Download InterHand2.6M/code/finish_when_ready.py from WhynotGPT/Pretrain: direct link, hf CLI and curl.
- Browser
- Download file 635 Bytes
-
https://huggingface.co/datasets/WhynotGPT/Pretrain/resolve/main/InterHand2.6M/code/finish_when_ready.py
- Command line
-
hf download hf://datasets/WhynotGPT/Pretrain/InterHand2.6M/code/finish_when_ready.py
-
curl -L -o finish_when_ready.py https://huggingface.co/datasets/WhynotGPT/Pretrain/resolve/main/InterHand2.6M/code/finish_when_ready.py
635 Bytes
| from pathlib import Path | |
| import json,time,subprocess | |
| r=Path('/SSD1/yangzijing/InterHand2.6M') | |
| while True: | |
| if (r/'audit/images_extraction_failure.json').exists(): | |
| raise SystemExit('Image extraction failed; see audit/images_extraction_failure.json') | |
| p=r/'audit/images_extraction.json' | |
| if p.exists() and json.loads(p.read_text()).get('status')=='complete':break | |
| time.sleep(10) | |
| a=json.loads((r/'audit/annotations_verification.json').read_text()) | |
| if not a['complete']:raise SystemExit('Annotations incomplete') | |
| raise SystemExit(subprocess.call(['/SSD2/jiasen/envs/foundation_hand/bin/python','-u',str(r/'code/validate_dataset.py')])) | |