AugustHoeg commited on
Commit
a975114
·
verified ·
1 Parent(s): de0e4d3

Upload extract_files.sh with huggingface_hub

Browse files
Files changed (1) hide show
  1. extract_files.sh +19 -0
extract_files.sh ADDED
@@ -0,0 +1,19 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ #!/bin/bash
2
+
3
+ ROOT="ome"
4
+
5
+ echo "Extracting all .zarr.tar.gz files in $ROOT ..."
6
+
7
+ find "$ROOT" -name "*.zarr.tar.gz" -print0 | while IFS= read -r -d '' file; do
8
+ echo "Extracting $file ..."
9
+
10
+ # Extract
11
+ if tar -xzf "$file"; then
12
+ echo "Extraction successful: $file"
13
+ rm "$file"
14
+ else
15
+ echo "ERROR: Failed to extract $file"
16
+ fi
17
+ done
18
+
19
+ echo "Done."