-
Notifications
You must be signed in to change notification settings - Fork 19
Open
Description
Currently, _make_model_distribution is implemented as a concrete method in HSSMBase, but this method's logic is specific to standard HSSM models. As we work towards making HSSMBase a proper abstract base class that can be extended for different model types (e.g., RLSSM, custom models), this method should be abstract to enforce that each subclass provides its own implementation.
Proposed Solution
Refactor _make_model_distribution to be an abstract method in HSSMBase, with the current implementation moved to the HSSM class.
Tasks
- Make
HSSMBaseinherit from ABC - Convert
_make_model_distributioninHSSMBaseto an abstract method with appropriate docstring - Move the current implementation of
_make_model_distributionto the HSSM class - Ensure the HSSM implementation includes all necessary validation (e.g., for self.loglik and self.list_params)
- Run full test suite to ensure no regressions
- Verify all tests in test_hssm.py pass
- Update any relevant documentation if needed
Expected Benefits
- Clear interface contract for subclasses
- Better code organization and separation of concerns
- Easier to extend for future model types
- Python's ABC will automatically raise TypeError if subclasses don't implement required methods
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels