File tree Expand file tree Collapse file tree 1 file changed +2
-3
lines changed Expand file tree Collapse file tree 1 file changed +2
-3
lines changed Original file line number Diff line number Diff line change @@ -331,6 +331,7 @@ def _chunk_variable(ds: Dataset, variable_name: str) -> None:
331331 break
332332
333333 def determine_target_size (var_type : str ) -> int :
334+ """Determines the target size (in bytes) for a Variable based on its type."""
334335 if var_type == "bool" :
335336 return MAX_SIZE_LIVE_MASK
336337 return MAX_COORDINATES_BYTES
@@ -346,12 +347,10 @@ def determine_target_size(var_type: str) -> int:
346347 )
347348 )
348349
349- # Update the variable's metadata
350+ # Update the variable's metadata with the new chunk grid
350351 if ds .variables [idx ].metadata is None :
351- # Create new metadata with the chunk grid
352352 ds .variables [idx ].metadata = VariableMetadata (chunk_grid = chunks .chunk_grid )
353353 else :
354- # Update existing metadata
355354 ds .variables [idx ].metadata .chunk_grid = chunks .chunk_grid
356355
357356
You can’t perform that action at this time.
0 commit comments