Skip to content

Feature request: concatenate for NDArray (C-API/Python) without decompression #382

@rivershah

Description

@rivershah

Request native concatenate functionality for blosc2.NDArray, exposed in both the C-API and the Python wrapper.

Requirements:

  • C-API: Provide a C function to concatenate compressed b2nd along a specified axis.
  • Python API: Wrap the C function, mimicking the numpy.concatenate signature (sequence of arrays, axis parameter). Ref: NumPy Docs
  • Core Constraint: Must operate directly on compressed data, avoiding full decompression/recompression.
  • Assumptions: Input arrays share identical compression settings (codec, clevel, cparams, etc.).

Use Case:

Efficiently join large, pre-compressed datasets in both low-level C applications and Python without the performance penalty of decompression/recompression. Exposing it in the C-API is key for broader integration.

blosc2.SChunk.insert_chunk is very fast. Can this feature use this, along with metadata updates?

Thanks for considering this.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or requesthelp wantedExtra attention is needed

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions