Skip to content

Releases: hdmf-dev/hdmf

3.4.0

05 Aug 18:33
3.4.0
7be4022
Compare
Choose a tag to compare

HDMF 3.4.0 (August 5, 2022)

Minor improvements

  • Allow manual triggering of some GitHub Actions. @rly (#744)
  • Relax input validation of HDF5IO to allow for s3fs support. Existing arguments of HDF5IO are modified as follows: i) mode was given a default value of "r", ii) path was given a default value of None, and iii) file can now accept an S3File type argument. @bendichter (#746)
  • Added ability to create and get back handle to empty HDF5 dataset. @ajtritt (#747)
  • Added AbstractContainer._in_construct_mode that is set and modified only by the ObjectMapper when constructing an
    object from a builder read from a file. Subclasses of AbstractContainer can check _in_construct_mode
    during the initialization phase as part of __init__ to distinguish between actions during construction
    (i.e., read from disk) vs. creation by the user, e.g., to determine whether to raise a warning or error when
    encountering invalid data to support reading and correcting data that is invalid while preventing creation
    of new data that is invalid. @rly (#751)

Bug fixes

3.3.2

28 Jun 00:45
3.3.2
0e50852
Compare
Choose a tag to compare
hdmf 3.3.2

3.3.1

25 May 15:48
3.3.1
2ae871f
Compare
Choose a tag to compare
hdmf 3.3.1

3.2.1

23 Feb 07:15
3.2.1
18bb897
Compare
Choose a tag to compare
hdmf 3.2.1

3.1.1

30 Jul 00:09
3.1.1
df31c59
Compare
Choose a tag to compare

Fixes

  • Updated the new DynamicTableRegion.get_linked_tables function (added in 3.1.0) to return lists of typing.NamedTuple
    objects rather than lists of dicts. @oruebel (#660)

3.1.0

29 Jul 22:07
3.1.0
44e0ba7
Compare
Choose a tag to compare

New features

  • Added several features to simplify interaction with DynamicTable objects that link to other tables via
    DynamicTableRegion columns. @oruebel (#645)
    • Added DynamicTable.get_foreign_columns to find all columns in a table that are a DynamicTableRegion
    • Added DynamicTable.has_foreign_columns to identify if a DynamicTable contains DynamicTableRegion columns
    • Added DynamicTable.get_linked_tables to retrieve all tables linked to either directly or indirectly from
      the current table via DynamicTableRegion
    • Implemented the new get_foreign_columns, has_foreign_columns, and get_linked_tables also for
      AlignedDynamicTable
    • Added new module hdmf.common.hierarchicaltable with helper functions to facilitate conversion of
      hierarchically nested DynamicTable objects via the following new functions:
      • to_hierarchical_dataframe to merge linked tables into a single consolidated pandas DataFrame.
      • drop_id_columns to remove "id" columns from a DataFrame.
      • flatten_column_index to replace a pandas.MultiIndex with a regular pandas.Index

Bug fixes

  • Do not build wheels compatible with Python 2 because HDMF requires Python 3.7. @rly (#642)
  • AlignedDynamicTable did not overwrite its get function. When using DynamicTableRegion to referenece AlignedDynamicTable this led to cases where the columns of the category subtables where omitted during data access (e.g., conversion to pandas.DataFrame). This fix adds the AlignedDynamicTable.get based on the existing AlignedDynamicTable.__getitem__. @oruebel (#645)
  • Fixed #651 to support selection of cells in an AlignedDynamicTable via slicing with [int, (str, str)](and [int, str, str]) to select a single cell, and [int, str] to select a single row of a category table. @oruebel (#645)

Minor improvements

  • Updated DynamicTable.to_dataframe() and DynamicTable.get functions to set the .name attribute
    on generated pandas DataFrame objects. @oruebel (#645)
  • Added AlignedDynamicTable.get_colnames(...) to support look-up of the full list of columns as the
    AlignedDynamicTable.colnames property only includes the columns of the main table for compliance with
    DynamicTable @oruebel (#645)
  • Fix documentation for DynamicTable.get and DynamicTableRegion.get. @rly (#650)
  • Allow passing string column name to DynamicTableRegion, i.e., dtr['col_name'] is a shortcut to
    dtr.table['col_name']. @rly (#657)

3.0.1

07 Jul 17:01
3.0.1
935d983
Compare
Choose a tag to compare

Bug fixes

  • Fixed release CI that prevented distribution from being uploaded to PyPI. @rly (#641)

3.0.0

07 Jul 17:05
@rly rly
3.0.0
0953ab0
Compare
Choose a tag to compare

New features

  • Add support for Python 3.9, drop support for Python 3.6. @rly (#620)
  • Add support for h5py 3. @ajtritt (#480)
    • h5py 3 introduced [breaking changes regarding how strings are handled]
      (https://docs.h5py.org/en/latest/whatsnew/3.0.html#breaking-changes-deprecations), specifically that
      variable-length UTF-8 strings in datasets are now read as bytes objects instead of str by default.
      To reduce the impact of this change on HDMF users, when HDMF reads a variable-length UTF-8 string
      dataset, instead of returning an h5py.Dataset that is read as bytes objects, HDMF will return a
      hdmf.utils.StrDataset object that extends h5py.Dataset and is read as str objects, which preserves
      previous behavior. For example, under HDMF 2.x, an HDF5 dataset d with data ['a', 'b'] is read as a
      h5py.Dataset object, and d[:] returns str objects. Under HDMF 3.x, the same dataset d is read
      as a hdmf.utils.StrDataset object and d[:] still returns str objects.
  • Add RRID to docs. @oruebel (#633)
  • Allow passing index=True to DynamicTable.to_dataframe() to support returning DynamicTableRegion columns
    as indices or Pandas DataFrame. @rly (#579)
  • Improve DynamicTable documentation. @rly (#639)
  • Updated external resources tutorial. @mavaylon (#611)

Breaking changes and deprecations

  • Previously, when using DynamicTable.__getitem__ or DynamicTable.get to access a selection of a
    DynamicTable containing a DynamicTableRegion, new columns with mangled names for the table data referred to
    by the DynamicTableRegion were added to the returned DataFrame. This did not work properly for ragged
    DynamicTableRegion, multiple levels of nesting, or multiple rows returned.
    Now, these methods will by default return columns of indices of the DynamicTableRegion. If index=False is
    passed to DynamicTable.get, then nested DataFrames will be returned, one DataFrame per row of the original
    resulting DataFrame. @rly (#579)

Minor improvements

  • Updated requirements and tests. @rly (#640)

Bug fixes

  • Update the validator to allow extensions to data types which only define data_type_inc. @dsleiter (#609)
  • Fix error when validating lazy-loaded datasets containing references. @dsleiter (#609)
  • Fix error when using DynamicTable.__getitem__ or DynamicTable.get when table has a ragged
    DynamicTableRegion. @rly (#579)

2.5.8

16 Jun 22:21
2.5.8
929ec93
Compare
Choose a tag to compare

Minor improvements

  • Improve Sphinx documentation. @rly (#627)

Bug fix

  • Fix error with representing an indexed table column when the VectorIndex dtype precision is upgraded more
    than one step, e.g., uint8 to uint32. This can happen when, for example, a single add_row call is used to
    add more than 65535 elements to an empty indexed column. @rly (#631)

2.5.7

05 Jun 06:11
2.5.7
1b084d5
Compare
Choose a tag to compare

Bug fix

  • Fix generation of extension classes that extend MultiContainerInterface and use a custom _fieldsname. @rly (#626)