MRiabov commited on
Commit
f2f9fec
·
1 Parent(s): 61275b8

Pull ttpla script

Browse files
Files changed (2) hide show
  1. requirements.txt +1 -0
  2. scripts/pull_ttpla.sh +24 -0
requirements.txt CHANGED
@@ -7,3 +7,4 @@ opencv-python>=4.8.0.76
7
  Pillow>=9.5.0
8
  PyYAML>=6.0.1
9
  tqdm>=4.65.0
 
 
7
  Pillow>=9.5.0
8
  PyYAML>=6.0.1
9
  tqdm>=4.65.0
10
+ gdown>=5.1.0
scripts/pull_ttpla.sh ADDED
@@ -0,0 +1,24 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ #!/usr/bin/env bash
2
+ set -euo pipefail
3
+
4
+ # Download TTPLA zip and extract
5
+ # Usage:
6
+ # scripts/pull_ttpla.sh [FILE_ID_OR_URL] [ZIP_NAME] [OUT_DIR]
7
+ # Defaults replicate the manual commands you ran.
8
+
9
+ FILE_ID_OR_URL="${1:-1Yz59yXCiPKS0_X4K3x9mW22NLnxjvrr0}"
10
+ ZIP_NAME="${2:-data_original_size_v1.zip}"
11
+ OUT_DIR="${3:-dataset/ttpla_dataset}"
12
+
13
+ # Work inside dataset/ like you did manually
14
+ mkdir -p dataset
15
+ cd dataset
16
+
17
+ echo "Downloading TTPLA: ${FILE_ID_OR_URL} -> ${ZIP_NAME}"
18
+ gdown "${FILE_ID_OR_URL}" -O "${ZIP_NAME}" --fuzzy
19
+
20
+ echo "Unzipping ${ZIP_NAME} -> ${OUT_DIR}"
21
+ mkdir -p "${OUT_DIR}"
22
+ unzip -q -o "${ZIP_NAME}" -d "${OUT_DIR}"
23
+
24
+ echo "Done. Contents extracted under: ${OUT_DIR}"