We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 1037059 commit 28815f0Copy full SHA for 28815f0
webknossos/webknossos/dataset/layer.py
@@ -900,7 +900,17 @@ def add_mag_as_copy(
900
else:
901
has_same_compression = compress == foreign_mag_view.info.compression_mode
902
903
- if has_same_shapes and has_same_format and has_same_compression:
+ uses_memory_store = (
904
+ foreign_mag_view.path.protocol == "memory"
905
+ or (self.path / foreign_mag_view.mag.to_layer_name()).protocol == "memory"
906
+ )
907
+
908
+ if (
909
+ has_same_shapes
910
+ and has_same_format
911
+ and has_same_compression
912
+ and not uses_memory_store
913
+ ):
914
logger.debug(
915
f"Optimization: Copying files from {foreign_mag_view.path} to {self.path}/{foreign_mag_view.mag} directly without re-encoding."
916
)
0 commit comments