|
Download README.md from Potestates/DeepSparse-25v: direct link, hf CLI and curl.
- Browser
- Download file 4.44 kB
-
https://huggingface.co/Potestates/DeepSparse-25v/resolve/main/README.md
- Command line
-
hf download hf://Potestates/DeepSparse-25v/README.md
-
curl -L -o README.md https://huggingface.co/Potestates/DeepSparse-25v/resolve/main/README.md
4.44 kB
| license: other | |
| license_name: mixed-see-readme | |
| tags: | |
| - sparse-view-ct | |
| - cbct | |
| - ct-reconstruction | |
| - medical-imaging | |
| - deepsparse | |
| # DeepSparse — 25-view finetuned checkpoints | |
| Finetuned checkpoints of [DeepSparse](https://github.com/xmed-lab/DeepSparse) for **25-view (180°) sparse-view CT reconstruction** on four anatomies. All models start from the official pretrained weights (`pretrain/ep_700.pth` from [HajihajihaJimmy/DeepSparse](https://huggingface.co/HajihajihaJimmy/DeepSparse)) and use the official two-stage finetuning protocol. | |
| The folder layout matches the official repo, so the checkpoints drop into the codebase's `logs/` directory. | |
| ## Results (official test splits, 256³, 3D PSNR / SSIM) | |
| | Checkpoint | Train cases | Test cases | PSNR (dB) | SSIM (×10⁻²) | | |
| |---|---|---|---|---| | |
| | `pelvis+25v+n250+s2` (PENGWIN) | 60 (all) | 30 | **30.96** ± 2.63 | **90.31** ± 3.20 | | |
| | `luna+25v+n250+s2` (LUNA16) | 250 / 738 | 100 | **32.47** ± 1.05 | **92.33** ± 1.83 | | |
| | `abdomen+25v+n250+s2` (PANORAMA) | 250 / 1244 | 600 | **29.79** ± 2.11 | **89.52** ± 3.21 | | |
| | `tooth+25v+n250+s2` (ToothFairy) | 250 / 343 | 75 | **34.03** ± 1.15 | **94.29** ± 1.53 | | |
| Mean ± std over test cases, from the official `code/evaluate.py`. Per-case results are in each folder's `results_1.0x.csv`. | |
| For reference, paper Table III (10 views, full training sets): pelvis 29.03 / 90.27, LUNA16 31.86 / 91.41, abdomen 29.42 / 88.36, tooth 31.79 / 92.50. On the full LUNA16 test set, the official 10-view checkpoint gives 31.79 / 91.46 on our preprocessed data. | |
| ## Setup | |
| - Code: xmed-lab/DeepSparse @ `a055aba3bcb5732a68f89cc0bf3ee6fbfbb1b1e4` | |
| - Views: 25 input views, uniformly over 180°, taken from a 300-view projection cache | |
| - Stage 1: `--num_views 30 --vq_w 0.1`, resumed from `pretrain/ep_700.pth`, 400 epochs | |
| - Stage 2: `--num_views 30 --min_views 25 --random_views --vq_w 1.0 --safely_load --freeze_ft`, resumed from stage-1 `ep_400.pth`, 400 epochs | |
| - Batch size 2, lr 1e-4, weight decay 1e-3, no LR schedule, 1 GPU per job | |
| - Environment: PyTorch 2.7.1 + CUDA 12.8, TIGRE 3.1.3 | |
| ## Differences from the paper protocol | |
| 1. **Training set size**: at most 250 training cases per dataset (the paper uses the full training sets). Test splits are the official ones. The exact case lists are in `splits/<DATASET>/meta_info.json`. | |
| 2. **Dense views**: `num_views=30` during training, so stage 2 has a teacher/student view ratio of 1.2× (official: 24 dense views vs 6/8/10). | |
| 3. **Environment**: newer PyTorch and TIGRE than the official (PyTorch 1.13, TIGRE 2.3), needed for Blackwell GPUs. | |
| 4. **ToothFairy config**: the official `meta_info.json` references an unreleased `config+new.yaml` / `processed+new/`. We use the repo's public `config.yaml`. The official tooth 10-view checkpoint reproduces the paper numbers with this config (31.89 / 92.74). | |
| ## Files | |
| ``` | |
| <dataset>+25v+n250+s2/ | |
| ep_400.pth final stage-2 checkpoint (use this) | |
| config.yaml config saved by train.py (note: min_views stays 10 here) | |
| results_1.0x.csv per-case test PSNR/SSIM + average | |
| train.log stage-2 training log (args + val curve) | |
| train_s1.log stage-1 training log | |
| configs/ | |
| finetune_s1_n250.yaml, finetune_s2_n250.yaml training configs (root_dir ./data_n250) | |
| eval_25v_n250.yaml evaluation config (min_views: 25) | |
| splits/<DATASET>/meta_info.json train/eval/test case lists used | |
| ``` | |
| ## Usage | |
| ```bash | |
| # inside a DeepSparse checkout with data prepared as in the official README | |
| hf download Potestates/DeepSparse-25v --local-dir ./logs | |
| cp logs/configs/eval_25v_n250.yaml configs/generated/ # set root_dir to your data root | |
| python code/evaluate.py --name luna+25v+n250+s2 --epoch 400 --dst_name luna \ | |
| --split test --num_views 25 --cfg_path configs/generated/eval_25v_n250.yaml \ | |
| --out_res_scale 1.0 | |
| ``` | |
| Evaluation must use `min_views: 25`. The `config.yaml` saved inside each checkpoint folder keeps `min_views: 10`, so use `configs/eval_25v_n250.yaml` instead. | |
| ## License | |
| The DeepSparse code is MIT. These weights are derived from datasets with their own terms. Check each dataset's license before use: | |
| - PANORAMA (abdomen): CC BY-NC 4.0 (**non-commercial**) | |
| - PENGWIN (pelvis): CC BY 4.0 | |
| - LUNA16 (lung), ToothFairy (tooth): see the original dataset terms | |
| Please cite the DeepSparse paper and the datasets if you use these checkpoints. | |