-
tensorstore.ChunkLayout.update(self, *, rank: int | None =
None, inner_order: Iterable[int] | None =None, inner_order_soft_constraint: Iterable[int] | None =None, grid_origin: Iterable[int | None] | None =None, grid_origin_soft_constraint: Iterable[int | None] | None =None, chunk: ChunkLayout.Grid | None =None, write_chunk: ChunkLayout.Grid | None =None, read_chunk: ChunkLayout.Grid | None =None, codec_chunk: ChunkLayout.Grid | None =None, chunk_shape: Iterable[int | None] | None =None, chunk_shape_soft_constraint: Iterable[int | None] | None =None, write_chunk_shape: Iterable[int | None] | None =None, write_chunk_shape_soft_constraint: Iterable[int | None] | None =None, read_chunk_shape: Iterable[int | None] | None =None, read_chunk_shape_soft_constraint: Iterable[int | None] | None =None, codec_chunk_shape: Iterable[int | None] | None =None, codec_chunk_shape_soft_constraint: Iterable[int | None] | None =None, chunk_aspect_ratio: Iterable[float | None] | None =None, chunk_aspect_ratio_soft_constraint: Iterable[float | None] | None =None, write_chunk_aspect_ratio: Iterable[float | None] | None =None, write_chunk_aspect_ratio_soft_constraint: Iterable[float | None] | None =None, read_chunk_aspect_ratio: Iterable[float | None] | None =None, read_chunk_aspect_ratio_soft_constraint: Iterable[float | None] | None =None, codec_chunk_aspect_ratio: Iterable[float | None] | None =None, codec_chunk_aspect_ratio_soft_constraint: Iterable[float | None] | None =None, chunk_elements: int | None =None, chunk_elements_soft_constraint: int | None =None, write_chunk_elements: int | None =None, write_chunk_elements_soft_constraint: int | None =None, read_chunk_elements: int | None =None, read_chunk_elements_soft_constraint: int | None =None, codec_chunk_elements: int | None =None, codec_chunk_elements_soft_constraint: int | None =None, finalize: bool | None =None) None Adds additional constraints.
- Parameters:¶
- rank: int | None =
None¶ Specifies the number of dimensions.
- inner_order: Iterable[int] | None =
None¶ Permutation specifying the element storage order within the innermost chunks. Corresponds to the JSON
ChunkLayout.inner_ordermember. This must be a permutation of[0, 1, ..., rank-1]. Lexicographic order (i.e. C order/row-major order) is specified as[0, 1, ..., rank-1], while colexicographic order (i.e. Fortran order/column-major order) is specified as[rank-1, ..., 1, 0].- inner_order_soft_constraint: Iterable[int] | None =
None¶ Specifies a preferred value for
inner_orderrather than a hard constraint. Corresponds to the JSONChunkLayout.inner_order_soft_constraintmember. Ifinner_orderis also specified, it takes precedence.- grid_origin: Iterable[int | None] | None =
None¶ Hard constraints on the origin of the chunk grid. Corresponds to the JSON
ChunkLayout.grid_originmember.- grid_origin_soft_constraint: Iterable[int | None] | None =
None¶ Soft constraints on the origin of the chunk grid. Corresponds to the JSON
ChunkLayout.grid_origin_soft_constraintmember.- chunk: ChunkLayout.Grid | None =
None¶ Common constraints on write, read, and codec chunks. Corresponds to the JSON
ChunkLayout.chunkmember. Theshapeandelementsconstraints apply only to write and read chunks, while theaspect_ratioconstraints apply to write, read, and codec chunks.- write_chunk: ChunkLayout.Grid | None =
None¶ Constraints on write chunks. Corresponds to the JSON
ChunkLayout.write_chunkmember.- read_chunk: ChunkLayout.Grid | None =
None¶ Constraints on read chunks. Corresponds to the JSON
ChunkLayout.read_chunkmember.- codec_chunk: ChunkLayout.Grid | None =
None¶ Constraints on codec chunks. Corresponds to the JSON
ChunkLayout.codec_chunkmember.- chunk_shape: Iterable[int | None] | None =
None¶ Hard constraints on both the write and read chunk shape. Corresponds to the JSON
shapemember ofChunkLayout.chunk. Equivalent to specifying bothwrite_chunk_shapeandread_chunk_shape.- chunk_shape_soft_constraint: Iterable[int | None] | None =
None¶ Soft constraints on both the write and read chunk shape. Corresponds to the JSON
shape_soft_constraintmember ofChunkLayout.chunk. Equivalent to specifying bothwrite_chunk_shape_soft_constraintandread_chunk_shape_soft_constraint.- write_chunk_shape: Iterable[int | None] | None =
None¶ Hard constraints on the write chunk shape. Corresponds to the JSON
shapemember ofChunkLayout.write_chunk.- write_chunk_shape_soft_constraint: Iterable[int | None] | None =
None¶ Soft constraints on the write chunk shape. Corresponds to the JSON
shape_soft_constraintmember ofChunkLayout.write_chunk.- read_chunk_shape: Iterable[int | None] | None =
None¶ Hard constraints on the read chunk shape. Corresponds to the JSON
shapemember ofChunkLayout.read_chunk.- read_chunk_shape_soft_constraint: Iterable[int | None] | None =
None¶ Soft constraints on the read chunk shape. Corresponds to the JSON
shape_soft_constraintmember ofChunkLayout.read_chunk.- codec_chunk_shape: Iterable[int | None] | None =
None¶ Soft constraints on the codec chunk shape. Corresponds to the JSON
shapemember ofChunkLayout.codec_chunk.- codec_chunk_shape_soft_constraint: Iterable[int | None] | None =
None¶ Soft constraints on the codec chunk shape. Corresponds to the JSON
shape_soft_constraintmember ofChunkLayout.codec_chunk.- chunk_aspect_ratio: Iterable[float | None] | None =
None¶ Hard constraints on the write, read, and codec chunk aspect ratio. Corresponds to the JSON
aspect_ratiomember ofChunkLayout.chunk. Equivalent to specifyingwrite_chunk_aspect_ratio,read_chunk_aspect_ratio, andcodec_chunk_aspect_ratio.- chunk_aspect_ratio_soft_constraint: Iterable[float | None] | None =
None¶ Soft constraints on the write, read, and codec chunk aspect ratio. Corresponds to the
aspect_ratio_soft_constraintmember ofChunkLayout.chunk. Equivalent to specifyingwrite_chunk_aspect_ratio_soft_constraint,read_chunk_aspect_ratio_soft_constraint, andcodec_chunk_aspect_ratio_soft_constraint.- write_chunk_aspect_ratio: Iterable[float | None] | None =
None¶ Hard constraints on the write chunk aspect ratio. Corresponds to the JSON
aspect_ratiomember ofChunkLayout.write_chunk.- write_chunk_aspect_ratio_soft_constraint: Iterable[float | None] | None =
None¶ Soft constraints on the write chunk aspect ratio. Corresponds to the JSON
aspect_ratio_soft_constraintmember ofChunkLayout.write_chunk.- read_chunk_aspect_ratio: Iterable[float | None] | None =
None¶ Hard constraints on the read chunk aspect ratio. Corresponds to the JSON
aspect_ratiomember ofChunkLayout.read_chunk.- read_chunk_aspect_ratio_soft_constraint: Iterable[float | None] | None =
None¶ Soft constraints on the read chunk aspect ratio. Corresponds to the JSON
aspect_ratio_soft_constraintmember ofChunkLayout.read_chunk.- codec_chunk_aspect_ratio: Iterable[float | None] | None =
None¶ Soft constraints on the codec chunk aspect ratio. Corresponds to the JSON
aspect_ratiomember ofChunkLayout.codec_chunk.- codec_chunk_aspect_ratio_soft_constraint: Iterable[float | None] | None =
None¶ Soft constraints on the codec chunk aspect ratio. Corresponds to the JSON
aspect_ratio_soft_constraintmember ofChunkLayout.codec_chunk.- chunk_elements: int | None =
None¶ Hard constraints on the target number of elements for write and read chunks. Corresponds to the JSON
elementsmember ofChunkLayout.chunk. Equivalent to specifying bothwrite_chunk_elementsandread_chunk_elements.- chunk_elements_soft_constraint: int | None =
None¶ Soft constraints on the target number of elements for write and read chunks. Corresponds to the JSON
elements_soft_constraintmember ofChunkLayout.chunk. Equivalent to specifying bothwrite_chunk_elements_soft_constraintandread_chunk_elements_soft_constraint.- write_chunk_elements: int | None =
None¶ Hard constraints on the target number of elements for write chunks. Corresponds to the JSON
elementsmember ofChunkLayout.write_chunk.- write_chunk_elements_soft_constraint: int | None =
None¶ Soft constraints on the target number of elements for write chunks. Corresponds to the JSON
elements_soft_constraintmember ofChunkLayout.write_chunk.- read_chunk_elements: int | None =
None¶ Hard constraints on the target number of elements for read chunks. Corresponds to the JSON
elementsmember ofChunkLayout.read_chunk.- read_chunk_elements_soft_constraint: int | None =
None¶ Soft constraints on the target number of elements for read chunks. Corresponds to the JSON
elements_soft_constraintmember ofChunkLayout.read_chunk.- codec_chunk_elements: int | None =
None¶ Hard constraints on the target number of elements for codec chunks. Corresponds to the JSON
elementsmember ofChunkLayout.codec_chunk.- codec_chunk_elements_soft_constraint: int | None =
None¶ Soft constraints on the target number of elements for codec chunks. Corresponds to the JSON
elements_soft_constraintmember ofChunkLayout.codec_chunk.- finalize: bool | None =
None¶ Validates and converts the layout into a precise chunk layout.
All dimensions of
grid_originmust be specified as hard constraints.Any write/read/codec chunk
shapesoft constraints are cleared.Any unspecified dimensions of the read chunk shape are set from the write chunk shape.
Any write/read/codec chunk
aspect_ratioorelementsconstraints are cleared.
- rank: int | None =