Skip to content

Refactor feature generation#18

Merged
5h4ng merged 13 commits intomainfrom
refactor-feature-generation
Mar 16, 2026
Merged

Refactor feature generation#18
5h4ng merged 13 commits intomainfrom
refactor-feature-generation

Conversation

@5h4ng
Copy link
Copy Markdown
Owner

@5h4ng 5h4ng commented Mar 15, 2026

This PR introduces a Factory + Registry pattern for feature generators, replacing the if/elif chain in the orchestrator with a clean and extensible architecture (#8). It also removes the experimental Streamlit GUI and unifies code style.

5h4ng and others added 10 commits March 15, 2026 09:37
The GUI is not a current focus. This removes the entire optimhc/gui/
package (18 files, ~2300 lines), the `optimhc gui` CLI command,
the optional [gui] dependency group (streamlit, plotly, watchdog),
and all GUI references from README, docs, and pyproject.toml.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Migrate Google-style docstrings (Parameters:/Returns: without underlines)
to NumPy style (Parameters\n----------) in config.py, basic.py, DeepLC.py,
and spectral_similarity.py (13 docstrings total).

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Rename PWM.py, DeepLC.py, netMHCpan.py, and netMHCIIpan.py to their
lowercase equivalents (pwm.py, deeplc.py, netmhcpan.py, netmhciipan.py).
Update all import statements in feature_generation.py and module paths
in docs/api/features.md accordingly.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Auto-format base_feature_generator.py, factory.py, and spectral_similarity.py
to comply with ruff style (line wrapping adjustments).

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@5h4ng
Copy link
Copy Markdown
Owner Author

5h4ng commented Mar 15, 2026

Need to update logging because the import logic has changed. Logging should now be configured at the entry point of OptiMHC, in cli.py, rather than during module import.

@5h4ng
Copy link
Copy Markdown
Owner Author

5h4ng commented Mar 16, 2026

@codex review

Copy link
Copy Markdown

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 5f226be3b7

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread optimhc/cli.py Outdated

def setup_logging():
logging.basicConfig(
level=logging.INFO,
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Respect configured log level when initializing CLI logging

The CLI now hard-codes logging.INFO in setup_logging(), and pipeline/experiment call this before any config-driven level is applied, so both --logLevel and logLevel in YAML are effectively ignored. In workflows that rely on quieter logs (e.g., ERROR) or verbose diagnostics (DEBUG), this regression changes runtime behavior and makes the existing configuration knob misleading because it no longer controls logging output.

Useful? React with 👍 / 👎.

@5h4ng 5h4ng merged commit 8c48944 into main Mar 16, 2026
4 checks passed
@5h4ng 5h4ng deleted the refactor-feature-generation branch March 23, 2026 12:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant