Instructions

1-Data preparation

This is how inputs_data organizes

    $inputs_data/
    β”œβ”€β”€ casename00001
    β”‚   └── ct.nii.gz
    β”œβ”€β”€ casename00002
    β”‚   └── ct.nii.gz
    β”œβ”€β”€ casename00003
    β”‚   └── ct.nii.gz
    ...

2-Download

You can choose to use the docker image (recommand) or the singularity container.

Download the docker image.

docker pull qchen99/suprem:v1

or

Download the singularity container.

wget https://huggingface.co/qicq1c/SuPreM/resolve/main/suprem_final.sif

3-Inference

You can directly perform inference on your own data. Simply modify inputs_data into your data path and adjust outputs_data to specify the desired output location for the segmentation results.

Use Docker

sudo docker container run --gpus "device=0" -m 128G --rm -v $inputs_data:/workspace/inputs/ -v $outputs_data:/workspace/outputs/ qchen99/suprem:v1 /bin/bash -c "sh predict.sh"

or

Use Singularity

SINGULARITYENV_CUDA_VISIBLE_DEVICES=0 singularity run --nv -B $inputs_data:/workspace/inputs -B $outputs_data:/workspace/outputs suprem_final.sif

This is how outputs_data organizes

    $outputs_data/
    β”œβ”€β”€ casename00001
    β”œβ”€β”€ casename00002
    β”œβ”€β”€ casename00003
        │── combined_labels.nii.gz
        └── segmentations
            β”œβ”€β”€ aorta.nii.gz
            β”œβ”€β”€ gall_bladder.nii.gz
            β”œβ”€β”€ kidney_left.nii.gz
            β”œβ”€β”€ kidney_right.nii.gz
            β”œβ”€β”€ liver.nii.gz
            β”œβ”€β”€ pancreas.nii.gz
            β”œβ”€β”€ postcava.nii.gz
            β”œβ”€β”€ spleen.nii.gz
            β”œβ”€β”€ stomach.nii.gz
    β”‚
    ...
Downloads last month

-

Downloads are not tracked for this model. How to track
Inference Providers NEW
This model is not currently available via any of the supported Inference Providers.
The model cannot be deployed to the HF Inference API: The model has no library tag.