Added demo section to README
Browse files- README.md +7 -0
- demo/src/utils.py +1 -0
README.md
CHANGED
|
@@ -74,6 +74,13 @@ where:
|
|
| 74 |
|
| 75 |
Use ```ddmr --help``` to see additional options like using precomputed segmentations to crop the images to the desired ROI, or debugging.
|
| 76 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 77 |
## 🏋️♂️ Training
|
| 78 |
|
| 79 |
Use the "MultiTrain" scripts to launch the trainings, providing the neccesary parameters. Those in the COMET folder accepts a .ini configuration file (see COMET/train_config_files for example configurations).
|
|
|
|
| 74 |
|
| 75 |
Use ```ddmr --help``` to see additional options like using precomputed segmentations to crop the images to the desired ROI, or debugging.
|
| 76 |
|
| 77 |
+
## 🤗 Demo <a target="_blank" href="https://huggingface.co/spaces/andreped/DDMR"><img src="https://img.shields.io/badge/🤗%20Hugging%20Face-Spaces-yellow.svg"></a>
|
| 78 |
+
|
| 79 |
+
A live demo to easily test the best performing pretrained models was developed in Gradio and is deployed on `Hugging Face`.
|
| 80 |
+
|
| 81 |
+
To access the live demo, click on the `Hugging Face` badge above. Below is a snapshot of the current state of the demo app.
|
| 82 |
+
|
| 83 |
+
|
| 84 |
## 🏋️♂️ Training
|
| 85 |
|
| 86 |
Use the "MultiTrain" scripts to launch the trainings, providing the neccesary parameters. Those in the COMET folder accepts a .ini configuration file (see COMET/train_config_files for example configurations).
|
demo/src/utils.py
CHANGED
|
@@ -9,6 +9,7 @@ def load_ct_to_numpy(data_path):
|
|
| 9 |
data_path = data_path.name
|
| 10 |
|
| 11 |
image = nib.load(data_path)
|
|
|
|
| 12 |
resampled = resample_to_output(image, None, order=0)
|
| 13 |
data = resampled.get_fdata()
|
| 14 |
|
|
|
|
| 9 |
data_path = data_path.name
|
| 10 |
|
| 11 |
image = nib.load(data_path)
|
| 12 |
+
print("original nibabel image shape:", image.shape)
|
| 13 |
resampled = resample_to_output(image, None, order=0)
|
| 14 |
data = resampled.get_fdata()
|
| 15 |
|