Skip to content

Commit

Permalink
Add env variable for chunks per shard
Browse files Browse the repository at this point in the history
  • Loading branch information
sm1lla committed Oct 24, 2023
1 parent 0db11cd commit 056fb03
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions webknossos/webknossos/dataset/defaults.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,12 @@
DEFAULT_WKW_FILE_LEN = 32
DEFAULT_CHUNK_SHAPE = Vec3Int.full(32)
DEFAULT_DATA_FORMAT = (
DataFormat.WKW if not os.environ.get("DATA_FORMAT") == "zarr3" else DataFormat.Zarr3
DataFormat.WKW
if not os.environ.get("WK_DEFAULT_DATA_FORMAT") == "zarr3"
else DataFormat.Zarr3
)
DEFAULT_CHUNKS_PER_SHARD = (
Vec3Int.full(32) if DEFAULT_DATA_FORMAT == DataFormat.WKW else Vec3Int.full(16)
DEFAULT_CHUNKS_PER_SHARD = Vec3Int.full(
int(os.environ.get("WK_DEFAULT_CHUNKS_PER_SHARD", 32))
)
DEFAULT_CHUNKS_PER_SHARD_ZARR = Vec3Int.full(1)
DEFAULT_CHUNKS_PER_SHARD_FROM_IMAGES = Vec3Int(128, 128, 1)
Expand Down

0 comments on commit 056fb03

Please sign in to comment.