vLAR commited on
Commit
103d9b9
·
verified ·
1 Parent(s): 00c818d

Align public download utilities with GitHub

Browse files
.gitattributes CHANGED
@@ -28708,3 +28708,5 @@ Assets/PhysicBenchmark/Content/__ExternalActors__/PhysicsScenario/Levels/buildin
28708
  Assets/PhysicBenchmark/Content/__ExternalActors__/deformable/5/3J/RJQ0J1N13LMCBW5ROJ8M8F.uasset filter=lfs diff=lfs merge=lfs -text
28709
  Utils/leaderboard_lists/video-generation.txt filter=lfs diff=lfs merge=lfs -text
28710
  Utils/metadata/repo_assignment.txt filter=lfs diff=lfs merge=lfs -text
 
 
 
28708
  Assets/PhysicBenchmark/Content/__ExternalActors__/deformable/5/3J/RJQ0J1N13LMCBW5ROJ8M8F.uasset filter=lfs diff=lfs merge=lfs -text
28709
  Utils/leaderboard_lists/video-generation.txt filter=lfs diff=lfs merge=lfs -text
28710
  Utils/metadata/repo_assignment.txt filter=lfs diff=lfs merge=lfs -text
28711
+ Utils/scripts/download_lists/repo_assignment.txt filter=lfs diff=lfs merge=lfs -text
28712
+ Utils/scripts/download_lists/video_generation.txt filter=lfs diff=lfs merge=lfs -text
README.md CHANGED
@@ -495,7 +495,7 @@ The seven training archives add approximately <strong>51.61 GiB</strong> of back
495
 
