Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Data view /slice of zarr array without loading entire array #980

Open
Labels
documentationImprovements to the documentation
@aliaksei-chareshneu

Description

@aliaksei-chareshneu

Dear all,

Could you tell me please how do I get a data view of a zarr array? The key thing is performance.

From the docs, it looks like there is two options:

  • Usegetitem via ":" notation
    (store is existing DirectoryStore, there is one group 'sgroup' and one 3D array 'sarr')
root = zarr.group(store=store)arr = root.sgroup.sarrslice = arr[1:3, 1:3, 1:3]
  • Useget_basic_selection
root = zarr.group(store=store)arr = root.sgroup.sarrslice = arr.get_basic_selection(slice(1, 3), slice(1,3), slice(1,3))

In general, what is the difference between them? Would both options indeed get slice without loading entire array? Are there better alternatives in terms of performance?

Best regards,
Aliaksei

  • Value ofzarr.__version__: 2.10.3
  • Value ofnumcodecs.__version__: 0.9.1
  • Version of Python interpreter: 3.8.2
  • Operating system (Linux/Windows/Mac): Windows 7
  • How Zarr was installed (e.g., "using pip into virtual environment", or "using conda"): using pip into virtual environment

Metadata

Metadata

Assignees

No one assigned

    Labels

    documentationImprovements to the documentation

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions


      [8]ページ先頭

      ©2009-2025 Movatter.jp