Skip to content

[TUTORIAL] Hierarchical datasets with TreeStore #715

Description

@FrancescAlted

TreeStore is one of Python-Blosc2's headline features, and doc/reference/tree_store.rst documents its API. However, there is no interactive tutorial notebook in doc/tutorials/ showing how to use TreeStore to organize and query complex datasets.

Suggested Work

Create a new Jupyter Notebook at doc/tutorials/17.treestore-hierarchies.ipynb and register it in doc/tutorials/index.rst.

The notebook should demonstrate:

  1. Container layouts: Creating and opening in-memory stores, single-file zip stores (.b2z), and directory layouts (.b2d).
  2. Hierarchy & Groups: Creating groups and populating nested paths (e.g., /experiment/run_01/measurements, /metadata/config).
  3. Storing mixed containers: Inserting blosc2.NDArray arrays, blosc2.CTable tables, and custom scalar/dictionary attributes (attrs).
  4. Traversal & Discovery: Walking through trees with tree.walk() and searching for nodes matching specific criteria.
  5. Updating nodes & compression: Replacing or appending nodes in existing stores.
  6. Visualizing with b2view: Mentioning how the generated .b2z/.b2d file can be browsed in the terminal via b2view.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions