Add HDF5 checkpoint support for analysis pipeline Add support f…#18
Draft
darshanmandge wants to merge 2 commits into
Draft
Add HDF5 checkpoint support for analysis pipeline Add support f…#18darshanmandge wants to merge 2 commits into
darshanmandge wants to merge 2 commits into
Conversation
…or reading optimisation checkpoints from HDF5 files in addition to pickle. This enables storing portable, reproducible checkpoint summaries that are not tied to specific Python/library versions. Changes: - New module bluepyemodel/tools/checkpoint_hdf5.py with: - read_checkpoint_h5(): reads HDF5 and returns DEAP-compatible shims - convert_checkpoint(): pickle → HDF5 conversion utility - Shim classes (_Individual, _Logbook, _CMAStatus, _History) that implement the exact API surface used by the analysis pipeline - Updated read_checkpoint() in utils.py to auto-detect format (.h5/.pkl) - Updated existing_checkpoint_paths() to glob both .pkl and .h5 - Updated access_point.py to use read_checkpoint() instead of inline pickle.load, and to discover .h5 checkpoint files HDF5 layout stores: param_names, halloffame (genes+fitness), population (genes+fitness), logbook (per-gen stats), and history/genealogy_genes for parameter evolution plots. Tested end-to-end: store_optimisation_results, optimisation plot, evolution_parameters_density, and check_optimisation_state all work from HDF5 with pickle removed.
Codecov Report❌ Patch coverage is
🚀 New features to boost your workflow:
|
| p = Path(checkpoint_path) | ||
|
|
||
| # HDF5 format | ||
| if p.suffix in (".h5", ".hdf5"): |
There was a problem hiding this comment.
If you write .h5 it won't become .hdf5, no? Wouldn't checking only for .h5 be sufficient?
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.