Skip to content

644 implement model registrator#651

Merged
cpaniaguam merged 19 commits intomainfrom
644-implement-model-registrator
Feb 10, 2025
Merged

644 implement model registrator#651
cpaniaguam merged 19 commits intomainfrom
644-implement-model-registrator

Conversation

@cpaniaguam
Copy link
Copy Markdown
Collaborator

This pull request introduces model registration functionality.

Model Registration:

  • Added a new module register.py for registering custom models in HSSM, including functions register_model, list_registered_models, and get_model_info.
  • Updated src/hssm/__init__.py to include the register_model function. [1] [2]
  • Tests

Other updates

Dependency Updates:

  • Added ipython, nbconvert, and ptpython to the dev dependencies in pyproject.toml. [1] [2]

Initialization Refactoring:

  • Refactored the __init__ method in src/hssm/hssm.py to use a dictionary comprehension for initializing self._init_args.

@cpaniaguam cpaniaguam linked an issue Feb 6, 2025 that may be closed by this pull request
Copy link
Copy Markdown
Collaborator

@digicosmos86 digicosmos86 left a comment

Choose a reason for hiding this comment

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

This looks great! I really like how clean it is, and it is exactly what we were thinking of.

Taking this further, we can now move on to thinking about how not to modify the default_model_config object (it is really supposed to be read-only) and also lazy-loading only certain model configs as needed, but this is already pretty great!

@codecov
Copy link
Copy Markdown

codecov bot commented Feb 6, 2025

Codecov Report

Attention: Patch coverage is 94.59459% with 2 lines in your changes missing coverage. Please review.

Files with missing lines Patch % Lines
src/hssm/register.py 94.11% 1 Missing ⚠️
tests/test_register.py 94.11% 1 Missing ⚠️
Files with missing lines Coverage Δ
src/hssm/__init__.py 100.00% <100.00%> (ø)
src/hssm/hssm.py 77.60% <100.00%> (+0.06%) ⬆️
src/hssm/register.py 94.11% <94.11%> (ø)
tests/test_register.py 94.11% <94.11%> (ø)

Copy link
Copy Markdown
Collaborator

@digicosmos86 digicosmos86 left a comment

Choose a reason for hiding this comment

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

LGTM!!

@cpaniaguam cpaniaguam merged commit 03ba14b into main Feb 10, 2025
5 checks passed
@digicosmos86 digicosmos86 deleted the 644-implement-model-registrator branch February 10, 2026 15:56
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.

Implement Model Registrator

2 participants