do not use h5py on restarts#868
Conversation
WalkthroughWalkthroughThe recent changes enhance clarity and performance in the codebase by renaming parameters for better readability, streamlining internal logic, and introducing new methods for handling data. Key functions now utilize a more direct approach to retrieve information, reducing reliance on external libraries. These modifications not only simplify the code but also improve maintainability and extend functionality in attribute reading and data processing. Changes
Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media? TipsChatThere are 3 ways to chat with CodeRabbit:
Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (invoked as PR comments)
Additionally, you can add CodeRabbit Configuration File (
|
There was a problem hiding this comment.
Actionable comments posted: 0
Review details
Configuration used: .coderabbit.yaml
Review profile: CHILL
Files selected for processing (3)
- pyphare/pyphare/pharein/init.py (1 hunks)
- src/hdf5/detail/h5/h5_file.hpp (2 hunks)
- src/python3/cpp_etc.cpp (2 hunks)
Additional context used
Path-based instructions (1)
src/hdf5/detail/h5/h5_file.hpp (1)
Pattern
**/*.hpp: Review the C++ code, point out issues relative to principles of clean code, expressiveness, and performance.
Additional comments not posted (7)
src/python3/cpp_etc.cpp (3)
36-38: LGTM!The lambda function
samrai_restart_fileis clear and correctly encapsulates the call toPHARE::amr::HierarchyRestarter::getRestartFileFullPath(path).
60-69: LGTM!The function
patch_data_idscorrectly retrieves patch data IDs from the restart file using the HighFive library and handles the case where HighFive support is not available.
70-79: LGTM!The function
serialized_simulation_stringcorrectly retrieves the serialized simulation string from the restart file using the HighFive library and handles the case where HighFive support is not available.src/hdf5/detail/h5/h5_file.hpp (2)
72-75: LGTM!The reformatting of the
filemethod enhances readability without altering functionality.
241-248: LGTM!The method
read_attributeis well-implemented and correctly retrieves the attribute using thegetGroupandgetAttributemethods.pyphare/pyphare/pharein/__init__.py (2)
73-80: LGTM!The function
_patch_data_idscorrectly replaces the use ofh5pywithcpp_etc_lib, enhancing clarity and reducing dependencies.
83-86: LGTM!The function
_serialized_simulation_stringcorrectly replaces the use ofh5pywithcpp_etc_lib, enhancing clarity and reducing dependencies.
prevent hdf5 header/lib mismatch
eg: https://stackoverflow.com/q/45411700/795574
Summary by CodeRabbit
New Features
Improvements