Changelog for dh5io
All notable changes to this project will be documented in this file.
The format is based on Keep a Changelog, and this project adheres to Semantic Versioning.
[Unreleased]
Added
Writing and reading SPIKE blocks (
dh5io.spike):create_empty_spike_group_in_file,create_spike_group_from_data_in_file, theSpikeclass (timestamps, waveforms as(nSpikes, spikeSamples, nChannels), cluster numbers, chunked writing withwrite_spikes),DH5File.get_spikes()/get_spike_by_id(), and validation of SPIKE blocks invalidate_dh5_file.SPIKE blocks without waveforms:
spikeSamples = 0(emptyDATA) for timestamps-only spike trains, e.g. from template-matching spike sorters, with an optionalMEAN_WAVEFORMdataset (documented as a dh5io extension in the specification).
[0.4.2] - 2026-08-11
Fixed
dh5browser: fixedAssertionErrorin ephyviewer’s navigation toolbar when opening files without continuous data. Spike sources without channels are no longer turned into empty viewers, and sources spanning zero time (empty, or holding a single spike/event) no longer abort the browser.
[0.4.1] - 2026-04-17
Added
Added
add_write_trialmap_operation()helper to write an Operations entry for TRIALMAP for backwards compatibility with BrainBox.
[0.4.0] - 2026-02-23
Added
MNE integration (
dh5io.dh5mne): New module for reading DH5 files as MNE-PythonRawobjectsMneRawDH5: lazy-loading Raw object backed by a DH5 fileread_raw_dh5: read a DH5 file as a singleMneRawDH5, selecting CONT groups by IDread_raw_dh5_per_sfreq: read oneMneRawDH5per unique sampling rate, grouping all matching CONT blocks togetherread_raw_dh5_per_cont: read oneMneRawDH5per CONT groupannotations_from_dh5: build MNEAnnotationsfrom TRIALMAP and EV02 eventsepochs_from_dh5: create MNEEpochsfrom aMneRawDH5using TRIALMAP annotationsAcquisition gaps between CONT regions are marked as
BAD_ACQ_SKIPannotationsrequire_matching_sampling_ratekwarg to control error vs skip behaviour on mixed-rate CONT groups
DH5File.is_continuous()and free functionis_continuous(fname): returnTruewhen all CONT blocks have a single region (no acquisition gaps)DH5File.cont_blocks_start_simultaneously()and free functioncont_blocks_start_simultaneously(fname): returnTruewhen all CONT blocks share the same first-region start timestampDH5File.get_cont_groups_by_sfreq(): return CONT groups grouped by sampling rateDH5File.get_cont_groups_by_ids(ids): return CONT groups for a given list of IDs, raisingDH5Erroron missing IDsSpecific
DH5Warningsubclasses for finer-grained warning filtering:DH5CalibrationMissingWarning(cont_id=...)— missingCalibrationattribute on a CONT blockkDH5ChannelsMissingWarning(cont_id=...)— missingChannelsattribute on a CONT blockDH5DataTypeConversionWarning— CONT data silently converted toint16on writeDH5OperationIndexWarning— malformed or non-sequential operation indexDH5DiscontinuousRegionsWarning— file contains multiple discontinuous CONT regionsDH5SampleCountMismatchWarning— selected CONT blocks have different sample countsDH5SampleRateMismatchWarning— CONT blocks with non-matching sampling rates were skipped
DH5File.__str__improvements: CONT groups are now displayed grouped by sampling rate, with per-block channel count, sample count and region count; file-level[continuous/discontinuous, simultaneous start]flags shown at the section headerdhfun compatibility: How dh5io writes string attributes to the DH5 file has been changed to be maximally compatible with the MATLAB tool dhfun, which uses a very old HDF5 library. In particular, this fixes errors when reading the output of dh5merge with dhfun (version 1).
Fixed
DH5File.get_trialmap()no longer crashes when the file contains no TRIALMAP dataset (now correctly returnsNone)
[0.3.0] - 2026-02-05
Added
Wavelet support: Added support for reading and writing WAVELET blocks with corresponding tests
dh5merge tool: New command-line tool for merging multiple DH5 files
Support for merging WAVELET, TRIALMAP, and EV02 blocks
GUI selector for choosing files to merge
Auto-suggest output filename based on common prefix of input files
Proper INDEX handling and DATA concatenation for all supported block types
Preserve Operations from first file on merge
Handle differing calibrations when merging CONT
dh5browser tool: New GUI tool for browsing and visualizing DH5 files
Scrolling through continuous data with segment annotations
Trial info widget and segment annotations
dh5neo implementation: Added README and tests for dh5neo subpackage to load data from DH5 files using the NEO data model.
Specification documentation: Added formal DH5 file format specification (revision 3.1)
[0.2.1] - 2025-08-21
Fixed
Fixed wrong package name in version getter
Fixed broken import in tests
Fixed trialmap test
[0.2.0] - 2025-08-21
Initial release on PyPI.