MichaelGlo commited on
Commit
a11073f
·
verified ·
1 Parent(s): 172a199

Use inference notebook for model card quick start

Browse files
Files changed (1) hide show
  1. README.md +15 -11
README.md CHANGED
@@ -12,7 +12,7 @@ tags:
12
 
13
  # XGLASS: X-Ray, Gaze and Language Assisted Slice Sequencing for CT Volumes
14
 
15
- Accepted at WACV2027.
16
 
17
  ![XGLASS pipeline](Final_pipeline.svg)
18
 
@@ -23,21 +23,25 @@ Vision-language models (VLMs) achieve remarkable performance on 2D medical image
23
  [Download checkpoint (1.04 GB)](https://huggingface.co/MichaelGlo/XGLASS/resolve/main/xglass.ckpt?download=true)
24
  · [GitHub: code and documentation](https://github.com/michaelgloeckler/XGLASS)
25
 
26
- ## Quick start
27
 
28
- Use Python 3.11. Prepare normalized CT projections using the
29
- [data preparation guide](https://github.com/michaelgloeckler/XGLASS/blob/main/data/README.md),
30
- including `manifest.csv`, per-case projection/metadata files, and the matching
31
- split file. The supplied gaze priors are included in GitHub.
32
 
33
  ```bash
34
  git clone https://github.com/michaelgloeckler/XGLASS.git
35
  cd XGLASS
36
  pip install -r requirements.txt huggingface_hub
37
- hf download MichaelGlo/XGLASS xglass.ckpt --local-dir checkpoints
38
- python src/xglass/export_orders.py --ckpt_path checkpoints/xglass.ckpt --data_root data/processed/projection_dataset --heatmap_dir data/processed/gaze_importance_maps --splits_json splits/paper_splits.json --projection_type aip_wide --blend_alpha 0.75 --out_orders_dir results/orders/xglass
39
  ```
40
 
41
- The command writes a ranking for each CT–finding pair in the test split.
42
- Indices refer to the normalized 240-slice CT block. For visualization, see the
43
- [inference notebook](https://github.com/michaelgloeckler/XGLASS/blob/main/demo/infer_demo.ipynb).
 
 
 
 
 
 
 
 
 
12
 
13
  # XGLASS: X-Ray, Gaze and Language Assisted Slice Sequencing for CT Volumes
14
 
15
+ Michael Glöckler and Timo Ropinski · Ulm University
16
 
17
  ![XGLASS pipeline](Final_pipeline.svg)
18
 
 
23
  [Download checkpoint (1.04 GB)](https://huggingface.co/MichaelGlo/XGLASS/resolve/main/xglass.ckpt?download=true)
24
  · [GitHub: code and documentation](https://github.com/michaelgloeckler/XGLASS)
25
 
26
+ ## Quick start: inference notebook
27
 
28
+ Use Python 3.11 and install the code and checkpoint:
 
 
 
29
 
30
  ```bash
31
  git clone https://github.com/michaelgloeckler/XGLASS.git
32
  cd XGLASS
33
  pip install -r requirements.txt huggingface_hub
34
+ hf download MichaelGlo/XGLASS xglass.ckpt --local-dir checkpoints/vit_base_patch16_224.augreg_in21k_aip_wide_alpha0.75
 
35
  ```
36
 
37
+ 1. Prepare CT projections and the accompanying dataset files following the
38
+ [data preparation guide](https://github.com/michaelgloeckler/XGLASS/blob/main/data/README.md).
39
+ 2. Open [demo/infer_demo.ipynb](https://github.com/michaelgloeckler/XGLASS/blob/main/demo/infer_demo.ipynb)
40
+ in Jupyter or VS Code. Set `PROJ_ROOT`, `HEATMAP_DIR`, and `SPLITS_JSON` to
41
+ your prepared data and matching split file; the download folder above matches
42
+ the notebook's checkpoint directory.
43
+ 3. Run the cells to select a CT–finding example, predict slice relevance, and
44
+ visualize the results. Keep `projection_type="aip_wide"` and `blend_alpha=0.75`.
45
+
46
+ The notebook uses prepared CT projections and metadata, rather than loading an
47
+ arbitrary raw CT directly. Predictions refer to the normalized 240-slice CT block.