-
Notifications
You must be signed in to change notification settings - Fork 531
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(data): Throw error when data's element is not present in `input.j…
…son/type_map` (#4639) See issue #4519 . When there are elements in the data that are not present in input.json, no error will be reported. For example, when element D is in type_map.raw, but D is not in type_map of input.json, the training process is normal. This error appears when `self.mixed_type=True`. <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit - **New Features** - Introduced enhanced data validation to ensure the atom type mapping is complete and consistent. Users will now receive clear error notifications if there are discrepancies in the provided mapping. - **Tests** - Added a new test class to verify correct data initialization and validate that errors are raised appropriately for invalid atom type mappings. <!-- end of auto-generated comment: release notes by coderabbit.ai --> --------- Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
- Loading branch information
1 parent
65812b8
commit e4eb01f
Showing
2 changed files
with
87 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters