Skip to content

Commit d2b2777

Browse files
authored
[MNT] Refactor AptaNetPSeAAC as thin subclass of PSeAAC (#541)
#### Reference Issues/PRs Fixes #537 #### What does this implement/fix? Explain your changes. `AptaNetPSeAAC` in `pyaptamer/pseaac/_aptanet_pseaac.py` was a verbatim copy of `PSeAAC`, duplicating `_normalized_aa`, `_avg_theta_val`, and `transform` with no additional logic. This created a maintenance risk where any bug fixed in `PSeAAC` would have to be manually mirrored to `AptaNetPSeAAC`. This PR refactors `AptaNetPSeAAC` into a thin subclass of `PSeAAC`, removing all duplicated methods and delegating to `super().__init__()` with the fixed 21-property, 7-group AptaNet configuration. The docstring example was also corrected — it previously imported and instantiated `PSeAAC` instead of `AptaNetPSeAAC`. #### What should a reviewer concentrate their feedback on? - The `super().__init__()` call in `AptaNetPSeAAC.__init__` and whether the passed parameters (`prop_indices=None`, `group_props=3`) correctly reproduce the original AptaNet configuration - The updated docstring example for correctness #### Did you add any tests for the change? No new tests were added. A manual check confirms the output which was identical to the original implementation. #### Any other comments? This change has been discussed with @satvshr on Discord who confirmed the refactor is welcome. #### PR checklist - [x] The PR title starts with either [ENH], [MNT], [DOC], or [BUG]. [BUG] - bugfix, [MNT] - CI, test framework, [ENH] - adding or improving code, [DOC] - writing or improving documentation or docstrings. - [ ] Added/modified tests - [x] Used pre-commit hooks when committing to ensure that code is compliant with hooks. Install hooks with `pre-commit install`. To run hooks independent of commit, execute `pre-commit run --all-files`
1 parent 245739b commit d2b2777

0 file changed

File tree

    0 commit comments

    Comments
     (0)