496
  - [Browse the `PhysicBenchmark` project](https://huggingface.co/datasets/vLAR/PhysInOne/tree/main/Assets/PhysicBenchmark)
497
  - [Download and setup guide](https://huggingface.co/datasets/vLAR/PhysInOne/blob/main/Utils/3D_ASSETS_DOWNLOAD.md)
498
- - [Automated downloader](https://huggingface.co/datasets/vLAR/PhysInOne/blob/main/Utils/scripts/download_3d_assets.py)
499
  - [Exact validation release list](https://huggingface.co/datasets/vLAR/PhysInOne/blob/main/Utils/3d_assets_lists/validation.txt)
500
 
501
  Install <strong>Unreal Engine 5.5.4</strong>. Windows is recommended for the simplest setup; Linux is also supported with additional platform configuration. The dependency-free GitHub downloader currently retrieves and assembles the exact 1,000-scene validation project subset, safely extracts its eight ZIP files into their correct parent directories, preserves the Unreal Engine package hierarchy, supports interrupted-run recovery, and records detailed logs. The newly released training resource archives are available in their corresponding category folders in the project browser linked above.
@@ -558,7 +558,7 @@ Each row is a complete command that can be copied directly. The remote Leaderboa
558
 
559
  Downloads are resumable, and every run records successes and failures for review. No Hugging Face account, access token, or Python package installation is required.
560
 
561
- See the [complete GitHub download guide](https://github.com/vLAR-group/PhysInOne/blob/main/docs/DATA_DOWNLOAD.md), [download script](https://github.com/vLAR-group/PhysInOne/blob/main/scripts/download_data.py), and [bundled manifests](https://github.com/vLAR-group/PhysInOne/tree/main/scripts/download_lists). The additional [Hugging Face utility guide](https://huggingface.co/datasets/vLAR/PhysInOne/blob/main/Utils/LEADERBOARD_DOWNLOAD.md) remains available for users who prefer `huggingface_hub`.
562
 
563
  </div>
564
 
@@ -568,32 +568,32 @@ See the [complete GitHub download guide](https://github.com/vLAR-group/PhysInOne
568
 
569
  <div style="margin-left: 40px; text-align: justify;">
570
 
571
- Please download the [`Utils`](https://huggingface.co/datasets/vLAR/PhysInOne/tree/main/Utils) folder from the main dataset repository. It contains:
572
 
573
  ```text
574
  Utils/
575
- ├── metadata/
576
- │ ├── repo_assignment.txt
577
- │ └── repo_map.json
578
- ├── 3d_assets_lists/
579
- │ ├── validation.txt
580
- │ ├── validation_archives.txt
581
- │ └── summary.json
582
- ├── leaderboard_lists/
583
- │ ├── video-generation.txt
584
- │ ├── future-prediction.txt
585
- │ ├── physical-properties-estimation.txt
586
- │ └── motion-transfer.txt
587
- ├── 3D_ASSETS_DOWNLOAD.md
588
- ├── LEADERBOARD_DOWNLOAD.md
589
- └── scripts/
590
- ├── filter_cases.py
591
- ├── download.py
592
- ├── download_3d_assets.py
593
- └── download_leaderboard.py
594
  ```
595
 
596
- Run the following commands from inside the downloaded folder so the scripts can find `metadata/` using their default paths:
597
 
598
  ```bash
599
  cd "Utils"
@@ -601,20 +601,18 @@ cd "Utils"
601
 
602
  PhysInOne is distributed across multiple Hugging Face dataset repositories because of its large scale. We provide utilities for selecting and downloading full-dataset cases and Leaderboard evaluation data:
603
 
604
- - `filter_cases.py`: exports selected cases to JSON.
605
- - `download.py`: downloads the selected case zip files from the corresponding repositories.
606
- - `download_leaderboard.py`: downloads public evaluation data for the four Leaderboard tasks; see `LEADERBOARD_DOWNLOAD.md`.
607
- - `download_3d_assets.py`: downloads and safely assembles the validation Unreal Engine project; see `3D_ASSETS_DOWNLOAD.md`.
608
 
609
  </div>
610
 
611
- <h3 id="install-dependencies" style="font-size: 1.35em; margin-top: 0.75em; margin-bottom: 0.22em; line-height: 1.2; margin-left: 24px;">2. Install Dependencies</h3>
612
 
613
  <div style="margin-left: 40px;">
614
 
615
- ```bash
616
- pip install huggingface_hub tqdm
617
- ```
618
 
619
  </div>
620
 
@@ -711,7 +709,7 @@ python scripts/filter_cases.py \
711
  Each selected case is downloaded as a zip file from the corresponding Hugging Face shard repository.
712
 
713
  ```bash
714
- python scripts/download.py \
715
  --selection selected_cases.json \
716
  --output_dir ./PhysInOne
717
  ```
@@ -719,7 +717,7 @@ python scripts/download.py \
719
  By default, downloaded zip files are saved into a flat output folder. To preserve shard/split/activity structure:
720
 
721
  ```bash
722
- python scripts/download.py \
723
  --selection selected_cases.json \
724
  --output_dir ./PhysInOne \
725
  --keep_shard_structure
 
495
 
496
  - [Browse the `PhysicBenchmark` project](https://huggingface.co/datasets/vLAR/PhysInOne/tree/main/Assets/PhysicBenchmark)
497
  - [Download and setup guide](https://huggingface.co/datasets/vLAR/PhysInOne/blob/main/Utils/3D_ASSETS_DOWNLOAD.md)
498
+ - [Automated downloader](https://huggingface.co/datasets/vLAR/PhysInOne/blob/main/Utils/scripts/download_data.py)
499
  - [Exact validation release list](https://huggingface.co/datasets/vLAR/PhysInOne/blob/main/Utils/3d_assets_lists/validation.txt)
500
 
501
  Install <strong>Unreal Engine 5.5.4</strong>. Windows is recommended for the simplest setup; Linux is also supported with additional platform configuration. The dependency-free GitHub downloader currently retrieves and assembles the exact 1,000-scene validation project subset, safely extracts its eight ZIP files into their correct parent directories, preserves the Unreal Engine package hierarchy, supports interrupted-run recovery, and records detailed logs. The newly released training resource archives are available in their corresponding category folders in the project browser linked above.
 
558
 
559
  Downloads are resumable, and every run records successes and failures for review. No Hugging Face account, access token, or Python package installation is required.
560
 
561
+ See the [complete GitHub download guide](https://github.com/vLAR-group/PhysInOne/blob/main/docs/DATA_DOWNLOAD.md), [download script](https://github.com/vLAR-group/PhysInOne/blob/main/scripts/download_data.py), and [bundled manifests](https://github.com/vLAR-group/PhysInOne/tree/main/scripts/download_lists). The [Hugging Face utility guide](https://huggingface.co/datasets/vLAR/PhysInOne/blob/main/Utils/LEADERBOARD_DOWNLOAD.md) documents the same dependency-free interface.
562
 
563
  </div>
564
 
 
568
 
569
  <div style="margin-left: 40px; text-align: justify;">
570
 
571
+ Please download the [`Utils`](https://huggingface.co/datasets/vLAR/PhysInOne/tree/main/Utils) folder from the main dataset repository. Its public scripts mirror the GitHub `scripts/` tree:
572
 
573
  ```text
574
  Utils/
575
+ |-- metadata/
576
+ | |-- repo_assignment.txt
577
+ | +-- repo_map.json
578
+ |-- 3d_assets_lists/
579
+ |-- leaderboard_lists/
580
+ |-- 3D_ASSETS_DOWNLOAD.md
581
+ |-- LEADERBOARD_DOWNLOAD.md
582
+ +-- scripts/
583
+ |-- download_data.py
584
+ |-- download_selected.py
585
+ |-- filter_cases.py
586
+ +-- download_lists/
587
+ |-- video_generation.txt
588
+ |-- future_prediction.txt
589
+ |-- physical_properties_estimation.txt
590
+ |-- motion_transfer.txt
591
+ |-- 3d_assets.txt
592
+ |-- repo_assignment.txt
593
+ +-- repo_map.json
594
  ```
595
 
596
+ Run the following commands from inside the downloaded `Utils/` folder:
597
 
598
  ```bash
599
  cd "Utils"
 
601
 
602
  PhysInOne is distributed across multiple Hugging Face dataset repositories because of its large scale. We provide utilities for selecting and downloading full-dataset cases and Leaderboard evaluation data:
603
 
604
+ - `download_data.py`: downloads all four Leaderboard tasks and assembles the validation Unreal Engine project.
605
+ - `filter_cases.py`: exports selected full-dataset cases to JSON.
606
+ - `download_selected.py`: downloads selected scene ZIPs from the corresponding public shards.
607
+ - `download_lists/`: contains the exact manifests used by all three scripts.
608
 
609
  </div>
610
 
611
+ <h3 id="install-dependencies" style="font-size: 1.35em; margin-top: 0.75em; margin-bottom: 0.22em; line-height: 1.2; margin-left: 24px;">2. Requirements</h3>
612
 
613
  <div style="margin-left: 40px;">
614
 
615
+ Python 3.9 or newer is recommended. The download utilities use only the Python standard library and anonymous HTTPS requests; no package installation or authentication is required.
 
 
616
 
617
  </div>
618
 
 
709
  Each selected case is downloaded as a zip file from the corresponding Hugging Face shard repository.
710
 
711
  ```bash
712
+ python scripts/download_selected.py \
713
  --selection selected_cases.json \
714
  --output_dir ./PhysInOne
715
  ```
 
717
  By default, downloaded zip files are saved into a flat output folder. To preserve shard/split/activity structure:
718
 
719
  ```bash
720
+ python scripts/download_selected.py \
721
  --selection selected_cases.json \
722
  --output_dir ./PhysInOne \
723
  --keep_shard_structure
Utils/3D_ASSETS_DOWNLOAD.md CHANGED
@@ -12,7 +12,6 @@ Repository location:
12
 
13
  - Unreal Engine **5.5.4**
14
  - Python 3.9 or newer for the automated downloader
15
- - `huggingface_hub`; `tqdm` is recommended for progress display
16
  - At least **50–60 GiB of free disk space** when keeping both ZIP files and
17
  extracted assets
18
 
@@ -22,51 +21,28 @@ case-sensitive paths may require additional configuration.
22
 
23
  ## Automated setup
24
 
25
- Install the Python dependencies:
 
26
 
27
  ```bash
28
- pip install -U huggingface_hub tqdm
 
 
29
  ```
30
 
31
- Download the script, release lists, and this guide:
32
-
33
- ```bash
34
- hf download vLAR/PhysInOne \
35
- "Utils/scripts/download_3d_assets.py" \
36
- "Utils/3d_assets_lists/validation.txt" \
37
- "Utils/3d_assets_lists/validation_archives.txt" \
38
- "Utils/3d_assets_lists/summary.json" \
39
- "Utils/3D_ASSETS_DOWNLOAD.md" \
40
- --repo-type dataset \
41
- --local-dir .
42
- ```
43
-
44
- Run the downloader:
45
-
46
- ```bash
47
- python "Utils/scripts/download_3d_assets.py" \
48
- --output-dir ./PhysInOne-3D-Assets
49
- ```
50
-
51
- The default command performs all of the following:
52
 
53
  1. Downloads the exact validation release file list.
54
  2. Maps the project to the space-free local path `assets/PhysicBenchmark/`.
55
  3. Validates ZIP paths and rejects unsafe archive members.
56
- 4. Extracts all eight ZIP files into their correct parent directories.
57
  5. Merges scene and trajectory batches without overwriting different files.
58
  6. Writes resumable extraction markers and detailed success/failure logs.
59
 
60
- After completion, the Unreal Engine project root is:
61
-
62
- ```text
63
- PhysInOne-3D-Assets/assets/PhysicBenchmark/
64
- ```
65
-
66
- Open the project with Unreal Engine 5.5.4 by launching:
67
 
68
  ```text
69
- PhysInOne-3D-Assets/assets/PhysicBenchmark/PhysInOne.uproject
70
  ```
71
 
72
  ## Download without extraction
@@ -74,8 +50,8 @@ PhysInOne-3D-Assets/assets/PhysicBenchmark/PhysInOne.uproject
74
  To download the released files but keep every archive compressed:
75
 
76
  ```bash
77
- python "Utils/scripts/download_3d_assets.py" \
78
- --output-dir ./PhysInOne-3D-Assets \
79
  --no-extract
80
  ```
81
 
@@ -87,8 +63,8 @@ the archives.
87
  To delete each ZIP only after it has been completely extracted and verified:
88
 
89
  ```bash
90
- python "Utils/scripts/download_3d_assets.py" \
91
- --output-dir ./PhysInOne-3D-Assets \
92
  --delete-zip-after-extract
93
  ```
94
 
@@ -180,8 +156,8 @@ layout can cause missing asset references or prevent levels from loading.
180
  ## Resume and logs
181
 
182
  The downloader is safe to run again with the same output directory. Completed
183
- downloads are reused by `huggingface_hub`, existing identical extracted files
184
- are retained, and archives with complete markers are skipped.
185
 
186
  Logs are written to:
187
 
@@ -200,13 +176,13 @@ If a run is interrupted, execute the same command again and review
200
  For a slower or rate-limited network, reduce concurrency:
201
 
202
  ```bash
203
- python "Utils/scripts/download_3d_assets.py" \
204
- --output-dir ./PhysInOne-3D-Assets \
205
  --workers 2
206
  ```
207
 
208
- Public downloads do not require authentication. Do not place access credentials
209
- in source code, shared shell scripts, commands, or download logs.
210
 
211
  ## Contact
212
 
 
12
 
13
  - Unreal Engine **5.5.4**
14
  - Python 3.9 or newer for the automated downloader
 
15
  - At least **50–60 GiB of free disk space** when keeping both ZIP files and
16
  extracted assets
17
 
 
21
 
22
  ## Automated setup
23
 
24
+ The public downloader uses only the Python standard library. Clone the GitHub
25
+ repository, which contains the script and exact release manifests:
26
 
27
  ```bash
28
+ git clone https://github.com/vLAR-group/PhysInOne.git
29
+ cd PhysInOne
30
+ python scripts/download_data.py --task 3d-assets --output-dir ./PhysInOne_data
31
  ```
32
 
33
+ The default command:
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
34
 
35
  1. Downloads the exact validation release file list.
36
  2. Maps the project to the space-free local path `assets/PhysicBenchmark/`.
37
  3. Validates ZIP paths and rejects unsafe archive members.
38
+ 4. Extracts all eight validation ZIP files into their correct parent directories.
39
  5. Merges scene and trajectory batches without overwriting different files.
40
  6. Writes resumable extraction markers and detailed success/failure logs.
41
 
42
+ After completion, launch this project with Unreal Engine 5.5.4:
 
 
 
 
 
 
43
 
44
  ```text
45
+ PhysInOne_data/assets/PhysicBenchmark/PhysInOne.uproject
46
  ```
47
 
48
  ## Download without extraction
 
50
  To download the released files but keep every archive compressed:
51
 
52
  ```bash
53
+ python scripts/download_data.py --task 3d-assets \
54
+ --output-dir ./PhysInOne_data \
55
  --no-extract
56
  ```
57
 
 
63
  To delete each ZIP only after it has been completely extracted and verified:
64
 
65
  ```bash
66
+ python scripts/download_data.py --task 3d-assets \
67
+ --output-dir ./PhysInOne_data \
68
  --delete-zip-after-extract
69
  ```
70
 
 
156
  ## Resume and logs
157
 
158
  The downloader is safe to run again with the same output directory. Completed
159
+ downloads are reused, valid `.part` files are resumed, existing identical
160
+ extracted files are retained, and archives with complete markers are skipped.
161
 
162
  Logs are written to:
163
 
 
176
  For a slower or rate-limited network, reduce concurrency:
177
 
178
  ```bash
179
+ python scripts/download_data.py --task 3d-assets \
180
+ --output-dir ./PhysInOne_data \
181
  --workers 2
182
  ```
183
 
184
+ Public downloads are anonymous. The downloader has no token parameter or
185
+ credential-handling path.
186
 
187
  ## Contact
188
 
Utils/LEADERBOARD_DOWNLOAD.md CHANGED
@@ -15,34 +15,29 @@ No Hugging Face access token is required for public downloads.
15
 
16
  ## Install
17
 
18
- Python 3.9 or newer is recommended.
 
 
19
 
20
- ```bash
21
- pip install -U huggingface_hub tqdm
22
- ```
23
-
24
- Download the utility script:
25
 
26
  ```bash
27
- hf download vLAR/PhysInOne \
28
- "Utils/scripts/download_leaderboard.py" \
29
- --repo-type dataset \
30
- --local-dir .
31
  ```
32
 
33
- The Python script automatically fetches the required task manifest from the
34
- public Hugging Face repository for the selected `--task` and `--revision`. You
35
- do not need to download any TXT manifest files manually.
36
 
37
  ## Quick start
38
 
39
- Run these commands from the directory containing the downloaded
40
- `Utils/` folder.
41
 
42
  Download all four tasks:
43
 
44
  ```bash
45
- python "Utils/scripts/download_leaderboard.py" \
46
  --task all \
47
  --output-dir ./PhysInOne-Leaderboard
48
  ```
@@ -50,7 +45,7 @@ python "Utils/scripts/download_leaderboard.py" \
50
  Download one task:
51
 
52
  ```bash
53
- python "Utils/scripts/download_leaderboard.py" \
54
  --task future-prediction \
55
  --output-dir ./PhysInOne-Leaderboard
56
  ```
@@ -58,18 +53,17 @@ python "Utils/scripts/download_leaderboard.py" \
58
  Download multiple tasks in one run:
59
 
60
  ```bash
61
- python "Utils/scripts/download_leaderboard.py" \
62
  --task video-generation motion-transfer \
63
  --output-dir ./PhysInOne-Leaderboard
64
  ```
65
 
66
  ## Task names and file lists
67
 
68
- For each selected task, the downloader automatically fetches a maintained TXT
69
- manifest containing one exact repository file path per line. It uses that
70
- manifest instead of scanning or downloading unrelated parts of the large
71
- PhysInOne repository. The links below are provided for inspection and
72
- reproducibility; manual manifest downloads are not required.
73
 
74
  | `--task` value | Repository directory | Maintained file list |
75
  | --- | --- | --- |
@@ -82,16 +76,16 @@ reproducibility; manual manifest downloads are not required.
82
 
83
  | Task | Command | Space-free local directory |
84
  | --- | --- | --- |
85
- | Video Generation | `python Utils/scripts/download_leaderboard.py --task video-generation --output-dir ./PhysInOne-Leaderboard` | `PhysInOne-Leaderboard/leaderboard/video_generation/` |
86
- | Future Prediction | `python Utils/scripts/download_leaderboard.py --task future-prediction --output-dir ./PhysInOne-Leaderboard` | `PhysInOne-Leaderboard/leaderboard/future_prediction/` |
87
- | Physical Properties Estimation | `python Utils/scripts/download_leaderboard.py --task physical-properties-estimation --output-dir ./PhysInOne-Leaderboard` | `PhysInOne-Leaderboard/leaderboard/physical_properties_estimation/` |
88
- | Motion Transfer | `python Utils/scripts/download_leaderboard.py --task motion-transfer --output-dir ./PhysInOne-Leaderboard` | `PhysInOne-Leaderboard/leaderboard/motion_transfer/` |
89
- | All four tasks | `python Utils/scripts/download_leaderboard.py --task all --output-dir ./PhysInOne-Leaderboard` | `PhysInOne-Leaderboard/leaderboard/` |
90
 
91
- Use `--list-only` to print the selected remote paths without downloading data:
92
 
93
  ```bash
94
- python "Utils/scripts/download_leaderboard.py" \
95
  --task motion-transfer \
96
  --list-only
97
  ```
@@ -99,7 +93,7 @@ python "Utils/scripts/download_leaderboard.py" \
99
  Use `--dry-run` to show the number of selected files:
100
 
101
  ```bash
102
- python "Utils/scripts/download_leaderboard.py" \
103
  --task all \
104
  --dry-run
105
  ```
@@ -111,14 +105,14 @@ It accepts a complete scene name or the unique six-character scene ID and can
111
  be repeated.
112
 
113
  ```bash
114
- python "Utils/scripts/download_leaderboard.py" \
115
  --task future-prediction \
116
  --scene yUlWPB \
117
  --output-dir ./PhysInOne-Leaderboard
118
  ```
119
 
120
  ```bash
121
- python "Utils/scripts/download_leaderboard.py" \
122
  --task motion-transfer \
123
  --scene B15ta6 \
124
  --scene 7omQio \
@@ -132,7 +126,7 @@ exact released artifacts. Add `--extract` to validate each ZIP with a CRC check
132
  and safely extract it next to the archive:
133
 
134
  ```bash
135
- python "Utils/scripts/download_leaderboard.py" \
136
  --task physical-properties-estimation \
137
  --output-dir ./PhysInOne-Leaderboard \
138
  --extract
@@ -142,7 +136,7 @@ To remove an archive after successful extraction, explicitly add
142
  `--delete-zip-after-extract`:
143
 
144
  ```bash
145
- python "Utils/scripts/download_leaderboard.py" \
146
  --task future-prediction \
147
  --output-dir ./PhysInOne-Leaderboard \
148
  --extract \
@@ -196,32 +190,28 @@ PhysInOne-Leaderboard/
196
  | +-- motion_transfer/
197
  +-- _download_logs/
198
  +-- YYYYMMDD_HHMMSS/
199
- |-- success.tsv
 
200
  |-- failures.tsv
201
- |-- events.jsonl
202
  +-- summary.json
203
  ```
204
 
205
- Hugging Face may also create a hidden local cache/metadata directory inside the
206
- output root. It is used to resume and avoid redundant transfers.
207
-
208
  ## Resume and troubleshooting
209
 
210
- Downloads are handled by `huggingface_hub`. Re-running the same command reuses
211
- the local Hugging Face metadata and cache, so completed files are not downloaded
212
- again unnecessarily. Review `failures.tsv` after each run and repeat the same
213
- command to retry failed files.
214
 
215
  The default is four concurrent downloads. For a slow or rate-limited network,
216
  reduce concurrency:
217
 
218
  ```bash
219
- python "Utils/scripts/download_leaderboard.py" \
220
  --task all \
221
  --output-dir ./PhysInOne-Leaderboard \
222
  --workers 2
223
  ```
224
 
225
- Public downloads do not require authentication. Do not place access tokens in
226
- source code, shared shell scripts, commands, or download logs.
227
 
 
15
 
16
  ## Install
17
 
18
+ Python 3.9 or newer is recommended. The downloader uses only the Python
19
+ standard library; no third-party package or Hugging Face authentication is
20
+ required.
21
 
22
+ Clone the GitHub repository, which contains the downloader and all maintained
23
+ manifests:
 
 
 
24
 
25
  ```bash
26
+ git clone https://github.com/vLAR-group/PhysInOne.git
27
+ cd PhysInOne
 
 
28
  ```
29
 
30
+ The same script tree is mirrored under `Utils/scripts/` in the Hugging Face
31
+ dataset repository.
 
32
 
33
  ## Quick start
34
 
35
+ Run these commands from the cloned GitHub repository root.
 
36
 
37
  Download all four tasks:
38
 
39
  ```bash
40
+ python scripts/download_data.py \
41
  --task all \
42
  --output-dir ./PhysInOne-Leaderboard
43
  ```
 
45
  Download one task:
46
 
47
  ```bash
48
+ python scripts/download_data.py \
49
  --task future-prediction \
50
  --output-dir ./PhysInOne-Leaderboard
51
  ```
 
53
  Download multiple tasks in one run:
54
 
55
  ```bash
56
+ python scripts/download_data.py \
57
  --task video-generation motion-transfer \
58
  --output-dir ./PhysInOne-Leaderboard
59
  ```
60
 
61
  ## Task names and file lists
62
 
63
+ For each selected task, the downloader reads a maintained TXT manifest bundled
64
+ under `scripts/download_lists/`. It does not fetch utility files at runtime and
65
+ does not scan unrelated parts of the large PhysInOne repository. The Hugging
66
+ Face copies below are provided for inspection and reproducibility.
 
67
 
68
  | `--task` value | Repository directory | Maintained file list |
69
  | --- | --- | --- |
 
76
 
77
  | Task | Command | Space-free local directory |
78
  | --- | --- | --- |
79
+ | Video Generation | `python scripts/download_data.py --task video-generation --output-dir ./PhysInOne-Leaderboard` | `PhysInOne-Leaderboard/leaderboard/video_generation/` |
80
+ | Future Prediction | `python scripts/download_data.py --task future-prediction --output-dir ./PhysInOne-Leaderboard` | `PhysInOne-Leaderboard/leaderboard/future_prediction/` |
81
+ | Physical Properties Estimation | `python scripts/download_data.py --task physical-properties-estimation --output-dir ./PhysInOne-Leaderboard` | `PhysInOne-Leaderboard/leaderboard/physical_properties_estimation/` |
82
+ | Motion Transfer | `python scripts/download_data.py --task motion-transfer --output-dir ./PhysInOne-Leaderboard` | `PhysInOne-Leaderboard/leaderboard/motion_transfer/` |
83
+ | All four tasks | `python scripts/download_data.py --task all --output-dir ./PhysInOne-Leaderboard` | `PhysInOne-Leaderboard/leaderboard/` |
84
 
85
+ Use `--list-only` to print the selected public URLs without downloading data:
86
 
87
  ```bash
88
+ python scripts/download_data.py \
89
  --task motion-transfer \
90
  --list-only
91
  ```
 
93
  Use `--dry-run` to show the number of selected files:
94
 
95
  ```bash
96
+ python scripts/download_data.py \
97
  --task all \
98
  --dry-run
99
  ```
 
105
  be repeated.
106
 
107
  ```bash
108
+ python scripts/download_data.py \
109
  --task future-prediction \
110
  --scene yUlWPB \
111
  --output-dir ./PhysInOne-Leaderboard
112
  ```
113
 
114
  ```bash
115
+ python scripts/download_data.py \
116
  --task motion-transfer \
117
  --scene B15ta6 \
118
  --scene 7omQio \
 
126
  and safely extract it next to the archive:
127
 
128
  ```bash
129
+ python scripts/download_data.py \
130
  --task physical-properties-estimation \
131
  --output-dir ./PhysInOne-Leaderboard \
132
  --extract
 
136
  `--delete-zip-after-extract`:
137
 
138
  ```bash
139
+ python scripts/download_data.py \
140
  --task future-prediction \
141
  --output-dir ./PhysInOne-Leaderboard \
142
  --extract \
 
190
  | +-- motion_transfer/
191
  +-- _download_logs/
192
  +-- YYYYMMDD_HHMMSS/
193
+ |-- downloads.tsv
194
+ |-- extractions.tsv
195
  |-- failures.tsv
 
196
  +-- summary.json
197
  ```
198
 
 
 
 
199
  ## Resume and troubleshooting
200
 
201
+ Downloads use resumable anonymous HTTPS requests. Re-running the same command
202
+ reuses completed files and resumes valid `.part` files. Review `failures.tsv`
203
+ after each run and repeat the same command to retry failed files.
 
204
 
205
  The default is four concurrent downloads. For a slow or rate-limited network,
206
  reduce concurrency:
207
 
208
  ```bash
209
+ python scripts/download_data.py \
210
  --task all \
211
  --output-dir ./PhysInOne-Leaderboard \
212
  --workers 2
213
  ```
214
 
215
+ Public downloads are anonymous. The downloader has no token parameter or
216
+ credential-handling path.
217
 
Utils/scripts/download.py DELETED
@@ -1,188 +0,0 @@
1
- #!/usr/bin/env python3
2
- """
3
- Download selected PhysInOne case zip files from Hugging Face shard repositories.
4
-
5
- Input:
6
- selected_cases.json produced by filter_cases.py
7
- repo_map.json mapping part IDs to Hugging Face repo IDs
8
-
9
- Recommended repo_map.json format:
10
- {
11
- "physinone_part1": "PhysInOneP01/PhysInOneP01",
12
- "physinone_part2": "PhysInOneP02/PhysInOneP02"
13
- }
14
-
15
- The script downloads each selected case zip using huggingface_hub.hf_hub_download.
16
- """
17
-
18
- from __future__ import annotations
19
-
20
- import argparse
21
- import json
22
- import shutil
23
- from pathlib import Path
24
- from urllib.parse import urlparse
25
-
26
- from huggingface_hub import hf_hub_download
27
- from tqdm import tqdm
28
-
29
-
30
- DEFAULT_SELECTION_FILE = Path("selected_cases.json")
31
- DEFAULT_REPO_MAP_FILE = Path("metadata/repo_map.json")
32
-
33
-
34
- def normalize_repo_id(value: str) -> str:
35
- """Accept either a repo id or a Hugging Face URL and return repo id."""
36
- value = value.strip().rstrip("/")
37
- if value.startswith("http://") or value.startswith("https://"):
38
- parsed = urlparse(value)
39
- # Expected: /datasets/PhysInOneP01/PhysInOneP01[/tree/main]
40
- parts = [p for p in parsed.path.split("/") if p]
41
- if len(parts) >= 3 and parts[0] == "datasets":
42
- return f"{parts[1]}/{parts[2]}"
43
- raise ValueError(f"Cannot parse Hugging Face dataset repo URL: {value}")
44
- return value
45
-
46
-
47
- def load_json(path: Path) -> dict:
48
- if not path.exists():
49
- raise FileNotFoundError(f"File not found: {path}")
50
- return json.loads(path.read_text(encoding="utf-8"))
51
-
52
-
53
- def load_repo_map(path: Path) -> dict[str, str]:
54
- data = load_json(path)
55
- if not isinstance(data, dict):
56
- raise ValueError("repo_map.json must be a dictionary: part_id -> repo_id")
57
- return {str(k): normalize_repo_id(str(v)) for k, v in data.items()}
58
-
59
-
60
- def safe_output_path(output_dir: Path, case: dict, keep_shard_structure: bool) -> Path:
61
- filename = Path(case["hf_zip_path"]).name
62
- if keep_shard_structure:
63
- # Preserve Split/ActivityType layout.
64
- return output_dir / case["part_id"] / case["split"] / case["activity_type"] / filename
65
- return output_dir / filename
66
-
67
-
68
- def main() -> None:
69
- parser = argparse.ArgumentParser(description="Download PhysInOne selected case zips.")
70
- parser.add_argument(
71
- "--selection",
72
- type=Path,
73
- default=DEFAULT_SELECTION_FILE,
74
- help=f"selected_cases.json from filter_cases.py. Default: {DEFAULT_SELECTION_FILE}",
75
- )
76
- parser.add_argument(
77
- "--repo_map",
78
- type=Path,
79
- default=DEFAULT_REPO_MAP_FILE,
80
- help=f"JSON mapping part_id to HF repo id. Default: {DEFAULT_REPO_MAP_FILE}",
81
- )
82
- parser.add_argument(
83
- "--output_dir",
84
- type=Path,
85
- default=Path("./PhysInOne"),
86
- help="Local output directory. Default: ./PhysInOne",
87
- )
88
- parser.add_argument(
89
- "--repo_type",
90
- type=str,
91
- default="dataset",
92
- help="Hugging Face repo type. Default: dataset",
93
- )
94
- parser.add_argument(
95
- "--revision",
96
- type=str,
97
- default="main",
98
- help="Hugging Face revision/branch. Default: main",
99
- )
100
- parser.add_argument(
101
- "--token",
102
- type=str,
103
- default=None,
104
- help="Optional Hugging Face token for gated/private repos.",
105
- )
106
- parser.add_argument(
107
- "--keep_shard_structure",
108
- action="store_true",
109
- help="Save as output_dir/part_id/Split/ActivityType/*.zip instead of a flat folder.",
110
- )
111
- parser.add_argument(
112
- "--dry_run",
113
- action="store_true",
114
- help="Print planned downloads without downloading.",
115
- )
116
- parser.add_argument(
117
- "--overwrite",
118
- action="store_true",
119
- help="Overwrite local files if they already exist.",
120
- )
121
-
122
- args = parser.parse_args()
123
-
124
- selection = load_json(args.selection)
125
- repo_map = load_repo_map(args.repo_map)
126
- cases = selection.get("cases", [])
127
- if not isinstance(cases, list):
128
- raise ValueError("selection JSON must contain a list field named 'cases'.")
129
-
130
- args.output_dir.mkdir(parents=True, exist_ok=True)
131
-
132
- missing_parts = sorted({case["part_id"] for case in cases if case["part_id"] not in repo_map})
133
- if missing_parts:
134
- raise KeyError(
135
- "The following part IDs are missing from repo_map.json: "
136
- + ", ".join(missing_parts)
137
- )
138
-
139
- print(f"Cases to download: {len(cases)}")
140
- if args.dry_run:
141
- for case in cases[:20]:
142
- repo_id = repo_map[case["part_id"]]
143
- out_path = safe_output_path(args.output_dir, case, args.keep_shard_structure)
144
- print(f"{repo_id} :: {case['hf_zip_path']} -> {out_path}")
145
- if len(cases) > 20:
146
- print(f"... and {len(cases) - 20} more")
147
- return
148
-
149
- failures = []
150
- for case in tqdm(cases, desc="Downloading cases"):
151
- repo_id = repo_map[case["part_id"]]
152
- filename = case["hf_zip_path"]
153
- out_path = safe_output_path(args.output_dir, case, args.keep_shard_structure)
154
- out_path.parent.mkdir(parents=True, exist_ok=True)
155
-
156
- if out_path.exists() and not args.overwrite:
157
- continue
158
-
159
- try:
160
- cached_file = hf_hub_download(
161
- repo_id=repo_id,
162
- filename=filename,
163
- repo_type=args.repo_type,
164
- revision=args.revision,
165
- token=args.token,
166
- )
167
- shutil.copy2(cached_file, out_path)
168
- except Exception as exc: # Keep going and summarize failures.
169
- failures.append(
170
- {
171
- "case_id": case.get("case_id"),
172
- "part_id": case.get("part_id"),
173
- "repo_id": repo_id,
174
- "hf_zip_path": filename,
175
- "error": repr(exc),
176
- }
177
- )
178
-
179
- if failures:
180
- failure_path = args.output_dir / "download_failures.json"
181
- failure_path.write_text(json.dumps(failures, indent=2, ensure_ascii=False), encoding="utf-8")
182
- print(f"Finished with {len(failures)} failures. See: {failure_path}")
183
- else:
184
- print("All downloads completed successfully.")
185
-
186
-
187
- if __name__ == "__main__":
188
- main()
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
Utils/scripts/download_3d_assets.py DELETED
@@ -1,478 +0,0 @@
1
- #!/usr/bin/env python3
2
- """Download and assemble the PhysInOne validation 3D asset project."""
3
-
4
- from __future__ import annotations
5
-
6
- import argparse
7
- import filecmp
8
- import json
9
- import os
10
- import shutil
11
- import stat
12
- import sys
13
- import threading
14
- import zipfile
15
- from concurrent.futures import ThreadPoolExecutor, as_completed
16
- from dataclasses import dataclass
17
- from datetime import datetime, timezone
18
- from pathlib import Path, PurePosixPath
19
- from typing import Sequence
20
-
21
- try:
22
- from huggingface_hub import hf_hub_download
23
- except ImportError as exc: # pragma: no cover
24
- raise SystemExit(
25
- "Missing dependency: huggingface_hub. Install it with "
26
- "`pip install -U huggingface_hub tqdm`."
27
- ) from exc
28
-
29
- try:
30
- from tqdm import tqdm
31
- except ImportError: # pragma: no cover
32
- tqdm = None
33
-
34
-
35
- REPO_ID = "vLAR/PhysInOne"
36
- REPO_TYPE = "dataset"
37
- REMOTE_ROOT = "Assets/PhysicBenchmark"
38
- LOCAL_ROOT = PurePosixPath("assets/PhysicBenchmark")
39
- LIST_REPO_ROOT = "Utils/3d_assets_lists"
40
- LOCAL_LIST_ROOT = Path(__file__).resolve().parent.parent / "3d_assets_lists"
41
- FILE_LIST_NAME = "validation.txt"
42
- ARCHIVE_LIST_NAME = "validation_archives.txt"
43
- SUMMARY_NAME = "summary.json"
44
-
45
-
46
- def utc_now() -> str:
47
- return datetime.now(timezone.utc).isoformat(timespec="seconds")
48
-
49
-
50
- def safe_message(exc: BaseException) -> str:
51
- return " ".join(str(exc).replace("\t", " ").splitlines()).strip() or type(exc).__name__
52
-
53
-
54
- def read_lines(path: Path) -> list[str]:
55
- return [
56
- line.strip()
57
- for line in path.read_text(encoding="utf-8").splitlines()
58
- if line.strip() and not line.lstrip().startswith("#")
59
- ]
60
-
61
-
62
- def get_release_file(name: str, revision: str, cache_dir: Path) -> Path:
63
- local = LOCAL_LIST_ROOT / name
64
- if local.is_file():
65
- return local
66
- return Path(
67
- hf_hub_download(
68
- REPO_ID,
69
- f"{LIST_REPO_ROOT}/{name}",
70
- repo_type=REPO_TYPE,
71
- revision=revision,
72
- cache_dir=cache_dir,
73
- )
74
- )
75
-
76
-
77
- def load_release(revision: str, cache_dir: Path) -> tuple[list[str], list[str], dict]:
78
- files = read_lines(get_release_file(FILE_LIST_NAME, revision, cache_dir))
79
- archives = read_lines(get_release_file(ARCHIVE_LIST_NAME, revision, cache_dir))
80
- summary = json.loads(
81
- get_release_file(SUMMARY_NAME, revision, cache_dir).read_text(encoding="utf-8")
82
- )
83
- if not files or len(files) != len(set(files)) or files != sorted(files):
84
- raise RuntimeError("the validation 3D asset file list is empty, duplicated, or unsorted")
85
- if any(not path.startswith(REMOTE_ROOT + "/") for path in files):
86
- raise RuntimeError("a release path is outside the expected PhysicBenchmark root")
87
- if set(archives) != {path for path in files if path.lower().endswith(".zip")}:
88
- raise RuntimeError("the archive list does not match the validation file list")
89
- if any(PurePosixPath(path).name.casefold() == "train.zip" for path in files):
90
- raise RuntimeError("the validation release unexpectedly contains Train.zip")
91
- return files, archives, summary
92
-
93
-
94
- def local_path_for(remote_path: str, output_dir: Path) -> Path:
95
- if not remote_path.startswith(REMOTE_ROOT + "/"):
96
- raise RuntimeError(f"path is outside the expected asset root: {remote_path}")
97
- relative = PurePosixPath(remote_path[len(REMOTE_ROOT) + 1 :])
98
- if not relative.parts or any(part in {"", ".", ".."} for part in relative.parts):
99
- raise RuntimeError(f"unsafe relative path: {remote_path}")
100
- return output_dir.joinpath(*LOCAL_ROOT.parts, *relative.parts)
101
-
102
-
103
- def materialize_cached_file(cached: Path, destination: Path) -> str:
104
- source = cached.resolve()
105
- destination.parent.mkdir(parents=True, exist_ok=True)
106
- if destination.is_file() and destination.stat().st_size == source.stat().st_size:
107
- return "reused"
108
- if destination.exists():
109
- raise RuntimeError(f"local destination conflicts with the release: {destination}")
110
- temporary = destination.with_name(
111
- f".{destination.name}.materializing-{os.getpid()}-{threading.get_ident()}"
112
- )
113
- try:
114
- try:
115
- os.link(source, temporary)
116
- except OSError:
117
- shutil.copy2(source, temporary)
118
- os.replace(temporary, destination)
119
- finally:
120
- if temporary.exists():
121
- temporary.unlink()
122
- return "downloaded"
123
-
124
-
125
- def archive_marker(archive: Path) -> Path:
126
- return archive.parent / ".physinone_extract_status" / f"{archive.name}.json"
127
-
128
-
129
- def completed_removed_archive(archive: Path) -> bool:
130
- marker = archive_marker(archive)
131
- if archive.exists() or not marker.is_file():
132
- return False
133
- try:
134
- state = json.loads(marker.read_text(encoding="utf-8"))
135
- except (OSError, ValueError):
136
- return False
137
- return state.get("status") == "complete" and int(state.get("files", 0)) > 0
138
-
139
-
140
- def safe_zip_members(archive: zipfile.ZipFile) -> list[zipfile.ZipInfo]:
141
- members = archive.infolist()
142
- for info in members:
143
- path = PurePosixPath(info.filename)
144
- mode = (info.external_attr >> 16) & 0o170000
145
- if (
146
- path.is_absolute()
147
- or not path.parts
148
- or any(part in {"", ".", ".."} for part in path.parts)
149
- or mode == stat.S_IFLNK
150
- ):
151
- raise RuntimeError(f"unsafe ZIP member: {info.filename}")
152
- return members
153
-
154
-
155
- def members_complete(parent: Path, members: Sequence[zipfile.ZipInfo]) -> bool:
156
- files = [info for info in members if not info.is_dir()]
157
- return bool(files) and all(
158
- (parent.joinpath(*PurePosixPath(info.filename).parts)).is_file()
159
- and (parent.joinpath(*PurePosixPath(info.filename).parts)).stat().st_size
160
- == info.file_size
161
- for info in files
162
- )
163
-
164
-
165
- def merge_extracted_tree(temporary: Path, destination: Path) -> tuple[int, int]:
166
- added = 0
167
- reused = 0
168
- for source in sorted(temporary.rglob("*")):
169
- relative = source.relative_to(temporary)
170
- target = destination / relative
171
- if source.is_dir():
172
- target.mkdir(parents=True, exist_ok=True)
173
- continue
174
- target.parent.mkdir(parents=True, exist_ok=True)
175
- if target.exists():
176
- if not target.is_file():
177
- raise RuntimeError(f"extraction conflict with non-file path: {target}")
178
- if source.stat().st_size != target.stat().st_size or not filecmp.cmp(
179
- source, target, shallow=False
180
- ):
181
- raise RuntimeError(f"extraction would overwrite different data: {target}")
182
- source.unlink()
183
- reused += 1
184
- else:
185
- source.replace(target)
186
- added += 1
187
- return added, reused
188
-
189
-
190
- def extract_archive(archive_path: Path) -> tuple[str, int, int]:
191
- marker = archive_marker(archive_path)
192
- with zipfile.ZipFile(archive_path) as archive:
193
- members = safe_zip_members(archive)
194
- files = [info for info in members if not info.is_dir()]
195
- if members_complete(archive_path.parent, members):
196
- marker.parent.mkdir(exist_ok=True)
197
- marker.write_text(
198
- json.dumps(
199
- {
200
- "archive": archive_path.name,
201
- "archive_size": archive_path.stat().st_size,
202
- "files": len(files),
203
- "status": "complete",
204
- "verified_at": utc_now(),
205
- },
206
- sort_keys=True,
207
- )
208
- + "\n",
209
- encoding="utf-8",
210
- )
211
- return "already_extracted", 0, len(files)
212
-
213
- temporary_root = archive_path.parent / ".physinone_extracting"
214
- temporary = temporary_root / (
215
- f"{archive_path.stem}-{os.getpid()}-{threading.get_ident()}"
216
- )
217
- if temporary.exists():
218
- shutil.rmtree(temporary)
219
- temporary.mkdir(parents=True)
220
- try:
221
- archive.extractall(temporary)
222
- added, reused = merge_extracted_tree(temporary, archive_path.parent)
223
- finally:
224
- if temporary.exists():
225
- shutil.rmtree(temporary)
226
- if temporary_root.exists() and not any(temporary_root.iterdir()):
227
- temporary_root.rmdir()
228
-
229
- marker.parent.mkdir(exist_ok=True)
230
- marker.write_text(
231
- json.dumps(
232
- {
233
- "archive": archive_path.name,
234
- "archive_size": archive_path.stat().st_size,
235
- "files": len(files),
236
- "status": "complete",
237
- "verified_at": utc_now(),
238
- },
239
- sort_keys=True,
240
- )
241
- + "\n",
242
- encoding="utf-8",
243
- )
244
- return "extracted", added, reused
245
-
246
-
247
- @dataclass(frozen=True)
248
- class DownloadResult:
249
- remote_path: str
250
- local_path: str
251
- status: str
252
- error: str = ""
253
-
254
-
255
- class Logs:
256
- def __init__(self, root: Path) -> None:
257
- self.root = root
258
- self.root.mkdir(parents=True, exist_ok=True)
259
- self.downloads = root / "downloads.tsv"
260
- self.failures = root / "failures.tsv"
261
- self.extraction = root / "extraction.tsv"
262
- self.events = root / "events.jsonl"
263
- self._lock = threading.Lock()
264
- self.downloads.write_text(
265
- "remote_path\tlocal_path\tstatus\ttimestamp\n", encoding="utf-8"
266
- )
267
- self.failures.write_text(
268
- "stage\tpath\terror\ttimestamp\n", encoding="utf-8"
269
- )
270
- self.extraction.write_text(
271
- "archive\tstatus\tadded_files\treused_files\ttimestamp\n",
272
- encoding="utf-8",
273
- )
274
-
275
- def event(self, event: str, **fields: object) -> None:
276
- payload = {"event": event, "timestamp": utc_now(), **fields}
277
- with self._lock, self.events.open("a", encoding="utf-8") as handle:
278
- handle.write(json.dumps(payload, sort_keys=True) + "\n")
279
-
280
- def record_download(self, result: DownloadResult) -> None:
281
- timestamp = utc_now()
282
- with self._lock:
283
- if result.error:
284
- with self.failures.open("a", encoding="utf-8") as handle:
285
- handle.write(
286
- f"download\t{result.remote_path}\t{result.error}\t{timestamp}\n"
287
- )
288
- else:
289
- with self.downloads.open("a", encoding="utf-8") as handle:
290
- handle.write(
291
- f"{result.remote_path}\t{result.local_path}\t"
292
- f"{result.status}\t{timestamp}\n"
293
- )
294
- self.event(
295
- "download",
296
- remote_path=result.remote_path,
297
- local_path=result.local_path,
298
- status=result.status,
299
- error=result.error,
300
- )
301
-
302
- def record_extraction(
303
- self, archive: str, status: str, added: int, reused: int, error: str = ""
304
- ) -> None:
305
- timestamp = utc_now()
306
- with self._lock:
307
- if error:
308
- with self.failures.open("a", encoding="utf-8") as handle:
309
- handle.write(f"extract\t{archive}\t{error}\t{timestamp}\n")
310
- else:
311
- with self.extraction.open("a", encoding="utf-8") as handle:
312
- handle.write(
313
- f"{archive}\t{status}\t{added}\t{reused}\t{timestamp}\n"
314
- )
315
- self.event(
316
- "extraction",
317
- archive=archive,
318
- status=status,
319
- added_files=added,
320
- reused_files=reused,
321
- error=error,
322
- )
323
-
324
-
325
- def download_one(
326
- remote_path: str,
327
- output_dir: Path,
328
- cache_dir: Path,
329
- revision: str,
330
- skip_removed_archive: bool,
331
- ) -> DownloadResult:
332
- local_expected = local_path_for(remote_path, output_dir)
333
- if skip_removed_archive and completed_removed_archive(local_expected):
334
- return DownloadResult(remote_path, str(local_expected), "extracted_zip_removed")
335
- try:
336
- cached = Path(
337
- hf_hub_download(
338
- REPO_ID,
339
- remote_path,
340
- repo_type=REPO_TYPE,
341
- revision=revision,
342
- cache_dir=cache_dir,
343
- )
344
- )
345
- status = materialize_cached_file(cached, local_expected)
346
- return DownloadResult(remote_path, str(local_expected), status)
347
- except Exception as exc:
348
- return DownloadResult(remote_path, "", "failed", safe_message(exc))
349
-
350
-
351
- def build_parser() -> argparse.ArgumentParser:
352
- parser = argparse.ArgumentParser(
353
- description="Download and assemble the PhysInOne validation 3D asset project."
354
- )
355
- parser.add_argument(
356
- "--output-dir",
357
- type=Path,
358
- default=Path("PhysInOne-3D-Assets"),
359
- help=(
360
- "Local release root. The project will be stored at "
361
- "<output-dir>/assets/PhysicBenchmark."
362
- ),
363
- )
364
- parser.add_argument(
365
- "--workers", type=int, default=4, help="Concurrent downloads (default: 4)."
366
- )
367
- parser.add_argument("--revision", default="main", help="Dataset revision (default: main).")
368
- parser.add_argument(
369
- "--no-extract",
370
- action="store_true",
371
- help="Download the release without extracting its eight ZIP archives.",
372
- )
373
- parser.add_argument(
374
- "--delete-zip-after-extract",
375
- action="store_true",
376
- help="Delete each ZIP only after it is completely extracted and verified.",
377
- )
378
- parser.add_argument(
379
- "--dry-run", action="store_true", help="Show release statistics without downloading."
380
- )
381
- return parser
382
-
383
-
384
- def main(argv: Sequence[str] | None = None) -> int:
385
- args = build_parser().parse_args(argv)
386
- if args.workers < 1:
387
- raise SystemExit("--workers must be at least 1")
388
- if args.no_extract and args.delete_zip_after_extract:
389
- raise SystemExit("--delete-zip-after-extract cannot be combined with --no-extract")
390
-
391
- output_dir = args.output_dir.expanduser().resolve()
392
- cache_dir = output_dir / ".hf_cache"
393
- files, archives, release_summary = load_release(args.revision, cache_dir)
394
- print(
395
- f"Validation 3D assets: {len(files)} files, {len(archives)} ZIP archives, "
396
- f"{int(release_summary['bytes']) / (1024 ** 3):.2f} GiB download"
397
- )
398
- print(f"Project root: {output_dir.joinpath(*LOCAL_ROOT.parts)}")
399
- if args.dry_run:
400
- return 0
401
-
402
- output_dir.mkdir(parents=True, exist_ok=True)
403
- run_id = datetime.now().strftime("%Y%m%d_%H%M%S")
404
- logs = Logs(output_dir / "_3d_asset_download_logs" / run_id)
405
- results: list[DownloadResult] = []
406
- with ThreadPoolExecutor(max_workers=args.workers) as pool:
407
- futures = {
408
- pool.submit(
409
- download_one,
410
- path,
411
- output_dir,
412
- cache_dir,
413
- args.revision,
414
- args.delete_zip_after_extract,
415
- ): path
416
- for path in files
417
- }
418
- completed = as_completed(futures)
419
- if tqdm is not None:
420
- completed = tqdm(completed, total=len(futures), unit="file", desc="Download")
421
- for future in completed:
422
- result = future.result()
423
- logs.record_download(result)
424
- results.append(result)
425
-
426
- download_failures = [result for result in results if result.error]
427
- extraction_failures = 0
428
- extracted = 0
429
- if not args.no_extract:
430
- iterable = archives
431
- if tqdm is not None:
432
- iterable = tqdm(archives, unit="archive", desc="Extract")
433
- for remote_path in iterable:
434
- archive_path = local_path_for(remote_path, output_dir)
435
- if completed_removed_archive(archive_path):
436
- logs.record_extraction(remote_path, "already_extracted_zip_removed", 0, 0)
437
- extracted += 1
438
- continue
439
- if not archive_path.is_file():
440
- error = "archive is unavailable because its download failed"
441
- logs.record_extraction(remote_path, "failed", 0, 0, error)
442
- extraction_failures += 1
443
- continue
444
- try:
445
- status, added, reused = extract_archive(archive_path)
446
- logs.record_extraction(remote_path, status, added, reused)
447
- extracted += 1
448
- if args.delete_zip_after_extract:
449
- archive_path.unlink()
450
- except Exception as exc:
451
- logs.record_extraction(
452
- remote_path, "failed", 0, 0, safe_message(exc)
453
- )
454
- extraction_failures += 1
455
-
456
- summary = {
457
- "repo_id": REPO_ID,
458
- "revision": args.revision,
459
- "release": "validation",
460
- "expected_files": len(files),
461
- "successful_downloads": len(results) - len(download_failures),
462
- "download_failures": len(download_failures),
463
- "expected_archives": len(archives),
464
- "completed_archives": extracted,
465
- "extraction_failures": extraction_failures,
466
- "project_root": str(output_dir.joinpath(*LOCAL_ROOT.parts)),
467
- "log_dir": str(logs.root),
468
- "finished_at": utc_now(),
469
- }
470
- (logs.root / "summary.json").write_text(
471
- json.dumps(summary, indent=2, sort_keys=True) + "\n", encoding="utf-8"
472
- )
473
- print(json.dumps(summary, indent=2, sort_keys=True))
474
- return 1 if download_failures or extraction_failures else 0
475
-
476
-
477
- if __name__ == "__main__":
478
- raise SystemExit(main())
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
Utils/scripts/download_data.py ADDED
@@ -0,0 +1,720 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ #!/usr/bin/env python3
2
+ """Download public PhysInOne evaluation data and validation 3D assets."""
3
+
4
+ from __future__ import annotations
5
+
6
+ import argparse
7
+ import filecmp
8
+ import json
9
+ import os
10
+ import re
11
+ import shutil
12
+ import stat
13
+ import sys
14
+ import threading
15
+ import time
16
+ import urllib.error
17
+ import urllib.request
18
+ import zipfile
19
+ from concurrent.futures import ThreadPoolExecutor, as_completed
20
+ from dataclasses import dataclass
21
+ from datetime import datetime, timezone
22
+ from pathlib import Path, PurePosixPath
23
+ from typing import Iterable, Optional, Sequence
24
+ from urllib.parse import quote, unquote
25
+
26
+
27
+ REPOSITORY = "vLAR/PhysInOne"
28
+ LIST_ROOT = Path(__file__).resolve().parent / "download_lists"
29
+ CHUNK_SIZE = 8 * 1024 * 1024
30
+ USER_AGENT = "PhysInOne-public-downloader/1.0"
31
+
32
+
33
+ @dataclass(frozen=True)
34
+ class TaskSpec:
35
+ manifest: str
36
+ remote_prefix: str
37
+ local_root: str
38
+ extract_by_default: bool = False
39
+
40
+
41
+ TASKS = {
42
+ "video_generation": TaskSpec(
43
+ "video_generation.txt",
44
+ "Leaderboard/Video%20Generation/",
45
+ "leaderboard/video_generation",
46
+ ),
47
+ "future_prediction": TaskSpec(
48
+ "future_prediction.txt",
49
+ "Leaderboard/Future%20Prediction/",
50
+ "leaderboard/future_prediction",
51
+ ),
52
+ "physical_properties_estimation": TaskSpec(
53
+ "physical_properties_estimation.txt",
54
+ "Leaderboard/Physical%20Properties%20Estimation/",
55
+ "leaderboard/physical_properties_estimation",
56
+ ),
57
+ "motion_transfer": TaskSpec(
58
+ "motion_transfer.txt",
59
+ "Leaderboard/Motion%20Transfer/",
60
+ "leaderboard/motion_transfer",
61
+ ),
62
+ "3d_assets": TaskSpec(
63
+ "3d_assets.txt",
64
+ "Assets/PhysicBenchmark/",
65
+ "assets/PhysicBenchmark",
66
+ extract_by_default=True,
67
+ ),
68
+ }
69
+
70
+ ALIASES = {
71
+ "video": "video_generation",
72
+ "vg": "video_generation",
73
+ "future": "future_prediction",
74
+ "fp": "future_prediction",
75
+ "physical_properties": "physical_properties_estimation",
76
+ "physical_property_estimation": "physical_properties_estimation",
77
+ "ppe": "physical_properties_estimation",
78
+ "motion": "motion_transfer",
79
+ "mt": "motion_transfer",
80
+ "assets": "3d_assets",
81
+ "3d": "3d_assets",
82
+ }
83
+
84
+
85
+ def utc_now() -> str:
86
+ return datetime.now(timezone.utc).isoformat(timespec="seconds")
87
+
88
+
89
+ def safe_message(exc: BaseException) -> str:
90
+ message = " ".join(str(exc).replace("\t", " ").splitlines()).strip()
91
+ return message or type(exc).__name__
92
+
93
+
94
+ def normalize_task(value: str) -> str:
95
+ slug = value.strip().lower().replace("-", "_").replace(" ", "_")
96
+ slug = ALIASES.get(slug, slug)
97
+ if slug not in TASKS and slug != "all":
98
+ choices = ", ".join([*TASKS, "all"])
99
+ raise argparse.ArgumentTypeError(
100
+ f"unknown task {value!r}; choose one of: {choices}"
101
+ )
102
+ return slug
103
+
104
+
105
+ def selected_tasks(values: Sequence[str]) -> list[str]:
106
+ if not values or "all" in values:
107
+ return list(TASKS)
108
+ return list(dict.fromkeys(values))
109
+
110
+
111
+ def read_manifest(spec: TaskSpec) -> list[str]:
112
+ path = LIST_ROOT / spec.manifest
113
+ if not path.is_file():
114
+ raise RuntimeError(f"missing download manifest: {path}")
115
+ entries = [
116
+ line.strip()
117
+ for line in path.read_text(encoding="utf-8").splitlines()
118
+ if line.strip() and not line.lstrip().startswith("#")
119
+ ]
120
+ if not entries:
121
+ raise RuntimeError(f"empty download manifest: {path}")
122
+ if len(entries) != len(set(entries)):
123
+ raise RuntimeError(f"duplicate paths in download manifest: {path}")
124
+ invalid = [entry for entry in entries if not entry.startswith(spec.remote_prefix)]
125
+ if invalid:
126
+ raise RuntimeError(f"invalid path in {path.name}: {invalid[0]}")
127
+ for entry in entries:
128
+ validate_remote_path(entry)
129
+ return entries
130
+
131
+
132
+ def validate_remote_path(encoded_path: str) -> None:
133
+ decoded = unquote(encoded_path)
134
+ path = PurePosixPath(decoded)
135
+ if path.is_absolute() or not path.parts:
136
+ raise RuntimeError(f"unsafe remote path: {encoded_path}")
137
+ if any(part in {"", ".", ".."} for part in path.parts):
138
+ raise RuntimeError(f"unsafe remote path: {encoded_path}")
139
+ if "\\" in decoded or re.match(r"^[A-Za-z]:", decoded):
140
+ raise RuntimeError(f"unsafe remote path: {encoded_path}")
141
+
142
+
143
+ def local_path_for(output_dir: Path, spec: TaskSpec, remote_path: str) -> Path:
144
+ relative = unquote(remote_path[len(spec.remote_prefix) :])
145
+ parts = PurePosixPath(relative).parts
146
+ if not parts or any(part in {"", ".", ".."} for part in parts):
147
+ raise RuntimeError(f"unsafe relative path: {remote_path}")
148
+ if any(any(character.isspace() for character in part) for part in parts):
149
+ raise RuntimeError(f"local path would contain whitespace: {remote_path}")
150
+ return output_dir.joinpath(*PurePosixPath(spec.local_root).parts, *parts)
151
+
152
+
153
+ def filter_entries(entries: Iterable[str], scene_filters: Sequence[str]) -> list[str]:
154
+ filters = [item.casefold() for item in scene_filters if item.strip()]
155
+ if not filters:
156
+ return list(entries)
157
+ return [
158
+ entry
159
+ for entry in entries
160
+ if any(item in unquote(entry).casefold() for item in filters)
161
+ ]
162
+
163
+
164
+ def build_url(repository: str, revision: str, remote_path: str) -> str:
165
+ encoded_revision = quote(revision, safe="")
166
+ encoded_path = quote(unquote(remote_path), safe="/._-~")
167
+ return (
168
+ f"https://huggingface.co/datasets/{repository}/resolve/"
169
+ f"{encoded_revision}/{encoded_path}?download=true"
170
+ )
171
+
172
+
173
+ @dataclass(frozen=True)
174
+ class DownloadResult:
175
+ task: str
176
+ remote_path: str
177
+ local_path: str
178
+ status: str
179
+ bytes_written: int = 0
180
+ error: str = ""
181
+
182
+
183
+ def download_once(
184
+ url: str,
185
+ destination: Path,
186
+ timeout: float,
187
+ resume: bool,
188
+ ) -> tuple[str, int]:
189
+ destination.parent.mkdir(parents=True, exist_ok=True)
190
+ partial = destination.with_name(f"{destination.name}.part")
191
+ if not resume and partial.exists():
192
+ partial.unlink()
193
+
194
+ offset = partial.stat().st_size if partial.is_file() else 0
195
+ headers = {"User-Agent": USER_AGENT}
196
+ if offset:
197
+ headers["Range"] = f"bytes={offset}-"
198
+
199
+ request = urllib.request.Request(url, headers=headers)
200
+ try:
201
+ response = urllib.request.urlopen(request, timeout=timeout)
202
+ except urllib.error.HTTPError as exc:
203
+ if exc.code == 416 and offset:
204
+ content_range = exc.headers.get("Content-Range", "")
205
+ match = re.search(r"\*/(\d+)$", content_range)
206
+ if match and int(match.group(1)) == offset:
207
+ os.replace(partial, destination)
208
+ return "resumed", 0
209
+ raise
210
+
211
+ with response:
212
+ status_code = getattr(response, "status", response.getcode())
213
+ append = bool(offset and status_code == 206)
214
+ mode = "ab" if append else "wb"
215
+ starting_size = offset if append else 0
216
+ expected_raw = response.headers.get("Content-Length")
217
+ expected = int(expected_raw) if expected_raw and expected_raw.isdigit() else None
218
+ written = 0
219
+ with partial.open(mode) as handle:
220
+ while True:
221
+ chunk = response.read(CHUNK_SIZE)
222
+ if not chunk:
223
+ break
224
+ handle.write(chunk)
225
+ written += len(chunk)
226
+ if expected is not None and written != expected:
227
+ raise IOError(
228
+ f"incomplete response: expected {expected} bytes, received {written}"
229
+ )
230
+ if partial.stat().st_size != starting_size + written:
231
+ raise IOError("downloaded file size changed unexpectedly")
232
+
233
+ os.replace(partial, destination)
234
+ return ("resumed" if append else "downloaded"), written
235
+
236
+
237
+ def download_file(
238
+ task: str,
239
+ remote_path: str,
240
+ destination: Path,
241
+ revision: str,
242
+ timeout: float,
243
+ retries: int,
244
+ resume: bool,
245
+ force: bool,
246
+ skip_removed_archive: bool,
247
+ repository: str = REPOSITORY,
248
+ ) -> DownloadResult:
249
+ if skip_removed_archive and not destination.exists() and marker_matches(destination):
250
+ return DownloadResult(
251
+ task, remote_path, str(destination), "extracted_zip_removed"
252
+ )
253
+ if destination.is_file() and not force:
254
+ return DownloadResult(task, remote_path, str(destination), "reused")
255
+ if destination.exists() and not destination.is_file():
256
+ return DownloadResult(
257
+ task,
258
+ remote_path,
259
+ str(destination),
260
+ "failed",
261
+ error="download target exists and is not a file",
262
+ )
263
+ if force:
264
+ partial = destination.with_name(f"{destination.name}.part")
265
+ if partial.exists():
266
+ partial.unlink()
267
+
268
+ url = build_url(repository, revision, remote_path)
269
+ error = ""
270
+ for attempt in range(retries + 1):
271
+ try:
272
+ status, written = download_once(url, destination, timeout, resume)
273
+ return DownloadResult(
274
+ task, remote_path, str(destination), status, bytes_written=written
275
+ )
276
+ except Exception as exc: # continue independent downloads and report every failure
277
+ error = safe_message(exc)
278
+ if attempt < retries:
279
+ time.sleep(min(2**attempt, 8))
280
+ return DownloadResult(
281
+ task, remote_path, str(destination), "failed", error=error
282
+ )
283
+
284
+
285
+ def is_safe_zip_member(info: zipfile.ZipInfo) -> bool:
286
+ raw = info.filename
287
+ normalized = raw.replace("\\", "/")
288
+ path = PurePosixPath(normalized)
289
+ if raw != normalized or path.is_absolute() or not path.parts:
290
+ return False
291
+ if any(part in {"", ".", ".."} for part in path.parts):
292
+ return False
293
+ if re.match(r"^[A-Za-z]:", normalized):
294
+ return False
295
+ mode = (info.external_attr >> 16) & 0o170000
296
+ return mode != stat.S_IFLNK
297
+
298
+
299
+ def extraction_marker(archive: Path) -> Path:
300
+ return archive.parent / ".physinone_extract_status" / f"{archive.name}.json"
301
+
302
+
303
+ def marker_matches(archive: Path, destination_required: Optional[Path] = None) -> bool:
304
+ marker = extraction_marker(archive)
305
+ if not marker.is_file():
306
+ return False
307
+ if destination_required is not None and not destination_required.is_dir():
308
+ return False
309
+ try:
310
+ state = json.loads(marker.read_text(encoding="utf-8"))
311
+ except (OSError, ValueError):
312
+ return False
313
+ if archive.is_file():
314
+ return state.get("archive_size") == archive.stat().st_size
315
+ return state.get("archive_removed") is True
316
+
317
+
318
+ def write_extraction_marker(archive: Path, file_count: int, removed: bool = False) -> None:
319
+ marker = extraction_marker(archive)
320
+ marker.parent.mkdir(parents=True, exist_ok=True)
321
+ payload = {
322
+ "archive": archive.name,
323
+ "archive_size": archive.stat().st_size if archive.is_file() else None,
324
+ "archive_removed": removed,
325
+ "files": file_count,
326
+ "status": "complete",
327
+ "verified_at": utc_now(),
328
+ }
329
+ marker.write_text(json.dumps(payload, sort_keys=True) + "\n", encoding="utf-8")
330
+
331
+
332
+ def inspect_archive(archive: zipfile.ZipFile) -> list[zipfile.ZipInfo]:
333
+ members = archive.infolist()
334
+ unsafe = [info.filename for info in members if not is_safe_zip_member(info)]
335
+ if unsafe:
336
+ raise RuntimeError(f"unsafe ZIP member: {unsafe[0]}")
337
+ bad = archive.testzip()
338
+ if bad is not None:
339
+ raise RuntimeError(f"ZIP CRC check failed at {bad}")
340
+ return members
341
+
342
+
343
+ def extract_scene_archive(archive_path: Path) -> tuple[str, int, int]:
344
+ destination = archive_path.with_suffix("")
345
+ if marker_matches(archive_path, destination):
346
+ return "already_extracted", 0, 0
347
+ if destination.exists():
348
+ raise RuntimeError(
349
+ f"extraction target exists without a matching marker: {destination}"
350
+ )
351
+ temporary = archive_path.parent / (
352
+ f".{archive_path.stem}.extracting-{os.getpid()}-{threading.get_ident()}"
353
+ )
354
+ if temporary.exists():
355
+ shutil.rmtree(temporary)
356
+ temporary.mkdir(parents=False)
357
+ try:
358
+ with zipfile.ZipFile(archive_path) as archive:
359
+ members = inspect_archive(archive)
360
+ roots = {PurePosixPath(info.filename).parts[0] for info in members}
361
+ if roots != {archive_path.stem}:
362
+ raise RuntimeError(
363
+ f"unexpected ZIP roots {sorted(roots)}; expected {archive_path.stem!r}"
364
+ )
365
+ archive.extractall(temporary)
366
+ extracted = temporary / archive_path.stem
367
+ if not extracted.is_dir():
368
+ raise RuntimeError("archive did not create the expected scene directory")
369
+ extracted.replace(destination)
370
+ file_count = sum(1 for info in members if not info.is_dir())
371
+ write_extraction_marker(archive_path, file_count)
372
+ return "extracted", file_count, 0
373
+ finally:
374
+ if temporary.exists():
375
+ shutil.rmtree(temporary)
376
+
377
+
378
+ def merge_tree(source_root: Path, destination_root: Path) -> tuple[int, int]:
379
+ added = 0
380
+ reused = 0
381
+ for source in sorted(source_root.rglob("*")):
382
+ relative = source.relative_to(source_root)
383
+ destination = destination_root / relative
384
+ if source.is_dir():
385
+ destination.mkdir(parents=True, exist_ok=True)
386
+ continue
387
+ destination.parent.mkdir(parents=True, exist_ok=True)
388
+ if destination.exists():
389
+ if not destination.is_file():
390
+ raise RuntimeError(f"extraction conflict: {destination}")
391
+ if source.stat().st_size != destination.stat().st_size or not filecmp.cmp(
392
+ source, destination, shallow=False
393
+ ):
394
+ raise RuntimeError(f"extraction would overwrite different data: {destination}")
395
+ source.unlink()
396
+ reused += 1
397
+ else:
398
+ source.replace(destination)
399
+ added += 1
400
+ return added, reused
401
+
402
+
403
+ def extract_asset_archive(archive_path: Path) -> tuple[str, int, int]:
404
+ if marker_matches(archive_path):
405
+ return "already_extracted", 0, 0
406
+ temporary_root = archive_path.parent / ".physinone_extracting"
407
+ temporary = temporary_root / (
408
+ f"{archive_path.stem}-{os.getpid()}-{threading.get_ident()}"
409
+ )
410
+ if temporary.exists():
411
+ shutil.rmtree(temporary)
412
+ temporary.mkdir(parents=True)
413
+ try:
414
+ with zipfile.ZipFile(archive_path) as archive:
415
+ members = inspect_archive(archive)
416
+ archive.extractall(temporary)
417
+ added, reused = merge_tree(temporary, archive_path.parent)
418
+ file_count = sum(1 for info in members if not info.is_dir())
419
+ write_extraction_marker(archive_path, file_count)
420
+ return "extracted", added, reused
421
+ finally:
422
+ if temporary.exists():
423
+ shutil.rmtree(temporary)
424
+ if temporary_root.exists() and not any(temporary_root.iterdir()):
425
+ temporary_root.rmdir()
426
+
427
+
428
+ @dataclass(frozen=True)
429
+ class ExtractionResult:
430
+ task: str
431
+ archive: str
432
+ status: str
433
+ added: int = 0
434
+ reused: int = 0
435
+ error: str = ""
436
+
437
+
438
+ class RunLogs:
439
+ def __init__(self, root: Path) -> None:
440
+ self.root = root
441
+ self.root.mkdir(parents=True, exist_ok=True)
442
+ self.downloads = root / "downloads.tsv"
443
+ self.extractions = root / "extractions.tsv"
444
+ self.failures = root / "failures.tsv"
445
+ self._lock = threading.Lock()
446
+ self.downloads.write_text(
447
+ "task\tremote_path\tlocal_path\tstatus\tbytes_written\ttimestamp\n",
448
+ encoding="utf-8",
449
+ )
450
+ self.extractions.write_text(
451
+ "task\tarchive\tstatus\tadded\treused\ttimestamp\n",
452
+ encoding="utf-8",
453
+ )
454
+ self.failures.write_text(
455
+ "stage\ttask\tpath\terror\ttimestamp\n", encoding="utf-8"
456
+ )
457
+
458
+ def record_download(self, result: DownloadResult) -> None:
459
+ now = utc_now()
460
+ with self._lock:
461
+ if result.error:
462
+ with self.failures.open("a", encoding="utf-8") as handle:
463
+ handle.write(
464
+ f"download\t{result.task}\t{result.remote_path}\t"
465
+ f"{result.error}\t{now}\n"
466
+ )
467
+ else:
468
+ with self.downloads.open("a", encoding="utf-8") as handle:
469
+ handle.write(
470
+ f"{result.task}\t{result.remote_path}\t{result.local_path}\t"
471
+ f"{result.status}\t{result.bytes_written}\t{now}\n"
472
+ )
473
+
474
+ def record_extraction(self, result: ExtractionResult) -> None:
475
+ now = utc_now()
476
+ with self._lock:
477
+ if result.error:
478
+ with self.failures.open("a", encoding="utf-8") as handle:
479
+ handle.write(
480
+ f"extract\t{result.task}\t{result.archive}\t"
481
+ f"{result.error}\t{now}\n"
482
+ )
483
+ else:
484
+ with self.extractions.open("a", encoding="utf-8") as handle:
485
+ handle.write(
486
+ f"{result.task}\t{result.archive}\t{result.status}\t"
487
+ f"{result.added}\t{result.reused}\t{now}\n"
488
+ )
489
+
490
+
491
+ def should_extract(task: str, requested: Optional[bool]) -> bool:
492
+ if requested is not None:
493
+ return requested
494
+ return TASKS[task].extract_by_default
495
+
496
+
497
+ def extract_download(
498
+ task: str,
499
+ archive: Path,
500
+ delete_after: bool,
501
+ ) -> ExtractionResult:
502
+ try:
503
+ if task == "3d_assets":
504
+ status, added, reused = extract_asset_archive(archive)
505
+ else:
506
+ status, added, reused = extract_scene_archive(archive)
507
+ if delete_after and archive.is_file():
508
+ file_count = added + reused
509
+ archive.unlink()
510
+ write_extraction_marker(archive, file_count, removed=True)
511
+ return ExtractionResult(task, str(archive), status, added, reused)
512
+ except Exception as exc:
513
+ return ExtractionResult(
514
+ task, str(archive), "failed", error=safe_message(exc)
515
+ )
516
+
517
+
518
+ def build_parser() -> argparse.ArgumentParser:
519
+ parser = argparse.ArgumentParser(
520
+ description=(
521
+ "Download public PhysInOne Leaderboard data and validation 3D assets "
522
+ "with Python standard-library networking."
523
+ )
524
+ )
525
+ parser.add_argument(
526
+ "--task",
527
+ nargs="+",
528
+ type=normalize_task,
529
+ default=["all"],
530
+ help=(
531
+ "Task(s): video_generation, future_prediction, "
532
+ "physical_properties_estimation, motion_transfer, 3d_assets, or all."
533
+ ),
534
+ )
535
+ parser.add_argument(
536
+ "--output-dir",
537
+ type=Path,
538
+ default=Path("PhysInOne_data"),
539
+ help="Local output root without spaces (default: ./PhysInOne_data).",
540
+ )
541
+ parser.add_argument(
542
+ "--scene",
543
+ action="append",
544
+ default=[],
545
+ help="Keep paths containing this scene name or six-character ID; repeatable.",
546
+ )
547
+ parser.add_argument(
548
+ "--workers", type=int, default=4, help="Concurrent downloads (default: 4)."
549
+ )
550
+ parser.add_argument(
551
+ "--revision", default="main", help="Dataset revision (default: main)."
552
+ )
553
+ parser.add_argument(
554
+ "--retries", type=int, default=3, help="Retries after each failure (default: 3)."
555
+ )
556
+ parser.add_argument(
557
+ "--timeout",
558
+ type=float,
559
+ default=60.0,
560
+ help="Network timeout in seconds (default: 60).",
561
+ )
562
+ extraction = parser.add_mutually_exclusive_group()
563
+ extraction.add_argument(
564
+ "--extract", dest="extract", action="store_true", help="Safely extract ZIP files."
565
+ )
566
+ extraction.add_argument(
567
+ "--no-extract",
568
+ dest="extract",
569
+ action="store_false",
570
+ help="Keep all ZIP files compressed.",
571
+ )
572
+ parser.set_defaults(extract=None)
573
+ parser.add_argument(
574
+ "--delete-zip-after-extract",
575
+ action="store_true",
576
+ help="Delete a ZIP only after successful extraction.",
577
+ )
578
+ parser.add_argument(
579
+ "--no-resume",
580
+ action="store_true",
581
+ help="Restart incomplete .part files instead of resuming them.",
582
+ )
583
+ parser.add_argument(
584
+ "--force", action="store_true", help="Replace completed local downloads."
585
+ )
586
+ parser.add_argument(
587
+ "--list-only", action="store_true", help="Print selected public URLs and exit."
588
+ )
589
+ parser.add_argument(
590
+ "--dry-run", action="store_true", help="Show counts and output paths without downloading."
591
+ )
592
+ return parser
593
+
594
+
595
+ def main(argv: Optional[Sequence[str]] = None) -> int:
596
+ args = build_parser().parse_args(argv)
597
+ if args.workers < 1:
598
+ raise SystemExit("--workers must be at least 1")
599
+ if args.retries < 0:
600
+ raise SystemExit("--retries cannot be negative")
601
+ if args.timeout <= 0:
602
+ raise SystemExit("--timeout must be positive")
603
+ if args.delete_zip_after_extract and args.extract is False:
604
+ raise SystemExit("--delete-zip-after-extract cannot be used with --no-extract")
605
+ if any(character.isspace() for character in str(args.output_dir)):
606
+ raise SystemExit("--output-dir must not contain whitespace")
607
+
608
+ tasks = selected_tasks(args.task)
609
+ output_dir = args.output_dir.expanduser().resolve()
610
+ selections: list[tuple[str, str, Path]] = []
611
+ counts: dict[str, int] = {}
612
+ for task in tasks:
613
+ spec = TASKS[task]
614
+ entries = filter_entries(read_manifest(spec), args.scene)
615
+ counts[task] = len(entries)
616
+ selections.extend(
617
+ (task, entry, local_path_for(output_dir, spec, entry))
618
+ for entry in entries
619
+ )
620
+
621
+ for task in tasks:
622
+ print(f"{task}: {counts[task]} file(s)")
623
+ print(f"total: {len(selections)} file(s)")
624
+ if args.scene and not selections:
625
+ print("No files matched --scene.", file=sys.stderr)
626
+ return 2
627
+ if args.list_only:
628
+ for _, remote_path, _ in selections:
629
+ print(build_url(REPOSITORY, args.revision, remote_path))
630
+ return 0
631
+ if args.dry_run:
632
+ for task in tasks:
633
+ print(f"{task} -> {output_dir / TASKS[task].local_root}")
634
+ return 0
635
+
636
+ output_dir.mkdir(parents=True, exist_ok=True)
637
+ run_id = datetime.now().strftime("%Y%m%d_%H%M%S")
638
+ logs = RunLogs(output_dir / "_download_logs" / run_id)
639
+ results: list[DownloadResult] = []
640
+ with ThreadPoolExecutor(max_workers=args.workers) as pool:
641
+ futures = {
642
+ pool.submit(
643
+ download_file,
644
+ task,
645
+ remote_path,
646
+ destination,
647
+ args.revision,
648
+ args.timeout,
649
+ args.retries,
650
+ not args.no_resume,
651
+ args.force,
652
+ (
653
+ args.delete_zip_after_extract
654
+ and should_extract(task, args.extract)
655
+ and remote_path.lower().endswith(".zip")
656
+ ),
657
+ ): (task, remote_path)
658
+ for task, remote_path, destination in selections
659
+ }
660
+ total = len(futures)
661
+ for completed, future in enumerate(as_completed(futures), start=1):
662
+ result = future.result()
663
+ results.append(result)
664
+ logs.record_download(result)
665
+ label = result.status if not result.error else f"failed: {result.error}"
666
+ print(f"[{completed}/{total}] {result.task}: {label}: {result.remote_path}")
667
+
668
+ extraction_results: list[ExtractionResult] = []
669
+ successful = {
670
+ (result.task, result.remote_path): Path(result.local_path)
671
+ for result in results
672
+ if not result.error
673
+ }
674
+ for task, remote_path, destination in selections:
675
+ if not remote_path.lower().endswith(".zip"):
676
+ continue
677
+ if not should_extract(task, args.extract):
678
+ continue
679
+ archive = successful.get((task, remote_path), destination)
680
+ marker = extraction_marker(archive)
681
+ if not archive.is_file() and marker_matches(archive):
682
+ result = ExtractionResult(task, str(archive), "already_extracted_zip_removed")
683
+ elif not archive.is_file():
684
+ result = ExtractionResult(
685
+ task,
686
+ str(archive),
687
+ "failed",
688
+ error="archive is unavailable because its download failed",
689
+ )
690
+ else:
691
+ result = extract_download(task, archive, args.delete_zip_after_extract)
692
+ extraction_results.append(result)
693
+ logs.record_extraction(result)
694
+ label = result.status if not result.error else f"failed: {result.error}"
695
+ print(f"[extract] {task}: {label}: {archive}")
696
+
697
+ download_failures = sum(1 for result in results if result.error)
698
+ extraction_failures = sum(1 for result in extraction_results if result.error)
699
+ summary = {
700
+ "repository": REPOSITORY,
701
+ "revision": args.revision,
702
+ "tasks": tasks,
703
+ "selected_files": len(selections),
704
+ "successful_downloads": len(results) - download_failures,
705
+ "download_failures": download_failures,
706
+ "completed_extractions": len(extraction_results) - extraction_failures,
707
+ "extraction_failures": extraction_failures,
708
+ "output_dir": str(output_dir),
709
+ "log_dir": str(logs.root),
710
+ "finished_at": utc_now(),
711
+ }
712
+ (logs.root / "summary.json").write_text(
713
+ json.dumps(summary, indent=2, sort_keys=True) + "\n", encoding="utf-8"
714
+ )
715
+ print(json.dumps(summary, indent=2, sort_keys=True))
716
+ return 1 if download_failures or extraction_failures else 0
717
+
718
+
719
+ if __name__ == "__main__":
720
+ raise SystemExit(main())
Utils/scripts/download_leaderboard.py DELETED
@@ -1,480 +0,0 @@
1
- #!/usr/bin/env python3
2
- """Download public PhysInOne Leaderboard evaluation data.
3
-
4
- The script uses release-maintained, task-specific file lists so every download
5
- is explicit, reproducible, resumable, and limited to the requested tasks.
6
- """
7
-
8
- from __future__ import annotations
9
-
10
- import argparse
11
- import json
12
- import os
13
- import shutil
14
- import stat
15
- import sys
16
- import threading
17
- import zipfile
18
- from concurrent.futures import ThreadPoolExecutor, as_completed
19
- from dataclasses import dataclass
20
- from datetime import datetime, timezone
21
- from pathlib import Path, PurePosixPath
22
- from typing import Iterable, Sequence
23
-
24
- try:
25
- from huggingface_hub import hf_hub_download
26
- except ImportError as exc: # pragma: no cover - exercised by users without the dependency
27
- raise SystemExit(
28
- "Missing dependency: huggingface_hub. Install it with "
29
- "`pip install -U huggingface_hub tqdm`."
30
- ) from exc
31
-
32
- try:
33
- from tqdm import tqdm
34
- except ImportError: # pragma: no cover - tqdm is optional
35
- tqdm = None
36
-
37
-
38
- REPO_ID = "vLAR/PhysInOne"
39
- REPO_TYPE = "dataset"
40
- TASKS = {
41
- "video-generation": {
42
- "display": "Video Generation",
43
- "local_root": "video_generation",
44
- "list": "video-generation.txt",
45
- },
46
- "future-prediction": {
47
- "display": "Future Prediction",
48
- "local_root": "future_prediction",
49
- "list": "future-prediction.txt",
50
- },
51
- "physical-properties-estimation": {
52
- "display": "Physical Properties Estimation",
53
- "local_root": "physical_properties_estimation",
54
- "list": "physical-properties-estimation.txt",
55
- },
56
- "motion-transfer": {
57
- "display": "Motion Transfer",
58
- "local_root": "motion_transfer",
59
- "list": "motion-transfer.txt",
60
- },
61
- }
62
- ALIASES = {
63
- "video": "video-generation",
64
- "vg": "video-generation",
65
- "future": "future-prediction",
66
- "fp": "future-prediction",
67
- "physical-properties": "physical-properties-estimation",
68
- "physical-property-estimation": "physical-properties-estimation",
69
- "ppe": "physical-properties-estimation",
70
- "motion": "motion-transfer",
71
- "mt": "motion-transfer",
72
- }
73
- LIST_REPO_ROOT = "Utils/leaderboard_lists"
74
- LOCAL_LIST_ROOT = Path(__file__).resolve().parent.parent / "leaderboard_lists"
75
-
76
-
77
- def utc_now() -> str:
78
- return datetime.now(timezone.utc).isoformat(timespec="seconds")
79
-
80
-
81
- def safe_message(exc: BaseException) -> str:
82
- return " ".join(str(exc).replace("\t", " ").splitlines()).strip() or type(exc).__name__
83
-
84
-
85
- def normalize_task(value: str) -> str:
86
- slug = value.strip().lower().replace("_", "-").replace(" ", "-")
87
- slug = ALIASES.get(slug, slug)
88
- if slug not in TASKS and slug != "all":
89
- choices = ", ".join([*TASKS, "all"])
90
- raise argparse.ArgumentTypeError(f"unknown task {value!r}; choose one of: {choices}")
91
- return slug
92
-
93
-
94
- def selected_tasks(values: Sequence[str]) -> list[str]:
95
- if not values or "all" in values:
96
- return list(TASKS)
97
- return list(dict.fromkeys(values))
98
-
99
-
100
- def read_lines(path: Path) -> list[str]:
101
- lines = []
102
- for raw in path.read_text(encoding="utf-8").splitlines():
103
- line = raw.strip()
104
- if line and not line.startswith("#"):
105
- lines.append(line)
106
- return lines
107
-
108
-
109
- def get_task_list(task: str, revision: str, cache_dir: Path) -> list[str]:
110
- filename = str(TASKS[task]["list"])
111
- local = LOCAL_LIST_ROOT / filename
112
- if not local.is_file():
113
- remote = f"{LIST_REPO_ROOT}/{filename}"
114
- local = Path(
115
- hf_hub_download(
116
- repo_id=REPO_ID,
117
- repo_type=REPO_TYPE,
118
- filename=remote,
119
- revision=revision,
120
- cache_dir=cache_dir,
121
- )
122
- )
123
- paths = read_lines(local)
124
- expected_root = f"Leaderboard/{TASKS[task]['display']}/"
125
- invalid = [path for path in paths if not path.startswith(expected_root)]
126
- if invalid:
127
- raise RuntimeError(f"invalid path in {filename}: {invalid[0]}")
128
- if len(paths) != len(set(paths)):
129
- raise RuntimeError(f"duplicate paths found in {filename}")
130
- return paths
131
-
132
-
133
- def filter_scenes(paths: Iterable[str], scene_filters: Sequence[str]) -> list[str]:
134
- filters = [item.casefold() for item in scene_filters if item.strip()]
135
- if not filters:
136
- return list(paths)
137
- return [path for path in paths if any(item in path.casefold() for item in filters)]
138
-
139
-
140
- def local_path_for(task: str, remote_path: str, output_dir: Path) -> Path:
141
- remote_root = f"Leaderboard/{TASKS[task]['display']}/"
142
- if not remote_path.startswith(remote_root):
143
- raise RuntimeError(f"path is outside the expected task root: {remote_path}")
144
- relative = PurePosixPath(remote_path[len(remote_root) :])
145
- if not relative.parts or any(part in {"", ".", ".."} for part in relative.parts):
146
- raise RuntimeError(f"unsafe relative path: {remote_path}")
147
- return output_dir.joinpath(
148
- "leaderboard", str(TASKS[task]["local_root"]), *relative.parts
149
- )
150
-
151
-
152
- def materialize_cached_file(cached: Path, destination: Path) -> str:
153
- """Place a cached file at its normalized public path without duplicating bytes."""
154
- source = cached.resolve()
155
- destination.parent.mkdir(parents=True, exist_ok=True)
156
- if destination.is_file() and destination.stat().st_size == source.stat().st_size:
157
- return "reused"
158
- if destination.exists():
159
- raise RuntimeError(f"local destination conflicts with the release: {destination}")
160
- temporary = destination.with_name(
161
- f".{destination.name}.materializing-{os.getpid()}-{threading.get_ident()}"
162
- )
163
- try:
164
- try:
165
- os.link(source, temporary)
166
- except OSError:
167
- shutil.copy2(source, temporary)
168
- os.replace(temporary, destination)
169
- finally:
170
- if temporary.exists():
171
- temporary.unlink()
172
- return "downloaded"
173
-
174
-
175
- def is_safe_zip_member(info: zipfile.ZipInfo) -> bool:
176
- path = PurePosixPath(info.filename)
177
- if path.is_absolute() or not path.parts:
178
- return False
179
- if any(part in {"", ".", ".."} for part in path.parts):
180
- return False
181
- mode = (info.external_attr >> 16) & 0o170000
182
- return mode != stat.S_IFLNK
183
-
184
-
185
- def extract_scene_zip(zip_path: Path) -> str:
186
- """Safely extract a scene archive next to the ZIP and return its root path."""
187
- expected_root = zip_path.stem
188
- destination = zip_path.parent / expected_root
189
- marker_dir = zip_path.parent / ".physinone_extract_status"
190
- marker = marker_dir / f"{zip_path.name}.json"
191
- archive_stat = zip_path.stat()
192
-
193
- if marker.is_file() and destination.is_dir():
194
- try:
195
- state = json.loads(marker.read_text(encoding="utf-8"))
196
- if state.get("archive_size") == archive_stat.st_size:
197
- return "already_extracted"
198
- except (OSError, ValueError):
199
- pass
200
- if destination.exists():
201
- raise RuntimeError(
202
- f"extraction target already exists without a matching completion marker: {destination}"
203
- )
204
-
205
- temporary = zip_path.parent / (
206
- f".{expected_root}.extracting-{os.getpid()}-{threading.get_ident()}"
207
- )
208
- if temporary.exists():
209
- shutil.rmtree(temporary)
210
- temporary.mkdir(parents=False)
211
- try:
212
- with zipfile.ZipFile(zip_path) as archive:
213
- members = archive.infolist()
214
- unsafe = [info.filename for info in members if not is_safe_zip_member(info)]
215
- if unsafe:
216
- raise RuntimeError(f"unsafe ZIP member: {unsafe[0]}")
217
- roots = {PurePosixPath(info.filename).parts[0] for info in members}
218
- if roots != {expected_root}:
219
- raise RuntimeError(
220
- f"unexpected ZIP root(s) {sorted(roots)}; expected {expected_root!r}"
221
- )
222
- bad = archive.testzip()
223
- if bad is not None:
224
- raise RuntimeError(f"ZIP CRC check failed at {bad}")
225
- archive.extractall(temporary)
226
- extracted = temporary / expected_root
227
- if not extracted.is_dir():
228
- raise RuntimeError(f"archive did not create the expected scene directory: {expected_root}")
229
- extracted.replace(destination)
230
- marker_dir.mkdir(exist_ok=True)
231
- marker.write_text(
232
- json.dumps(
233
- {
234
- "archive": zip_path.name,
235
- "archive_size": archive_stat.st_size,
236
- "extracted_at": utc_now(),
237
- },
238
- sort_keys=True,
239
- )
240
- + "\n",
241
- encoding="utf-8",
242
- )
243
- return "extracted"
244
- finally:
245
- if temporary.exists():
246
- shutil.rmtree(temporary)
247
-
248
-
249
- @dataclass(frozen=True)
250
- class Result:
251
- task: str
252
- remote_path: str
253
- local_path: str
254
- status: str
255
- extracted: str
256
- error: str = ""
257
-
258
-
259
- class Logs:
260
- def __init__(self, root: Path) -> None:
261
- self.root = root
262
- self.root.mkdir(parents=True, exist_ok=True)
263
- self.success = self.root / "success.tsv"
264
- self.failures = self.root / "failures.tsv"
265
- self.events = self.root / "events.jsonl"
266
- self._lock = threading.Lock()
267
- self.success.write_text(
268
- "task\tremote_path\tlocal_path\tstatus\textracted\ttimestamp\n",
269
- encoding="utf-8",
270
- )
271
- self.failures.write_text(
272
- "task\tremote_path\terror\ttimestamp\n",
273
- encoding="utf-8",
274
- )
275
-
276
- def record(self, result: Result) -> None:
277
- timestamp = utc_now()
278
- with self._lock:
279
- if result.error:
280
- with self.failures.open("a", encoding="utf-8") as handle:
281
- handle.write(
282
- f"{result.task}\t{result.remote_path}\t{result.error}\t{timestamp}\n"
283
- )
284
- else:
285
- with self.success.open("a", encoding="utf-8") as handle:
286
- handle.write(
287
- f"{result.task}\t{result.remote_path}\t{result.local_path}\t"
288
- f"{result.status}\t{result.extracted}\t{timestamp}\n"
289
- )
290
- with self.events.open("a", encoding="utf-8") as handle:
291
- handle.write(
292
- json.dumps(
293
- {
294
- "task": result.task,
295
- "remote_path": result.remote_path,
296
- "local_path": result.local_path,
297
- "status": result.status,
298
- "extracted": result.extracted,
299
- "error": result.error,
300
- "timestamp": timestamp,
301
- },
302
- sort_keys=True,
303
- )
304
- + "\n"
305
- )
306
-
307
-
308
- def download_one(
309
- task: str,
310
- remote_path: str,
311
- output_dir: Path,
312
- cache_dir: Path,
313
- revision: str,
314
- extract: bool,
315
- delete_zip: bool,
316
- ) -> Result:
317
- try:
318
- cached = Path(
319
- hf_hub_download(
320
- repo_id=REPO_ID,
321
- repo_type=REPO_TYPE,
322
- filename=remote_path,
323
- revision=revision,
324
- cache_dir=cache_dir,
325
- )
326
- )
327
- local = local_path_for(task, remote_path, output_dir)
328
- status = materialize_cached_file(cached, local)
329
- extracted = "not_requested"
330
- if extract and local.suffix.lower() == ".zip":
331
- extracted = extract_scene_zip(local)
332
- if delete_zip:
333
- local.unlink()
334
- elif extract:
335
- extracted = "not_a_zip"
336
- return Result(task, remote_path, str(local), status, extracted)
337
- except Exception as exc: # keep other downloads running and report all failures
338
- return Result(task, remote_path, "", "failed", "not_extracted", safe_message(exc))
339
-
340
-
341
- def build_parser() -> argparse.ArgumentParser:
342
- parser = argparse.ArgumentParser(
343
- description="Download public PhysInOne Leaderboard evaluation data."
344
- )
345
- parser.add_argument(
346
- "--task",
347
- nargs="+",
348
- type=normalize_task,
349
- default=["all"],
350
- help=(
351
- "Task(s) to download: video-generation, future-prediction, "
352
- "physical-properties-estimation, motion-transfer, or all."
353
- ),
354
- )
355
- parser.add_argument(
356
- "--output-dir",
357
- type=Path,
358
- default=Path("PhysInOne-Leaderboard"),
359
- help="Local dataset root (default: ./PhysInOne-Leaderboard).",
360
- )
361
- parser.add_argument(
362
- "--scene",
363
- action="append",
364
- default=[],
365
- help="Download only paths containing this scene name or six-character ID; repeatable.",
366
- )
367
- parser.add_argument(
368
- "--workers",
369
- type=int,
370
- default=4,
371
- help="Concurrent file downloads (default: 4).",
372
- )
373
- parser.add_argument("--revision", default="main", help="Dataset revision (default: main).")
374
- parser.add_argument(
375
- "--extract",
376
- action="store_true",
377
- help="Validate and safely extract downloaded scene ZIP files next to each archive.",
378
- )
379
- parser.add_argument(
380
- "--delete-zip-after-extract",
381
- action="store_true",
382
- help="Delete each ZIP only after successful extraction; requires --extract.",
383
- )
384
- parser.add_argument(
385
- "--list-only",
386
- action="store_true",
387
- help="Print the selected remote file paths without downloading them.",
388
- )
389
- parser.add_argument(
390
- "--dry-run",
391
- action="store_true",
392
- help="Show task and file counts without downloading data.",
393
- )
394
- return parser
395
-
396
-
397
- def main(argv: Sequence[str] | None = None) -> int:
398
- args = build_parser().parse_args(argv)
399
- if args.workers < 1:
400
- raise SystemExit("--workers must be at least 1")
401
- if args.delete_zip_after_extract and not args.extract:
402
- raise SystemExit("--delete-zip-after-extract requires --extract")
403
-
404
- tasks = selected_tasks(args.task)
405
- output_dir = args.output_dir.expanduser().resolve()
406
- cache_dir = output_dir / ".hf_cache"
407
- selections: list[tuple[str, str]] = []
408
- counts: dict[str, int] = {}
409
- for task in tasks:
410
- paths = filter_scenes(get_task_list(task, args.revision, cache_dir), args.scene)
411
- counts[task] = len(paths)
412
- selections.extend((task, path) for path in paths)
413
-
414
- if args.list_only:
415
- for _, path in selections:
416
- print(path)
417
- return 0
418
-
419
- for task in tasks:
420
- print(f"{task}: {counts[task]} file(s)")
421
- print(f"Total: {len(selections)} file(s)")
422
- if args.scene and not selections:
423
- print("No files matched --scene.", file=sys.stderr)
424
- return 2
425
- if args.dry_run:
426
- for task in tasks:
427
- print(
428
- f"{task} -> "
429
- f"{output_dir / 'leaderboard' / str(TASKS[task]['local_root'])}"
430
- )
431
- return 0
432
-
433
- output_dir.mkdir(parents=True, exist_ok=True)
434
- run_id = datetime.now().strftime("%Y%m%d_%H%M%S")
435
- logs = Logs(output_dir / "_download_logs" / run_id)
436
- results: list[Result] = []
437
- with ThreadPoolExecutor(max_workers=args.workers) as pool:
438
- futures = {
439
- pool.submit(
440
- download_one,
441
- task,
442
- path,
443
- output_dir,
444
- cache_dir,
445
- args.revision,
446
- args.extract,
447
- args.delete_zip_after_extract,
448
- ): (task, path)
449
- for task, path in selections
450
- }
451
- completed = as_completed(futures)
452
- if tqdm is not None:
453
- completed = tqdm(completed, total=len(futures), unit="file")
454
- for future in completed:
455
- result = future.result()
456
- logs.record(result)
457
- results.append(result)
458
-
459
- failed = [result for result in results if result.error]
460
- summary = {
461
- "repo_id": REPO_ID,
462
- "revision": args.revision,
463
- "tasks": tasks,
464
- "selected_files": len(selections),
465
- "successful_files": len(results) - len(failed),
466
- "failed_files": len(failed),
467
- "output_dir": str(output_dir),
468
- "log_dir": str(logs.root),
469
- "finished_at": utc_now(),
470
- }
471
- (logs.root / "summary.json").write_text(
472
- json.dumps(summary, indent=2, sort_keys=True) + "\n",
473
- encoding="utf-8",
474
- )
475
- print(json.dumps(summary, indent=2, sort_keys=True))
476
- return 1 if failed else 0
477
-
478
-
479
- if __name__ == "__main__":
480
- raise SystemExit(main())
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
Utils/scripts/download_lists/3d_assets.txt ADDED
The diff for this file is too large to render. See raw diff
 
Utils/scripts/download_lists/future_prediction.txt ADDED
@@ -0,0 +1,103 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ Leaderboard/Future%20Prediction/DoublePhysics/AccelConcaveSpin_AccelSurfaceSpin__bg280__yUlWPB_trajectory.zip
2
+ Leaderboard/Future%20Prediction/DoublePhysics/AccelPanelSpin_BalloonFloat__bg202__mZuITT_trajectory.zip
3
+ Leaderboard/Future%20Prediction/DoublePhysics/BalloonLift_ChainSuspend__bg267__m1Cqz7_trajectory.zip
4
+ Leaderboard/Future%20Prediction/DoublePhysics/BalloonTether_BlockWallCollapse__bg227__74YCgm_trajectory.zip
5
+ Leaderboard/Future%20Prediction/DoublePhysics/CatapultLaunch_StickSupportFail__bg204__ulAbpI_trajectory.zip
6
+ Leaderboard/Future%20Prediction/DoublePhysics/DynMirrorRedirect_MirrorReflect__bg264__NxPd1o_trajectory.zip
7
+ Leaderboard/Future%20Prediction/DoublePhysics/ElasticCouple_CartMove__bg253__GSA6mr_trajectory.zip
8
+ Leaderboard/Future%20Prediction/DoublePhysics/ElasticFall_PlasticineFall__bg852__2QHJQg_trajectory.zip
9
+ Leaderboard/Future%20Prediction/DoublePhysics/FixedArrayRedirect_FixedConcaveRedirect__bg210__L2y3J0_trajectory.zip
10
+ Leaderboard/Future%20Prediction/DoublePhysics/FixedConvexRedirect_RotBoardInertia__bg234__fT2JKm_trajectory.zip
11
+ Leaderboard/Future%20Prediction/DoublePhysics/FixedPlanarRedirect_LaserBlock__bg299__TfT2x2_trajectory.zip
12
+ Leaderboard/Future%20Prediction/DoublePhysics/FloatOnLiquid_DropInLiquid__bg509__lRK4PA_trajectory.zip
13
+ Leaderboard/Future%20Prediction/DoublePhysics/FrictionStop_CrankPush__bg261__iFf7zo_trajectory.zip
14
+ Leaderboard/Future%20Prediction/DoublePhysics/ImpactFracture_DoublePendulum__bg215__RErDnS_trajectory.zip
15
+ Leaderboard/Future%20Prediction/DoublePhysics/LinCarryInertia_SimplePendulum__bg294__Ty0PCX_trajectory.zip
16
+ Leaderboard/Future%20Prediction/DoublePhysics/LiquidMultiTransfers_LiquidRise__bg544__WYOBHP_trajectory.zip
17
+ Leaderboard/Future%20Prediction/DoublePhysics/LiquidThroughGrid_StickyToObjects__bg670__EAVM3Z_trajectory.zip
18
+ Leaderboard/Future%20Prediction/DoublePhysics/MagnetAttract_MagnetRepel__bg265__rel0pp_trajectory.zip
19
+ Leaderboard/Future%20Prediction/DoublePhysics/MirrorFragmentReflect_RotTurnableInertia__bg286__yAEdAd_trajectory.zip
20
+ Leaderboard/Future%20Prediction/DoublePhysics/MovingHitsFixed_WindGravityBalance__bg299__l185PI_trajectory.zip
21
+ Leaderboard/Future%20Prediction/DoublePhysics/MovingHitsFixed_WindPushStationary__bg298__ifDc18_trajectory.zip
22
+ Leaderboard/Future%20Prediction/DoublePhysics/MovingHitsStationary_MovingHitsMoving__bg242__CrPMCl_trajectory.zip
23
+ Leaderboard/Future%20Prediction/DoublePhysics/MovingObjDriveLiquid_LiquidTransfer__bg596__hjv8Xm_trajectory.zip
24
+ Leaderboard/Future%20Prediction/DoublePhysics/NewtonianFluidFall_GranularFall__bg851__3GTIkU_trajectory.zip
25
+ Leaderboard/Future%20Prediction/DoublePhysics/ObliqueProjectile_RollDownSlope__bg250__s663ZS_trajectory.zip
26
+ Leaderboard/Future%20Prediction/DoublePhysics/RollUpSlope_AccelPanelSpin__bg256__ied5pR_trajectory.zip
27
+ Leaderboard/Future%20Prediction/DoublePhysics/SeesawCenterPivot_SeesawOffsetPivot__bg221__hudzDK_trajectory.zip
28
+ Leaderboard/Future%20Prediction/DoublePhysics/SpringCompress_SpringStretch__bg304__iY1AZp_trajectory.zip
29
+ Leaderboard/Future%20Prediction/DoublePhysics/UniformConcaveSpin_SpringboardRebound__bg254__hhDGVy_trajectory.zip
30
+ Leaderboard/Future%20Prediction/DoublePhysics/VerticalFall_UniformPanelSpin__bg261__OCFwnO_trajectory.zip
31
+ Leaderboard/Future%20Prediction/DoublePhysics/WindDeflectMotion_UniformSurfaceSpin__bg242__EvkQJ4_trajectory.zip
32
+ Leaderboard/Future%20Prediction/DoublePhysics/WindPushSameDir_WindPushOppDir__bg223__K3BpfI_trajectory.zip
33
+ Leaderboard/Future%20Prediction/SinglePhysics/AccelConcaveSpin__bg212__NFdwUo_trajectory.zip
34
+ Leaderboard/Future%20Prediction/SinglePhysics/AccelPanelSpin__bg262__djc1vR_trajectory.zip
35
+ Leaderboard/Future%20Prediction/SinglePhysics/AccelSurfaceSpin__bg222__QZ2PE4_trajectory.zip
36
+ Leaderboard/Future%20Prediction/SinglePhysics/BalloonFloat__bg302__p4KZYD_trajectory.zip
37
+ Leaderboard/Future%20Prediction/SinglePhysics/BalloonLift__bg292__Qt12QQ_trajectory.zip
38
+ Leaderboard/Future%20Prediction/SinglePhysics/BalloonTether__bg238__DxDc80_trajectory.zip
39
+ Leaderboard/Future%20Prediction/SinglePhysics/BlockWallCollapse__bg298__FNYLX6_trajectory.zip
40
+ Leaderboard/Future%20Prediction/SinglePhysics/CartMove__bg206__kYmfIb_trajectory.zip
41
+ Leaderboard/Future%20Prediction/SinglePhysics/CatapultLaunch__bg285__oEOde8_trajectory.zip
42
+ Leaderboard/Future%20Prediction/SinglePhysics/ChainSuspend__bg231__ryNCAj_trajectory.zip
43
+ Leaderboard/Future%20Prediction/SinglePhysics/CrankPush__bg244__bthMYh_trajectory.zip
44
+ Leaderboard/Future%20Prediction/SinglePhysics/DoublePendulum__bg222__Nzo0Eh_trajectory.zip
45
+ Leaderboard/Future%20Prediction/SinglePhysics/DynMirrorRedirect__bg292__41t9VE_trajectory.zip
46
+ Leaderboard/Future%20Prediction/SinglePhysics/ElasticCouple__bg227__JKaxKZ_trajectory.zip
47
+ Leaderboard/Future%20Prediction/SinglePhysics/ElasticFall__bg852__rueoHR_trajectory.zip
48
+ Leaderboard/Future%20Prediction/SinglePhysics/FixedArrayRedirect__bg299__ZepDd8_trajectory.zip
49
+ Leaderboard/Future%20Prediction/SinglePhysics/FixedConcaveRedirect__bg293__coyuOe_trajectory.zip
50
+ Leaderboard/Future%20Prediction/SinglePhysics/FixedConvexRedirect__bg285__n1yPPu_trajectory.zip
51
+ Leaderboard/Future%20Prediction/SinglePhysics/GranularFall__bg853__ZBMM7p_trajectory.zip
52
+ Leaderboard/Future%20Prediction/SinglePhysics/LiquidRefraction__bg707__nAoSt2_trajectory.zip
53
+ Leaderboard/Future%20Prediction/SinglePhysics/LiquidTension__bg622__aEkUTp_trajectory.zip
54
+ Leaderboard/Future%20Prediction/SinglePhysics/MagnetAttract__bg200__lf9N8U_trajectory.zip
55
+ Leaderboard/Future%20Prediction/SinglePhysics/MagnetRepel__bg200__xGZUDW_trajectory.zip
56
+ Leaderboard/Future%20Prediction/SinglePhysics/MovingHitsFixed__bg302__sItDt6_trajectory.zip
57
+ Leaderboard/Future%20Prediction/SinglePhysics/MovingHitsMoving__bg227__kkMgg3_trajectory.zip
58
+ Leaderboard/Future%20Prediction/SinglePhysics/MovingHitsStationary__bg279__TsWOVY_trajectory.zip
59
+ Leaderboard/Future%20Prediction/SinglePhysics/NewtonianFluidFall__bg851__ksCdUy_trajectory.zip
60
+ Leaderboard/Future%20Prediction/SinglePhysics/NonNewtonianFluidFall__bg851__CUmiwi_trajectory.zip
61
+ Leaderboard/Future%20Prediction/SinglePhysics/PlasticineFall__bg853__JqI201_trajectory.zip
62
+ Leaderboard/Future%20Prediction/SinglePhysics/RollUpSlope__bg222__U5gBBT_trajectory.zip
63
+ Leaderboard/Future%20Prediction/SinglePhysics/StickyFromObjects__bg550__69Heh3_trajectory.zip
64
+ Leaderboard/Future%20Prediction/TriplePhysics/BalloonFloat_BalloonLift_LaserBlock__bg240__i1Ifib_trajectory.zip
65
+ Leaderboard/Future%20Prediction/TriplePhysics/BalloonTether_FixedConvexRedirect_MirrorReflect__bg286__Sc6DUR_trajectory.zip
66
+ Leaderboard/Future%20Prediction/TriplePhysics/DropInLiquid_LiquidCarryMovingObj_LiquidTransfer__bg685__OU1tWD_trajectory.zip
67
+ Leaderboard/Future%20Prediction/TriplePhysics/ElasticFall_PlasticineFall_GranularFall__bg853__uzqMDe_trajectory.zip
68
+ Leaderboard/Future%20Prediction/TriplePhysics/FrictionStop_BalloonLift_StickSupportFail__bg246__XZiFvj_trajectory.zip
69
+ Leaderboard/Future%20Prediction/TriplePhysics/FrictionStop_SeesawOffsetPivot_BalloonLift__bg203__MAlrpr_trajectory.zip
70
+ Leaderboard/Future%20Prediction/TriplePhysics/ImpactFracture_BalloonTether_FixedConcaveRedirect__bg302__c7jIv7_trajectory.zip
71
+ Leaderboard/Future%20Prediction/TriplePhysics/ImpactFracture_MirrorFragmentReflect_CartMove__bg248__vfd9qM_trajectory.zip
72
+ Leaderboard/Future%20Prediction/TriplePhysics/LiquidCarryMovingObj_LiquidRise_JetLiquid__bg566__beJD8m_trajectory.zip
73
+ Leaderboard/Future%20Prediction/TriplePhysics/LiquidHitFixedObj_LiquidAcrossUneven_LiquidAlongContours__bg565__vTg7Bm_trajectory.zip
74
+ Leaderboard/Future%20Prediction/TriplePhysics/MagnetRepel_BalloonFloat_BalloonLift__bg207__Sb4Hsi_trajectory.zip
75
+ Leaderboard/Future%20Prediction/TriplePhysics/MirrorFragmentReflect_DynMirrorRedirect_MirrorReflect__bg299__cUcPzv_trajectory.zip
76
+ Leaderboard/Future%20Prediction/TriplePhysics/MirrorFragmentReflect_SpringboardRebound_MirrorReflect__bg204__3plqni_trajectory.zip
77
+ Leaderboard/Future%20Prediction/TriplePhysics/MovingHitsFixed_AccelPanelSpin_FrictionStop__bg292__T3rFSd_trajectory.zip
78
+ Leaderboard/Future%20Prediction/TriplePhysics/MovingHitsFixed_ElasticCouple_BalloonFloat__bg281__fUADj8_trajectory.zip
79
+ Leaderboard/Future%20Prediction/TriplePhysics/MovingHitsFixed_FrictionStop_BalloonTether__bg260__VfyYGz_trajectory.zip
80
+ Leaderboard/Future%20Prediction/TriplePhysics/MovingHitsFixed_MovingHitsMoving_RotTurnableInertia__bg261__v8ZFaw_trajectory.zip
81
+ Leaderboard/Future%20Prediction/TriplePhysics/MovingHitsMoving_ImpactFracture_FixedArrayRedirect__bg200__ikFNYR_trajectory.zip
82
+ Leaderboard/Future%20Prediction/TriplePhysics/MovingHitsMoving_ImpactFracture_MirrorReflect__bg264__xrKsUd_trajectory.zip
83
+ Leaderboard/Future%20Prediction/TriplePhysics/MovingHitsStationary_ObliqueProjectile_VerticalFall__bg222__Qzznk7_trajectory.zip
84
+ Leaderboard/Future%20Prediction/TriplePhysics/MovingHitsStationary_RollDownSlope_CatapultLaunch__bg289__3YHRsf_trajectory.zip
85
+ Leaderboard/Future%20Prediction/TriplePhysics/MovingHitsStationary_RollDownSlope_FixedPlanarRedirect__bg209__8k3SuZ_trajectory.zip
86
+ Leaderboard/Future%20Prediction/TriplePhysics/MovingHitsStationary_RollDownSlope_SimplePendulum__bg244__66TqQ5_trajectory.zip
87
+ Leaderboard/Future%20Prediction/TriplePhysics/MovingHitsStationary_RollDownSlope_SpringCompress__bg295__Sf64Sp_trajectory.zip
88
+ Leaderboard/Future%20Prediction/TriplePhysics/NewtonianFluidFall_NonNewtonianFluidFall_ElasticFall__bg852__EyPG9y_trajectory.zip
89
+ Leaderboard/Future%20Prediction/TriplePhysics/ObliqueProjectile_RollUpSlope_ChainSuspend__bg267__JaogRr_trajectory.zip
90
+ Leaderboard/Future%20Prediction/TriplePhysics/ObliqueProjectile_RollUpSlope_LinCarryInertia__bg222__CTFy4y_trajectory.zip
91
+ Leaderboard/Future%20Prediction/TriplePhysics/ObliqueProjectile_RollUpSlope_MagnetAttract__bg210__tUbbP1_trajectory.zip
92
+ Leaderboard/Future%20Prediction/TriplePhysics/RollDownSlope_RollUpSlope_MirrorFragmentReflect__bg266__ryc7c7_trajectory.zip
93
+ Leaderboard/Future%20Prediction/TriplePhysics/WindDeflectMotion_SeesawCenterPivot_BalloonTether__bg292__7JdiSA_trajectory.zip
94
+ Leaderboard/Future%20Prediction/TriplePhysics/WindDeflectMotion_VerticalFall_DoublePendulum__bg206__10pAkl_trajectory.zip
95
+ Leaderboard/Future%20Prediction/TriplePhysics/WindDeflectMotion_VerticalFall_UniformConcaveSpin__bg202__SZafgO_trajectory.zip
96
+ Leaderboard/Future%20Prediction/TriplePhysics/WindPushOppDir_SpringStretch_BalloonFloat__bg250__GWG0OJ_trajectory.zip
97
+ Leaderboard/Future%20Prediction/TriplePhysics/WindPushOppDir_VerticalFall_BlockWallCollapse__bg292__V5daqV_trajectory.zip
98
+ Leaderboard/Future%20Prediction/TriplePhysics/WindPushOppDir_WindDeflectMotion_AccelSurfaceSpin__bg262__ARn19P_trajectory.zip
99
+ Leaderboard/Future%20Prediction/TriplePhysics/WindPushSameDir_WindPushOppDir_UniformSurfaceSpin__bg222__EeWemv_trajectory.zip
100
+ Leaderboard/Future%20Prediction/TriplePhysics/WindPushStationary_UniformPanelSpin_BalloonFloat__bg250__659qpJ_trajectory.zip
101
+ Leaderboard/Future%20Prediction/TriplePhysics/WindPushStationary_WindPushSameDir_AccelConcaveSpin__bg291__S4A8wD_trajectory.zip
102
+ Leaderboard/Future%20Prediction/TriplePhysics/WindPushStationary_WindPushSameDir_CrankPush__bg281__7HsO29_trajectory.zip
103
+ Leaderboard/Future%20Prediction/TriplePhysics/WindPushStationary_WindPushSameDir_RotBoardInertia__bg291__kRkCLB_trajectory.zip
Utils/scripts/download_lists/motion_transfer.txt ADDED
@@ -0,0 +1,217 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ Leaderboard/Motion%20Transfer/DoublePhysics/MovingHitsFixed_RollUpSlope__bg182__tJqHNA_trajectory.zip
2
+ Leaderboard/Motion%20Transfer/DoublePhysics/MovingHitsMoving_ObliqueProjectile__bg177__T25qxa_trajectory.zip
3
+ Leaderboard/Motion%20Transfer/DoublePhysics/MovingHitsStationary_ObliqueProjectile__bg165__pOS6Xu_trajectory.zip
4
+ Leaderboard/Motion%20Transfer/DoublePhysics/MovingHitsStationary_RollDownSlope__bg171__8Vk9qD_trajectory.zip
5
+ Leaderboard/Motion%20Transfer/DoublePhysics/MovingHitsStationary_RollDownSlope__bg190__EKHD4c_trajectory.zip
6
+ Leaderboard/Motion%20Transfer/DoublePhysics/MovingHitsStationary_RollUpSlope__bg174__N6y01Z_trajectory.zip
7
+ Leaderboard/Motion%20Transfer/DoublePhysics/ObliqueProjectile_RollDownSlope__bg167__aDKc8W_trajectory.zip
8
+ Leaderboard/Motion%20Transfer/DoublePhysics/RollDownSlope_RollUpSlope__bg166__lFNaoh_trajectory.zip
9
+ Leaderboard/Motion%20Transfer/DoublePhysics/RollDownSlope_RollUpSlope__bg177__HLOoTv_trajectory.zip
10
+ Leaderboard/Motion%20Transfer/TriplePhysics/AccelConcaveSpin_FrictionStop_BalloonFloat__bg177__ztIf6l_trajectory.zip
11
+ Leaderboard/Motion%20Transfer/TriplePhysics/AccelConcaveSpin_ImpactFracture_MirrorFragmentReflect__bg165__PfuNfN_trajectory.zip
12
+ Leaderboard/Motion%20Transfer/TriplePhysics/AccelPanelSpin_BalloonTether_BalloonLift__bg180__dTqT2B_trajectory.zip
13
+ Leaderboard/Motion%20Transfer/TriplePhysics/AccelPanelSpin_FrictionStop_BalloonLift__bg161__PWuORg_trajectory.zip
14
+ Leaderboard/Motion%20Transfer/TriplePhysics/AccelPanelSpin_FrictionStop_MirrorReflect__bg151__XYF8bP_trajectory.zip
15
+ Leaderboard/Motion%20Transfer/TriplePhysics/BalloonFloat_BalloonLift_BlockWallCollapse__bg186__E6Ing1_trajectory.zip
16
+ Leaderboard/Motion%20Transfer/TriplePhysics/BalloonFloat_MirrorReflect_BlockWallCollapse__bg167__dCxcFr_trajectory.zip
17
+ Leaderboard/Motion%20Transfer/TriplePhysics/BalloonFloat_MirrorReflect_CatapultLaunch__bg167__P2au7f_trajectory.zip
18
+ Leaderboard/Motion%20Transfer/TriplePhysics/BalloonLift_LaserBlock_MirrorReflect__bg163__lVrSB4_trajectory.zip
19
+ Leaderboard/Motion%20Transfer/TriplePhysics/BalloonLift_MirrorReflect_RotTurnableInertia__bg178__RFawuv_trajectory.zip
20
+ Leaderboard/Motion%20Transfer/TriplePhysics/BalloonTether_BalloonLift_BlockWallCollapse__bg151__lYdEnL_trajectory.zip
21
+ Leaderboard/Motion%20Transfer/TriplePhysics/FrictionStop_BalloonFloat_BalloonTether__bg180__lDdPzV_trajectory.zip
22
+ Leaderboard/Motion%20Transfer/TriplePhysics/FrictionStop_BalloonFloat_MirrorReflect__bg180__8EOUtZ_trajectory.zip
23
+ Leaderboard/Motion%20Transfer/TriplePhysics/FrictionStop_BalloonFloat_RotBoardInertia__bg161__HCJlgt_trajectory.zip
24
+ Leaderboard/Motion%20Transfer/TriplePhysics/FrictionStop_BalloonLift_RotBoardInertia__bg167__NFHIrL_trajectory.zip
25
+ Leaderboard/Motion%20Transfer/TriplePhysics/FrictionStop_BalloonTether_BlockWallCollapse__bg163__7zfkGJ_trajectory.zip
26
+ Leaderboard/Motion%20Transfer/TriplePhysics/FrictionStop_ImpactFracture_BalloonLift__bg180__tGXdbw_trajectory.zip
27
+ Leaderboard/Motion%20Transfer/TriplePhysics/FrictionStop_ImpactFracture_BlockWallCollapse__bg151__p94i92_trajectory.zip
28
+ Leaderboard/Motion%20Transfer/TriplePhysics/FrictionStop_ImpactFracture_MirrorFragmentReflect__bg167__ncycBo_trajectory.zip
29
+ Leaderboard/Motion%20Transfer/TriplePhysics/FrictionStop_ImpactFracture_SeesawOffsetPivot__bg156__Kc5zRp_trajectory.zip
30
+ Leaderboard/Motion%20Transfer/TriplePhysics/FrictionStop_MirrorFragmentReflect_CatapultLaunch__bg151__pdETrM_trajectory.zip
31
+ Leaderboard/Motion%20Transfer/TriplePhysics/FrictionStop_MirrorFragmentReflect_MirrorReflect__bg151__iDff2y_trajectory.zip
32
+ Leaderboard/Motion%20Transfer/TriplePhysics/FrictionStop_MirrorFragmentReflect_RotTurnableInertia__bg177__0dTUOH_trajectory.zip
33
+ Leaderboard/Motion%20Transfer/TriplePhysics/FrictionStop_MirrorFragmentReflect_SeesawCenterPivot__bg180__ROCERE_trajectory.zip
34
+ Leaderboard/Motion%20Transfer/TriplePhysics/FrictionStop_MirrorFragmentReflect_StickSupportFail__bg156__fKFfMs_trajectory.zip
35
+ Leaderboard/Motion%20Transfer/TriplePhysics/FrictionStop_SeesawCenterPivot_BalloonFloat__bg151__3My9bB_trajectory.zip
36
+ Leaderboard/Motion%20Transfer/TriplePhysics/ImpactFracture_BalloonFloat_BlockWallCollapse__bg180__Id4ioR_trajectory.zip
37
+ Leaderboard/Motion%20Transfer/TriplePhysics/ImpactFracture_BalloonFloat_CatapultLaunch__bg178__1pueaK_trajectory.zip
38
+ Leaderboard/Motion%20Transfer/TriplePhysics/ImpactFracture_MirrorFragmentReflect_BlockWallCollapse__bg180__t1scdJ_trajectory.zip
39
+ Leaderboard/Motion%20Transfer/TriplePhysics/ImpactFracture_MirrorReflect_LinCarryInertia__bg156__H2uBR8_trajectory.zip
40
+ Leaderboard/Motion%20Transfer/TriplePhysics/MagnetAttract_FrictionStop_BalloonTether__bg177__agPIvS_trajectory.zip
41
+ Leaderboard/Motion%20Transfer/TriplePhysics/MagnetAttract_FrictionStop_MirrorReflect__bg168__Gw4Pch_trajectory.zip
42
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsFixed_FrictionStop_BalloonFloat__bg175__AiL3I6_trajectory.zip
43
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsFixed_FrictionStop_ImpactFracture__bg162__DsWczI_trajectory.zip
44
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsFixed_FrictionStop_MirrorReflect__bg169__FTCNd3_trajectory.zip
45
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsFixed_ImpactFracture_MirrorFragmentReflect__bg150__3hKEQv_trajectory.zip
46
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsFixed_MovingHitsMoving_BalloonFloat__bg177__yh1qhP_trajectory.zip
47
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsFixed_MovingHitsMoving_BalloonLift__bg152__ZJBDoj_trajectory.zip
48
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsFixed_MovingHitsMoving_DoublePendulum__bg180__BQwCXW_trajectory.zip
49
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsFixed_MovingHitsMoving_MirrorFragmentReflect__bg162__dyLhGI_trajectory.zip
50
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsFixed_MovingHitsMoving_ObliqueProjectile__bg180__jAznwr_trajectory.zip
51
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsFixed_MovingHitsMoving_RollDownSlope__bg177__gSumjG_trajectory.zip
52
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsFixed_MovingHitsMoving_RollUpSlope__bg156__bWbfdx_trajectory.zip
53
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsFixed_MovingHitsMoving_RotTurnableInertia__bg169__ix0QOd_trajectory.zip
54
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsFixed_MovingHitsStationary_FrictionStop__bg180__LyBT4O_trajectory.zip
55
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsFixed_MovingHitsStationary_MovingHitsMoving__bg154__B15ta6_trajectory.zip
56
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsFixed_MovingHitsStationary_RollDownSlope__bg156__7omQio_trajectory.zip
57
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsFixed_RollDownSlope_BalloonLift__bg151__It2aIO_trajectory.zip
58
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsFixed_RollDownSlope_BalloonTether__bg157__n3pouS_trajectory.zip
59
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsFixed_RollDownSlope_FrictionStop__bg162__dWSePy_trajectory.zip
60
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsFixed_RollDownSlope_ImpactFracture__bg171__zmh4Do_trajectory.zip
61
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsFixed_RollDownSlope_RollUpSlope__bg177__NoTchG_trajectory.zip
62
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsFixed_RollUpSlope_BalloonLift__bg162__IAFGKi_trajectory.zip
63
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsMoving_BalloonFloat_BalloonLift__bg156__nONfgD_trajectory.zip
64
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsMoving_BalloonFloat_BalloonTether__bg180__0dU8w7_trajectory.zip
65
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsMoving_BalloonFloat_MirrorReflect__bg177__IHFcbW_trajectory.zip
66
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsMoving_BalloonLift_MirrorReflect__bg162__cFNWUs_trajectory.zip
67
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsMoving_MirrorFragmentReflect_BalloonFloat__bg179__FstmOw_trajectory.zip
68
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsMoving_MirrorFragmentReflect_BalloonLift__bg177__SCWLt4_trajectory.zip
69
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsMoving_MirrorFragmentReflect_MirrorReflect__bg167__EZ8dMK_trajectory.zip
70
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsMoving_ObliqueProjectile_BalloonTether__bg156__xvdBKv_trajectory.zip
71
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsMoving_ObliqueProjectile_FixedConvexRedirect__bg156__zZew3m_trajectory.zip
72
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsMoving_ObliqueProjectile_FrictionStop__bg196__rsC4ey_trajectory.zip
73
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsMoving_ObliqueProjectile_ImpactFracture__bg162__JAJjmW_trajectory.zip
74
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsMoving_ObliqueProjectile_MirrorFragmentReflect__bg167__IHkdCP_trajectory.zip
75
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsMoving_ObliqueProjectile_MirrorReflect__bg156__H7T2Cp_trajectory.zip
76
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsMoving_ObliqueProjectile_RollDownSlope__bg180__eTjQ02_trajectory.zip
77
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsMoving_ObliqueProjectile_RollDownSlope__bg190__E8e8mZ_trajectory.zip
78
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsMoving_ObliqueProjectile_RollUpSlope__bg156__soNANa_trajectory.zip
79
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsMoving_RollDownSlope_FixedArrayRedirect__bg185__F2Zpdw_trajectory.zip
80
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsMoving_RollDownSlope_ImpactFracture__bg171__ZiQsSF_trajectory.zip
81
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsMoving_RollDownSlope_MirrorFragmentReflect__bg156__VWevqe_trajectory.zip
82
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsMoving_RollDownSlope_RollUpSlope__bg177__QRd3Nk_trajectory.zip
83
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsMoving_RollUpSlope_BalloonFloat__bg156__cPvHBn_trajectory.zip
84
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsMoving_RollUpSlope_BalloonTether__bg166__8rzJmd_trajectory.zip
85
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsMoving_RollUpSlope_FrictionStop__bg177__kET1VJ_trajectory.zip
86
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsMoving_RollUpSlope_MirrorFragmentReflect__bg156__224bYq_trajectory.zip
87
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsMoving_RollUpSlope_MirrorReflect__bg177__Ti6w0e_trajectory.zip
88
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsMoving_WindDeflectMotion_BalloonFloat__bg168__2ZX4ut_trajectory.zip
89
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsMoving_WindPushSameDir_ImpactFracture__bg156__aVIb22_trajectory.zip
90
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsStationary_BalloonFloat_BalloonTether__bg151__9WcRK7_trajectory.zip
91
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsStationary_BalloonFloat_MirrorReflect__bg192__jltkEu_trajectory.zip
92
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsStationary_BalloonTether_BalloonLift__bg162__N7Se2w_trajectory.zip
93
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsStationary_FrictionStop_BalloonTether__bg161__4mn9Lp_trajectory.zip
94
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsStationary_ImpactFracture_BalloonFloat__bg186__NhhiIr_trajectory.zip
95
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsStationary_MovingHitsMoving_BalloonTether__bg156__JRDFLb_trajectory.zip
96
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsStationary_MovingHitsMoving_ImpactFracture__bg151__lJOt7p_trajectory.zip
97
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsStationary_MovingHitsMoving_ObliqueProjectile__bg162__PUH2Rp_trajectory.zip
98
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsStationary_MovingHitsMoving_ObliqueProjectile__bg180__3jSmTd_trajectory.zip
99
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsStationary_MovingHitsMoving_RollUpSlope__bg151__3kPJkf_trajectory.zip
100
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsStationary_MovingHitsMoving_RollUpSlope__bg159__t9LxlQ_trajectory.zip
101
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsStationary_ObliqueProjectile_BalloonTether__bg151__IKuxmN_trajectory.zip
102
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsStationary_ObliqueProjectile_CartMove__bg151__sxPJth_trajectory.zip
103
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsStationary_ObliqueProjectile_FixedArrayRedirect__bg151__6L4XTB_trajectory.zip
104
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsStationary_ObliqueProjectile_MirrorFragmentReflect__bg177__8ihHEK_trajectory.zip
105
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsStationary_ObliqueProjectile_MirrorReflect__bg177__7A6vJU_trajectory.zip
106
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsStationary_ObliqueProjectile_RollDownSlope__bg156__1qrg25_trajectory.zip
107
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsStationary_ObliqueProjectile_RollDownSlope__bg177__63ajWJ_trajectory.zip
108
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsStationary_ObliqueProjectile_RollUpSlope__bg180__fde9Ft_trajectory.zip
109
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsStationary_ObliqueProjectile_RotTurnableInertia__bg159__Dtf2J9_trajectory.zip
110
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsStationary_RollDownSlope_BalloonFloat__bg162__VvJkvy_trajectory.zip
111
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsStationary_RollDownSlope_BalloonLift__bg156__t5et5p_trajectory.zip
112
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsStationary_RollDownSlope_BalloonTether__bg156__yxGqX9_trajectory.zip
113
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsStationary_RollDownSlope_MagnetAttract__bg162__8wqJ21_trajectory.zip
114
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsStationary_RollDownSlope_MirrorReflect__bg167__rxDvof_trajectory.zip
115
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsStationary_RollDownSlope_RollUpSlope__bg157__b2VnuH_trajectory.zip
116
+ Leaderboard/Motion%20Transfer/TriplePhysics/MovingHitsStationary_RollDownSlope_SeesawCenterPivot__bg151__epaGE6_trajectory.zip
117
+ Leaderboard/Motion%20Transfer/TriplePhysics/ObliqueProjectile_RollDownSlope_AccelPanelSpin__bg161__P6TSzh_trajectory.zip
118
+ Leaderboard/Motion%20Transfer/TriplePhysics/ObliqueProjectile_RollDownSlope_BalloonLift__bg180__xVmEtV_trajectory.zip
119
+ Leaderboard/Motion%20Transfer/TriplePhysics/ObliqueProjectile_RollDownSlope_BalloonTether__bg162__VC9TzW_trajectory.zip
120
+ Leaderboard/Motion%20Transfer/TriplePhysics/ObliqueProjectile_RollDownSlope_BlockWallCollapse__bg162__aaMonV_trajectory.zip
121
+ Leaderboard/Motion%20Transfer/TriplePhysics/ObliqueProjectile_RollDownSlope_DoublePendulum__bg156__JOvyMx_trajectory.zip
122
+ Leaderboard/Motion%20Transfer/TriplePhysics/ObliqueProjectile_RollDownSlope_FixedArrayRedirect__bg177__MuvJkH_trajectory.zip
123
+ Leaderboard/Motion%20Transfer/TriplePhysics/ObliqueProjectile_RollDownSlope_FixedPlanarRedirect__bg152__NQ6GZi_trajectory.zip
124
+ Leaderboard/Motion%20Transfer/TriplePhysics/ObliqueProjectile_RollDownSlope_ImpactFracture__bg156__V7e2G5_trajectory.zip
125
+ Leaderboard/Motion%20Transfer/TriplePhysics/ObliqueProjectile_RollDownSlope_MirrorFragmentReflect__bg167__Ocz9ia_trajectory.zip
126
+ Leaderboard/Motion%20Transfer/TriplePhysics/ObliqueProjectile_RollUpSlope_BalloonLift__bg180__LRxkdk_trajectory.zip
127
+ Leaderboard/Motion%20Transfer/TriplePhysics/ObliqueProjectile_RollUpSlope_BalloonTether__bg177__reqC1Y_trajectory.zip
128
+ Leaderboard/Motion%20Transfer/TriplePhysics/ObliqueProjectile_RollUpSlope_ImpactFracture__bg167__Nu3KZt_trajectory.zip
129
+ Leaderboard/Motion%20Transfer/TriplePhysics/VerticalFall_RollDownSlope_RollUpSlope__bg190__9BCb6n_trajectory.zip
130
+ Leaderboard/Motion%20Transfer/TriplePhysics/VerticalFall_RollUpSlope_ImpactFracture__bg167__JlrhDm_trajectory.zip
131
+ Leaderboard/Motion%20Transfer/TriplePhysics/VerticalFall_RollUpSlope_MagnetAttract__bg162__gf5o3Z_trajectory.zip
132
+ Leaderboard/Motion%20Transfer/TriplePhysics/VerticalFall_RollUpSlope_MirrorFragmentReflect__bg167__WLELXl_trajectory.zip
133
+ Leaderboard/Motion%20Transfer/TriplePhysics/VerticalFall_RollUpSlope_MirrorReflect__bg177__D0oxyg_trajectory.zip
134
+ Leaderboard/Motion%20Transfer/TriplePhysics/VerticalFall_RollUpSlope_SeesawOffsetPivot__bg162__VZlgAX_trajectory.zip
135
+ Leaderboard/Motion%20Transfer/TriplePhysics/VerticalFall_SpringboardRebound_MirrorReflect__bg180__W0Q3w4_trajectory.zip
136
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindDeflectMotion_ObliqueProjectile_RollDownSlope__bg162__aUKkrz_trajectory.zip
137
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindDeflectMotion_SpringStretch_ImpactFracture__bg157__vR1esL_trajectory.zip
138
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindDeflectMotion_SpringStretch_MirrorReflect__bg180__indwl5_trajectory.zip
139
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindDeflectMotion_UniformSurfaceSpin_MirrorReflect__bg162__yU3E5H_trajectory.zip
140
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindDeflectMotion_VerticalFall_AccelConcaveSpin__bg180__vzCly2_trajectory.zip
141
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindDeflectMotion_VerticalFall_BalloonTether__bg151__GhbT1L_trajectory.zip
142
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindDeflectMotion_VerticalFall_CrankPush__bg151__03CMk4_trajectory.zip
143
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindDeflectMotion_VerticalFall_ImpactFracture__bg178__CtrRED_trajectory.zip
144
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindDeflectMotion_VerticalFall_LinCarryInertia__bg171__IYypxr_trajectory.zip
145
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindDeflectMotion_VerticalFall_RollUpSlope__bg156__IzOEVV_trajectory.zip
146
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindDeflectMotion_VerticalFall_SpringStretch__bg177__G2aAEY_trajectory.zip
147
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindPushOppDir_ObliqueProjectile_RollDownSlope__bg167__NmP0aa_trajectory.zip
148
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindPushOppDir_RollDownSlope_RollUpSlope__bg180__qgrBov_trajectory.zip
149
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindPushOppDir_UniformPanelSpin_FrictionStop__bg151__eN0pgF_trajectory.zip
150
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindPushOppDir_UniformPanelSpin_MirrorFragmentReflect__bg177__GxIr7z_trajectory.zip
151
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindPushOppDir_VerticalFall_AccelConcaveSpin__bg177__6IWbv1_trajectory.zip
152
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindPushOppDir_VerticalFall_BalloonFloat__bg156__Y9Evh6_trajectory.zip
153
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindPushOppDir_VerticalFall_FrictionStop__bg180__uU6LvH_trajectory.zip
154
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindPushOppDir_VerticalFall_ImpactFracture__bg156__gCkICC_trajectory.zip
155
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindPushOppDir_VerticalFall_MirrorFragmentReflect__bg167__0GqKKX_trajectory.zip
156
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindPushOppDir_VerticalFall_RollDownSlope__bg180__ykGzsW_trajectory.zip
157
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindPushOppDir_VerticalFall_RollUpSlope__bg185__yM5F90_trajectory.zip
158
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindPushOppDir_VerticalFall_RotTurnableInertia__bg167__wb9rN9_trajectory.zip
159
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindPushOppDir_VerticalFall_SeesawCenterPivot__bg187__8RV7fn_trajectory.zip
160
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindPushOppDir_WindDeflectMotion_BlockWallCollapse__bg169__vw5Mxf_trajectory.zip
161
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindPushOppDir_WindDeflectMotion_FixedConcaveRedirect__bg177__bOEvi2_trajectory.zip
162
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindPushOppDir_WindDeflectMotion_MirrorReflect__bg162__QQZkwF_trajectory.zip
163
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindPushOppDir_WindDeflectMotion_RotTurnableInertia__bg162__lnGl5E_trajectory.zip
164
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindPushOppDir_WindDeflectMotion_SpringboardRebound__bg156__SUy65l_trajectory.zip
165
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindPushOppDir_WindDeflectMotion_UniformSurfaceSpin__bg151__evgHAn_trajectory.zip
166
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindPushSameDir_AccelPanelSpin_MirrorReflect__bg151__JDKRkY_trajectory.zip
167
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindPushSameDir_RollDownSlope_FrictionStop__bg180__NFtB4t_trajectory.zip
168
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindPushSameDir_RollDownSlope_RollUpSlope__bg151__R5fwYx_trajectory.zip
169
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindPushSameDir_SpringCompress_ImpactFracture__bg167__BrRees_trajectory.zip
170
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindPushSameDir_UniformConcaveSpin_BalloonTether__bg180__1Fievf_trajectory.zip
171
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindPushSameDir_VerticalFall_BalloonLift__bg178__ZvGuSk_trajectory.zip
172
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindPushSameDir_VerticalFall_FrictionStop__bg162__LA1esr_trajectory.zip
173
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindPushSameDir_VerticalFall_RollDownSlope__bg167__5k3nyY_trajectory.zip
174
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindPushSameDir_VerticalFall_RollUpSlope__bg157__aEiUJW_trajectory.zip
175
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindPushSameDir_WindDeflectMotion_AccelSurfaceSpin__bg156__tCIBVp_trajectory.zip
176
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindPushSameDir_WindDeflectMotion_BalloonFloat__bg151__yXoQZt_trajectory.zip
177
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindPushSameDir_WindDeflectMotion_RollDownSlope__bg161__sbZ8OV_trajectory.zip
178
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindPushSameDir_WindDeflectMotion_RollUpSlope__bg157__I5Cp9x_trajectory.zip
179
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindPushSameDir_WindDeflectMotion_StickSupportFail__bg162__WI3ZLE_trajectory.zip
180
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindPushSameDir_WindDeflectMotion_VerticalFall__bg156__4qDI0s_trajectory.zip
181
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindPushSameDir_WindPushOppDir_AccelSurfaceSpin__bg180__kPV19v_trajectory.zip
182
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindPushSameDir_WindPushOppDir_BalloonLift__bg167__pZSl0V_trajectory.zip
183
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindPushSameDir_WindPushOppDir_MagnetRepel__bg151__wAkPMK_trajectory.zip
184
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindPushSameDir_WindPushOppDir_RollDownSlope__bg157__qvL57Y_trajectory.zip
185
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindPushStationary_SeesawOffsetPivot_MirrorReflect__bg154__Wbg2gJ_trajectory.zip
186
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindPushStationary_UniformPanelSpin_BalloonTether__bg156__cxmCzT_trajectory.zip
187
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindPushStationary_VerticalFall_AccelConcaveSpin__bg156__sJlOHX_trajectory.zip
188
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindPushStationary_VerticalFall_FrictionStop__bg162__V7VgeP_trajectory.zip
189
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindPushStationary_VerticalFall_MirrorFragmentReflect__bg180__GEEH7G_trajectory.zip
190
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindPushStationary_VerticalFall_RollDownSlope__bg174__KrTbVj_trajectory.zip
191
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindPushStationary_VerticalFall_RollUpSlope__bg163__TwRzOW_trajectory.zip
192
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindPushStationary_VerticalFall_SimplePendulum__bg156__jXREY7_trajectory.zip
193
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindPushStationary_VerticalFall_SpringCompress__bg162__5ZHCOy_trajectory.zip
194
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindPushStationary_WindDeflectMotion_LaserBlock__bg167__Hr7H6N_trajectory.zip
195
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindPushStationary_WindDeflectMotion_MagnetAttract__bg167__r39NNr_trajectory.zip
196
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindPushStationary_WindDeflectMotion_MirrorReflect__bg162__hvYI0f_trajectory.zip
197
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindPushStationary_WindDeflectMotion_RollUpSlope__bg150__xu9M4c_trajectory.zip
198
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindPushStationary_WindDeflectMotion_RotTurnableInertia__bg156__OidiTx_trajectory.zip
199
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindPushStationary_WindDeflectMotion_SpringCompress__bg157__HJRZ3J_trajectory.zip
200
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindPushStationary_WindDeflectMotion_StickSupportFail__bg161__sGxVhe_trajectory.zip
201
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindPushStationary_WindDeflectMotion_UniformPanelSpin__bg194__8rSsBu_trajectory.zip
202
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindPushStationary_WindDeflectMotion_VerticalFall__bg152__0ptwQB_trajectory.zip
203
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindPushStationary_WindPushOppDir_BalloonLift__bg183__F60ALL_trajectory.zip
204
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindPushStationary_WindPushOppDir_BalloonTether__bg177__jjFieL_trajectory.zip
205
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindPushStationary_WindPushOppDir_BlockWallCollapse__bg178__lW1AzR_trajectory.zip
206
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindPushStationary_WindPushOppDir_ElasticCouple__bg156__8g7EuZ_trajectory.zip
207
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindPushStationary_WindPushOppDir_MagnetAttract__bg156__R2v1Pi_trajectory.zip
208
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindPushStationary_WindPushOppDir_MirrorFragmentReflect__bg186__4Oy5iW_trajectory.zip
209
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindPushStationary_WindPushOppDir_SeesawCenterPivot__bg167__QimfBA_trajectory.zip
210
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindPushStationary_WindPushOppDir_SpringStretch__bg155__Todj5E_trajectory.zip
211
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindPushStationary_WindPushOppDir_UniformPanelSpin__bg156__vP7MNz_trajectory.zip
212
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindPushStationary_WindPushOppDir_WindDeflectMotion__bg172__SiH1eh_trajectory.zip
213
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindPushStationary_WindPushSameDir_BalloonLift__bg152__2fsTO2_trajectory.zip
214
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindPushStationary_WindPushSameDir_FrictionStop__bg186__mq6XFU_trajectory.zip
215
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindPushStationary_WindPushSameDir_ImpactFracture__bg180__rwf7dB_trajectory.zip
216
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindPushStationary_WindPushSameDir_MagnetRepel__bg151__qOLuVm_trajectory.zip
217
+ Leaderboard/Motion%20Transfer/TriplePhysics/WindPushStationary_WindPushSameDir_RollDownSlope__bg177__7EUF6V_trajectory.zip
Utils/scripts/download_lists/physical_properties_estimation.txt ADDED
@@ -0,0 +1,74 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ Leaderboard/Physical%20Properties%20Estimation/DoublePhysics/ElasticFall_PlasticineFall__bg852__2QHJQg_trajectory.zip
2
+ Leaderboard/Physical%20Properties%20Estimation/DoublePhysics/ElasticFall_PlasticineFall__bg852__EyOXxy_trajectory.zip
3
+ Leaderboard/Physical%20Properties%20Estimation/DoublePhysics/ElasticFall_PlasticineFall__bg852__ihzgfo_trajectory.zip
4
+ Leaderboard/Physical%20Properties%20Estimation/DoublePhysics/NewtonianFluidFall_GranularFall__bg851__3GTIkU_trajectory.zip
5
+ Leaderboard/Physical%20Properties%20Estimation/DoublePhysics/NewtonianFluidFall_GranularFall__bg851__BlGkE3_trajectory.zip
6
+ Leaderboard/Physical%20Properties%20Estimation/DoublePhysics/NewtonianFluidFall_GranularFall__bg851__fDvosI_trajectory.zip
7
+ Leaderboard/Physical%20Properties%20Estimation/SinglePhysics/ElasticFall__bg851__HyKM4e_trajectory.zip
8
+ Leaderboard/Physical%20Properties%20Estimation/SinglePhysics/ElasticFall__bg851__ONA90r_trajectory.zip
9
+ Leaderboard/Physical%20Properties%20Estimation/SinglePhysics/ElasticFall__bg851__Urfkor_trajectory.zip
10
+ Leaderboard/Physical%20Properties%20Estimation/SinglePhysics/ElasticFall__bg851__aZnA3h_trajectory.zip
11
+ Leaderboard/Physical%20Properties%20Estimation/SinglePhysics/ElasticFall__bg851__tCRMt3_trajectory.zip
12
+ Leaderboard/Physical%20Properties%20Estimation/SinglePhysics/ElasticFall__bg851__wBxhzP_trajectory.zip
13
+ Leaderboard/Physical%20Properties%20Estimation/SinglePhysics/ElasticFall__bg852__n4vNbZ_trajectory.zip
14
+ Leaderboard/Physical%20Properties%20Estimation/SinglePhysics/ElasticFall__bg852__rueoHR_trajectory.zip
15
+ Leaderboard/Physical%20Properties%20Estimation/SinglePhysics/ElasticFall__bg852__tgPNPs_trajectory.zip
16
+ Leaderboard/Physical%20Properties%20Estimation/SinglePhysics/ElasticFall__bg853__IKwBRg_trajectory.zip
17
+ Leaderboard/Physical%20Properties%20Estimation/SinglePhysics/ElasticFall__bg853__ZT7AUD_trajectory.zip
18
+ Leaderboard/Physical%20Properties%20Estimation/SinglePhysics/ElasticFall__bg853__cPLVum_trajectory.zip
19
+ Leaderboard/Physical%20Properties%20Estimation/SinglePhysics/GranularFall__bg851__9lIDU3_trajectory.zip
20
+ Leaderboard/Physical%20Properties%20Estimation/SinglePhysics/GranularFall__bg851__JBM15M_trajectory.zip
21
+ Leaderboard/Physical%20Properties%20Estimation/SinglePhysics/GranularFall__bg851__U3Jlvj_trajectory.zip
22
+ Leaderboard/Physical%20Properties%20Estimation/SinglePhysics/GranularFall__bg851__Vbe8dQ_trajectory.zip
23
+ Leaderboard/Physical%20Properties%20Estimation/SinglePhysics/GranularFall__bg851__ioGrE8_trajectory.zip
24
+ Leaderboard/Physical%20Properties%20Estimation/SinglePhysics/GranularFall__bg851__osQrjq_trajectory.zip
25
+ Leaderboard/Physical%20Properties%20Estimation/SinglePhysics/GranularFall__bg852__MoyIIZ_trajectory.zip
26
+ Leaderboard/Physical%20Properties%20Estimation/SinglePhysics/GranularFall__bg852__VyRLV3_trajectory.zip
27
+ Leaderboard/Physical%20Properties%20Estimation/SinglePhysics/GranularFall__bg852__tDtaft_trajectory.zip
28
+ Leaderboard/Physical%20Properties%20Estimation/SinglePhysics/GranularFall__bg853__H2LWew_trajectory.zip
29
+ Leaderboard/Physical%20Properties%20Estimation/SinglePhysics/GranularFall__bg853__ZBMM7p_trajectory.zip
30
+ Leaderboard/Physical%20Properties%20Estimation/SinglePhysics/GranularFall__bg853__yXif8O_trajectory.zip
31
+ Leaderboard/Physical%20Properties%20Estimation/SinglePhysics/NewtonianFluidFall__bg851__9UuymC_trajectory.zip
32
+ Leaderboard/Physical%20Properties%20Estimation/SinglePhysics/NewtonianFluidFall__bg851__D4npMS_trajectory.zip
33
+ Leaderboard/Physical%20Properties%20Estimation/SinglePhysics/NewtonianFluidFall__bg851__gvvzoP_trajectory.zip
34
+ Leaderboard/Physical%20Properties%20Estimation/SinglePhysics/NewtonianFluidFall__bg851__ksCdUy_trajectory.zip
35
+ Leaderboard/Physical%20Properties%20Estimation/SinglePhysics/NewtonianFluidFall__bg851__q9BCMV_trajectory.zip
36
+ Leaderboard/Physical%20Properties%20Estimation/SinglePhysics/NewtonianFluidFall__bg851__vHyaMH_trajectory.zip
37
+ Leaderboard/Physical%20Properties%20Estimation/SinglePhysics/NewtonianFluidFall__bg852__2WIQvD_trajectory.zip
38
+ Leaderboard/Physical%20Properties%20Estimation/SinglePhysics/NewtonianFluidFall__bg852__JtG3Vh_trajectory.zip
39
+ Leaderboard/Physical%20Properties%20Estimation/SinglePhysics/NewtonianFluidFall__bg852__dLPzqy_trajectory.zip
40
+ Leaderboard/Physical%20Properties%20Estimation/SinglePhysics/NewtonianFluidFall__bg853__Mw45TL_trajectory.zip
41
+ Leaderboard/Physical%20Properties%20Estimation/SinglePhysics/NewtonianFluidFall__bg853__flqAQw_trajectory.zip
42
+ Leaderboard/Physical%20Properties%20Estimation/SinglePhysics/NewtonianFluidFall__bg853__wJG4hq_trajectory.zip
43
+ Leaderboard/Physical%20Properties%20Estimation/SinglePhysics/NonNewtonianFluidFall__bg851__1e9y4t_trajectory.zip
44
+ Leaderboard/Physical%20Properties%20Estimation/SinglePhysics/NonNewtonianFluidFall__bg851__CUmiwi_trajectory.zip
45
+ Leaderboard/Physical%20Properties%20Estimation/SinglePhysics/NonNewtonianFluidFall__bg851__D8DZBH_trajectory.zip
46
+ Leaderboard/Physical%20Properties%20Estimation/SinglePhysics/NonNewtonianFluidFall__bg851__NkuHcR_trajectory.zip
47
+ Leaderboard/Physical%20Properties%20Estimation/SinglePhysics/NonNewtonianFluidFall__bg851__i7JDwF_trajectory.zip
48
+ Leaderboard/Physical%20Properties%20Estimation/SinglePhysics/NonNewtonianFluidFall__bg851__xNRybL_trajectory.zip
49
+ Leaderboard/Physical%20Properties%20Estimation/SinglePhysics/NonNewtonianFluidFall__bg852__KrdygQ_trajectory.zip
50
+ Leaderboard/Physical%20Properties%20Estimation/SinglePhysics/NonNewtonianFluidFall__bg852__N1F0si_trajectory.zip
51
+ Leaderboard/Physical%20Properties%20Estimation/SinglePhysics/NonNewtonianFluidFall__bg852__yYzlwK_trajectory.zip
52
+ Leaderboard/Physical%20Properties%20Estimation/SinglePhysics/NonNewtonianFluidFall__bg853__3NsWvc_trajectory.zip
53
+ Leaderboard/Physical%20Properties%20Estimation/SinglePhysics/NonNewtonianFluidFall__bg853__X8RW5t_trajectory.zip
54
+ Leaderboard/Physical%20Properties%20Estimation/SinglePhysics/NonNewtonianFluidFall__bg853__raldSU_trajectory.zip
55
+ Leaderboard/Physical%20Properties%20Estimation/SinglePhysics/PlasticineFall__bg851__CJa9sg_trajectory.zip
56
+ Leaderboard/Physical%20Properties%20Estimation/SinglePhysics/PlasticineFall__bg851__Eo4QFG_trajectory.zip
57
+ Leaderboard/Physical%20Properties%20Estimation/SinglePhysics/PlasticineFall__bg851__QhSP1w_trajectory.zip
58
+ Leaderboard/Physical%20Properties%20Estimation/SinglePhysics/PlasticineFall__bg851__SR7SHn_trajectory.zip
59
+ Leaderboard/Physical%20Properties%20Estimation/SinglePhysics/PlasticineFall__bg851__fR29iu_trajectory.zip
60
+ Leaderboard/Physical%20Properties%20Estimation/SinglePhysics/PlasticineFall__bg851__mzVWKS_trajectory.zip
61
+ Leaderboard/Physical%20Properties%20Estimation/SinglePhysics/PlasticineFall__bg852__IovT0U_trajectory.zip
62
+ Leaderboard/Physical%20Properties%20Estimation/SinglePhysics/PlasticineFall__bg852__QYLkjv_trajectory.zip
63
+ Leaderboard/Physical%20Properties%20Estimation/SinglePhysics/PlasticineFall__bg852__TEgEeY_trajectory.zip
64
+ Leaderboard/Physical%20Properties%20Estimation/SinglePhysics/PlasticineFall__bg853__AudM59_trajectory.zip
65
+ Leaderboard/Physical%20Properties%20Estimation/SinglePhysics/PlasticineFall__bg853__JqI201_trajectory.zip
66
+ Leaderboard/Physical%20Properties%20Estimation/SinglePhysics/PlasticineFall__bg853__wWdOlo_trajectory.zip
67
+ Leaderboard/Physical%20Properties%20Estimation/TriplePhysics/ElasticFall_PlasticineFall_GranularFall__bg853__S2qLvS_trajectory.zip
68
+ Leaderboard/Physical%20Properties%20Estimation/TriplePhysics/ElasticFall_PlasticineFall_GranularFall__bg853__t7AbFK_trajectory.zip
69
+ Leaderboard/Physical%20Properties%20Estimation/TriplePhysics/ElasticFall_PlasticineFall_GranularFall__bg853__uzqMDe_trajectory.zip
70
+ Leaderboard/Physical%20Properties%20Estimation/TriplePhysics/NewtonianFluidFall_NonNewtonianFluidFall_ElasticFall__bg852__EyPG9y_trajectory.zip
71
+ Leaderboard/Physical%20Properties%20Estimation/TriplePhysics/NewtonianFluidFall_NonNewtonianFluidFall_ElasticFall__bg852__YklJCP_trajectory.zip
72
+ Leaderboard/Physical%20Properties%20Estimation/TriplePhysics/NewtonianFluidFall_NonNewtonianFluidFall_ElasticFall__bg852__rGZfig_trajectory.zip
73
+ Leaderboard/Physical%20Properties%20Estimation/test_supp_info/Test_sdf.zip
74
+ Leaderboard/Physical%20Properties%20Estimation/test_supp_info/test_case_supp_map.json
Utils/scripts/download_lists/repo_assignment.txt ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:380a0ba378cd4c2e89b1fc6b6c26c5adf01e65f2c1c1a0c62862d360c47091ab
3
+ size 21608478
Utils/scripts/download_lists/repo_map.json ADDED
@@ -0,0 +1,18 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "physinone_part1": "PhysInOneP01/PhysInOneP01",
3
+ "physinone_part2": "PhysInOneP02/PhysInOneP02",
4
+ "physinone_part3": "PhysInOneP03/PhysInOneP03",
5
+ "physinone_part4": "PhysInOneP04/PhysInOneP04",
6
+ "physinone_part5": "PhysInOneP05/PhysInOneP05",
7
+ "physinone_part6": "PhysInOneP06/PhysInOneP06",
8
+ "physinone_part7": "PhysInOneP07/PhysInOneP07",
9
+ "physinone_part8": "PhysInOneP08/PhysInOneP08",
10
+ "physinone_part9": "PhysInOneP09/PhysInOneP09",
11
+ "physinone_part10": "PhysInOneP10/PhysInOneP10",
12
+ "physinone_part11": "PhysInOneP11/PhysInOneP11",
13
+ "physinone_part12": "PhysInOneP12/PhysInOneP12",
14
+ "physinone_part13": "PhysInOneP13/PhysInOneP13",
15
+ "physinone_part14": "PhysInOneP14/PhysInOneP14",
16
+ "physinone_part15": "PhysInOneP15/PhysInOneP15",
17
+ "physinone_part16": "PhysInOneP16/PhysInOneP16"
18
+ }
Utils/scripts/download_lists/video_generation.txt ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:84c97a157b7db74fed69b196d271ecd855518a0c13e29fe64bc03dfbea8d745b
3
+ size 10719694
Utils/scripts/download_selected.py ADDED
@@ -0,0 +1,275 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ #!/usr/bin/env python3
2
+ """Download selected public PhysInOne scene archives from dataset shards."""
3
+
4
+ from __future__ import annotations
5
+
6
+ import argparse
7
+ import json
8
+ import re
9
+ import sys
10
+ import threading
11
+ from concurrent.futures import ThreadPoolExecutor, as_completed
12
+ from datetime import datetime
13
+ from pathlib import Path, PurePosixPath
14
+ from typing import Optional, Sequence
15
+ from urllib.parse import quote, urlparse
16
+
17
+ from download_data import DownloadResult, download_file, utc_now
18
+
19
+
20
+ SCRIPT_ROOT = Path(__file__).resolve().parent
21
+ DEFAULT_SELECTION = Path("selected_cases.json")
22
+ DEFAULT_REPO_MAP = SCRIPT_ROOT / "download_lists" / "repo_map.json"
23
+
24
+
25
+ def load_json(path: Path) -> object:
26
+ if not path.is_file():
27
+ raise FileNotFoundError(f"file not found: {path}")
28
+ return json.loads(path.read_text(encoding="utf-8"))
29
+
30
+
31
+ def normalize_repository(value: str) -> str:
32
+ value = value.strip().rstrip("/")
33
+ if value.startswith(("http://", "https://")):
34
+ parsed = urlparse(value)
35
+ parts = [part for part in parsed.path.split("/") if part]
36
+ if len(parts) >= 3 and parts[0] == "datasets":
37
+ value = f"{parts[1]}/{parts[2]}"
38
+ else:
39
+ raise ValueError(f"cannot parse dataset repository URL: {value}")
40
+ if not re.fullmatch(r"[A-Za-z0-9_.-]+/[A-Za-z0-9_.-]+", value):
41
+ raise ValueError(f"invalid dataset repository name: {value}")
42
+ return value
43
+
44
+
45
+ def load_repo_map(path: Path) -> dict[str, str]:
46
+ raw = load_json(path)
47
+ if not isinstance(raw, dict):
48
+ raise ValueError("repository map must be a JSON object")
49
+ return {str(key): normalize_repository(str(value)) for key, value in raw.items()}
50
+
51
+
52
+ def safe_component(value: object, field: str) -> str:
53
+ text = str(value)
54
+ if not text or text in {".", ".."} or "/" in text or "\\" in text:
55
+ raise ValueError(f"unsafe {field}: {text!r}")
56
+ if any(character.isspace() for character in text):
57
+ raise ValueError(f"{field} contains whitespace: {text!r}")
58
+ return text
59
+
60
+
61
+ def encoded_remote_path(case: dict) -> str:
62
+ raw = str(case.get("hf_zip_path", ""))
63
+ path = PurePosixPath(raw)
64
+ if path.is_absolute() or not path.parts:
65
+ raise ValueError(f"unsafe dataset path: {raw!r}")
66
+ if any(part in {"", ".", ".."} for part in path.parts) or "\\" in raw:
67
+ raise ValueError(f"unsafe dataset path: {raw!r}")
68
+ return quote(raw, safe="/._-~")
69
+
70
+
71
+ def output_path(output_dir: Path, case: dict, keep_structure: bool) -> Path:
72
+ remote = PurePosixPath(str(case["hf_zip_path"]))
73
+ filename = safe_component(remote.name, "archive name")
74
+ if not keep_structure:
75
+ return output_dir / filename
76
+ return output_dir.joinpath(
77
+ safe_component(case["part_id"], "part ID"),
78
+ safe_component(case["split"], "split"),
79
+ safe_component(case["activity_type"], "activity type"),
80
+ filename,
81
+ )
82
+
83
+
84
+ class Logs:
85
+ def __init__(self, root: Path) -> None:
86
+ self.root = root
87
+ self.root.mkdir(parents=True, exist_ok=True)
88
+ self.success = root / "downloads.tsv"
89
+ self.failures = root / "failures.tsv"
90
+ self._lock = threading.Lock()
91
+ self.success.write_text(
92
+ "case_id\trepository\tremote_path\tlocal_path\tstatus\tbytes_written\ttimestamp\n",
93
+ encoding="utf-8",
94
+ )
95
+ self.failures.write_text(
96
+ "case_id\trepository\tremote_path\terror\ttimestamp\n",
97
+ encoding="utf-8",
98
+ )
99
+
100
+ def record(self, case_id: str, repository: str, result: DownloadResult) -> None:
101
+ now = utc_now()
102
+ with self._lock:
103
+ if result.error:
104
+ with self.failures.open("a", encoding="utf-8") as handle:
105
+ handle.write(
106
+ f"{case_id}\t{repository}\t{result.remote_path}\t"
107
+ f"{result.error}\t{now}\n"
108
+ )
109
+ else:
110
+ with self.success.open("a", encoding="utf-8") as handle:
111
+ handle.write(
112
+ f"{case_id}\t{repository}\t{result.remote_path}\t"
113
+ f"{result.local_path}\t{result.status}\t"
114
+ f"{result.bytes_written}\t{now}\n"
115
+ )
116
+
117
+
118
+ def build_parser() -> argparse.ArgumentParser:
119
+ parser = argparse.ArgumentParser(
120
+ description="Download selected public PhysInOne scene archives."
121
+ )
122
+ parser.add_argument(
123
+ "--selection",
124
+ type=Path,
125
+ default=DEFAULT_SELECTION,
126
+ help="Selection JSON produced by filter_cases.py (default: selected_cases.json).",
127
+ )
128
+ parser.add_argument(
129
+ "--repo-map",
130
+ "--repo_map",
131
+ dest="repo_map",
132
+ type=Path,
133
+ default=DEFAULT_REPO_MAP,
134
+ help="Dataset shard map supplied with this repository.",
135
+ )
136
+ parser.add_argument(
137
+ "--output-dir",
138
+ "--output_dir",
139
+ dest="output_dir",
140
+ type=Path,
141
+ default=Path("PhysInOne_data/full_dataset"),
142
+ help="Whitespace-free local output directory.",
143
+ )
144
+ parser.add_argument(
145
+ "--revision", default="main", help="Dataset revision (default: main)."
146
+ )
147
+ parser.add_argument(
148
+ "--workers", type=int, default=4, help="Concurrent downloads (default: 4)."
149
+ )
150
+ parser.add_argument(
151
+ "--retries", type=int, default=3, help="Retries after each failure (default: 3)."
152
+ )
153
+ parser.add_argument(
154
+ "--timeout", type=float, default=60.0, help="Request timeout in seconds."
155
+ )
156
+ parser.add_argument(
157
+ "--keep-shard-structure",
158
+ "--keep_shard_structure",
159
+ dest="keep_shard_structure",
160
+ action="store_true",
161
+ help="Preserve part/split/activity directories instead of a flat output.",
162
+ )
163
+ parser.add_argument(
164
+ "--no-resume",
165
+ action="store_true",
166
+ help="Restart incomplete .part files instead of resuming them.",
167
+ )
168
+ parser.add_argument(
169
+ "--overwrite", action="store_true", help="Replace completed local files."
170
+ )
171
+ parser.add_argument(
172
+ "--dry-run",
173
+ "--dry_run",
174
+ dest="dry_run",
175
+ action="store_true",
176
+ help="Print the planned transfers without downloading.",
177
+ )
178
+ return parser
179
+
180
+
181
+ def main(argv: Optional[Sequence[str]] = None) -> int:
182
+ args = build_parser().parse_args(argv)
183
+ if args.workers < 1:
184
+ raise SystemExit("--workers must be at least 1")
185
+ if args.retries < 0:
186
+ raise SystemExit("--retries cannot be negative")
187
+ if args.timeout <= 0:
188
+ raise SystemExit("--timeout must be positive")
189
+ if any(character.isspace() for character in str(args.output_dir)):
190
+ raise SystemExit("--output-dir must not contain whitespace")
191
+
192
+ selection = load_json(args.selection)
193
+ if not isinstance(selection, dict) or not isinstance(selection.get("cases"), list):
194
+ raise ValueError("selection JSON must contain a list named 'cases'")
195
+ cases = selection["cases"]
196
+ repository_map = load_repo_map(args.repo_map)
197
+ missing = sorted(
198
+ {
199
+ str(case.get("part_id", ""))
200
+ for case in cases
201
+ if str(case.get("part_id", "")) not in repository_map
202
+ }
203
+ )
204
+ if missing:
205
+ raise KeyError("part IDs missing from repository map: " + ", ".join(missing))
206
+
207
+ output_dir = args.output_dir.expanduser().resolve()
208
+ planned = []
209
+ for case in cases:
210
+ part_id = str(case["part_id"])
211
+ planned.append(
212
+ (
213
+ str(case.get("case_id", "")),
214
+ repository_map[part_id],
215
+ encoded_remote_path(case),
216
+ output_path(output_dir, case, args.keep_shard_structure),
217
+ )
218
+ )
219
+
220
+ print(f"cases: {len(planned)}")
221
+ if args.dry_run:
222
+ for case_id, repository, remote_path, destination in planned[:20]:
223
+ print(f"{case_id}: {repository}/{remote_path} -> {destination}")
224
+ if len(planned) > 20:
225
+ print(f"... and {len(planned) - 20} more")
226
+ return 0
227
+
228
+ output_dir.mkdir(parents=True, exist_ok=True)
229
+ run_id = datetime.now().strftime("%Y%m%d_%H%M%S")
230
+ logs = Logs(output_dir / "_download_logs" / run_id)
231
+ results = []
232
+ with ThreadPoolExecutor(max_workers=args.workers) as pool:
233
+ futures = {
234
+ pool.submit(
235
+ download_file,
236
+ "full_dataset",
237
+ remote_path,
238
+ destination,
239
+ args.revision,
240
+ args.timeout,
241
+ args.retries,
242
+ not args.no_resume,
243
+ args.overwrite,
244
+ False,
245
+ repository,
246
+ ): (case_id, repository)
247
+ for case_id, repository, remote_path, destination in planned
248
+ }
249
+ total = len(futures)
250
+ for completed, future in enumerate(as_completed(futures), start=1):
251
+ case_id, repository = futures[future]
252
+ result = future.result()
253
+ results.append(result)
254
+ logs.record(case_id, repository, result)
255
+ label = result.status if not result.error else f"failed: {result.error}"
256
+ print(f"[{completed}/{total}] {label}: {case_id}")
257
+
258
+ failures = sum(1 for result in results if result.error)
259
+ summary = {
260
+ "selected_cases": len(planned),
261
+ "successful_downloads": len(results) - failures,
262
+ "download_failures": failures,
263
+ "output_dir": str(output_dir),
264
+ "log_dir": str(logs.root),
265
+ "finished_at": utc_now(),
266
+ }
267
+ (logs.root / "summary.json").write_text(
268
+ json.dumps(summary, indent=2, sort_keys=True) + "\n", encoding="utf-8"
269
+ )
270
+ print(json.dumps(summary, indent=2, sort_keys=True))
271
+ return 1 if failures else 0
272
+
273
+
274
+ if __name__ == "__main__":
275
+ raise SystemExit(main())
Utils/scripts/filter_cases.py CHANGED
@@ -24,10 +24,10 @@ import random
24
  import re
25
  from dataclasses import asdict, dataclass
26
  from pathlib import Path
27
- from typing import Iterable, Literal
28
 
29
 
30
- DEFAULT_ASSIGNMENT_FILE = Path("metadata/repo_assignment.txt")
31
 
32
 
33
  SUPPORTED_PHENOMENA = {
@@ -135,7 +135,7 @@ class CaseRecord:
135
  hf_zip_path: str
136
 
137
 
138
- def normalize_split(value: str | None) -> str | None:
139
  if value is None:
140
  return None
141
  key = value.strip().lower()
@@ -146,7 +146,7 @@ def normalize_split(value: str | None) -> str | None:
146
  return SPLIT_ALIASES[key]
147
 
148
 
149
- def normalize_activity(value: str | None) -> str | None:
150
  if value is None:
151
  return None
152
  key = value.strip().lower()
@@ -157,7 +157,7 @@ def normalize_activity(value: str | None) -> str | None:
157
  return ACTIVITY_ALIASES[key]
158
 
159
 
160
- def validate_phenomena(values: list[str] | None) -> list[str] | None:
161
  if not values:
162
  return values
163
 
@@ -173,7 +173,7 @@ def validate_phenomena(values: list[str] | None) -> list[str] | None:
173
  return values
174
 
175
 
176
- def parse_case_line(line: str, line_no: int) -> CaseRecord | None:
177
  line = line.strip()
178
  if not line or line.startswith("#"):
179
  return None
@@ -210,8 +210,8 @@ def parse_case_line(line: str, line_no: int) -> CaseRecord | None:
210
  if "__" not in case_id:
211
  raise ValueError(f"Line {line_no}: cannot parse case_id: {case_id}")
212
 
213
- tokens = case_id.split("__")
214
- phenomenon_token = tokens[0]
215
  phenomena = phenomenon_token.split("_") if phenomenon_token else []
216
 
217
  invalid_in_file = sorted(set(phenomena) - SUPPORTED_PHENOMENA)
@@ -235,16 +235,16 @@ def parse_case_line(line: str, line_no: int) -> CaseRecord | None:
235
 
236
  background = ""
237
  hash_code = ""
238
- for token in tokens[1:]:
239
- if re.fullmatch(r"bg\d+", token):
240
- background = token
241
  else:
242
- hash_code = token
243
 
244
  if not background:
245
- raise ValueError(f"Line {line_no}: background token not found in case_id: {case_id}")
246
  if not hash_code:
247
- raise ValueError(f"Line {line_no}: hash token not found in case_id: {case_id}")
248
 
249
  hf_zip_path = f"{split}/{activity_type}/{case_id}_trajectory.zip"
250
 
@@ -299,9 +299,9 @@ def record_matches_phenomena(
299
 
300
  def filter_records(
301
  records: list[CaseRecord],
302
- split: str | None = None,
303
- activity_type: str | None = None,
304
- phenomena: list[str] | None = None,
305
  match_mode: Literal["contains", "exact"] = "contains",
306
  ) -> list[CaseRecord]:
307
  split_norm = normalize_split(split)
 
24
  import re
25
  from dataclasses import asdict, dataclass
26
  from pathlib import Path
27
+ from typing import Iterable, Literal, Optional
28
 
29
 
30
+ DEFAULT_ASSIGNMENT_FILE = Path(__file__).resolve().parent / "download_lists" / "repo_assignment.txt"
31
 
32
 
33
  SUPPORTED_PHENOMENA = {
 
135
  hf_zip_path: str
136
 
137
 
138
+ def normalize_split(value: Optional[str]) -> Optional[str]:
139
  if value is None:
140
  return None
141
  key = value.strip().lower()
 
146
  return SPLIT_ALIASES[key]
147
 
148
 
149
+ def normalize_activity(value: Optional[str]) -> Optional[str]:
150
  if value is None:
151
  return None
152
  key = value.strip().lower()
 
157
  return ACTIVITY_ALIASES[key]
158
 
159
 
160
+ def validate_phenomena(values: Optional[list[str]]) -> Optional[list[str]]:
161
  if not values:
162
  return values
163
 
 
173
  return values
174
 
175
 
176
+ def parse_case_line(line: str, line_no: int) -> Optional[CaseRecord]:
177
  line = line.strip()
178
  if not line or line.startswith("#"):
179
  return None
 
210
  if "__" not in case_id:
211
  raise ValueError(f"Line {line_no}: cannot parse case_id: {case_id}")
212
 
213
+ segments = case_id.split("__")
214
+ phenomenon_token = segments[0]
215
  phenomena = phenomenon_token.split("_") if phenomenon_token else []
216
 
217
  invalid_in_file = sorted(set(phenomena) - SUPPORTED_PHENOMENA)
 
235
 
236
  background = ""
237
  hash_code = ""
238
+ for segment in segments[1:]:
239
+ if re.fullmatch(r"bg\d+", segment):
240
+ background = segment
241
  else:
242
+ hash_code = segment
243
 
244
  if not background:
245
+ raise ValueError(f"Line {line_no}: background segment not found in case_id: {case_id}")
246
  if not hash_code:
247
+ raise ValueError(f"Line {line_no}: hash segment not found in case_id: {case_id}")
248
 
249
  hf_zip_path = f"{split}/{activity_type}/{case_id}_trajectory.zip"
250
 
 
299
 
300
  def filter_records(
301
  records: list[CaseRecord],
302
+ split: Optional[str] = None,
303
+ activity_type: Optional[str] = None,
304
+ phenomena: Optional[list[str]] = None,
305
  match_mode: Literal["contains", "exact"] = "contains",
306
  ) -> list[CaseRecord]:
307
  split_norm = normalize_split(split)