Skip to content

Commit

Permalink
Update README.md
Browse files Browse the repository at this point in the history
  • Loading branch information
andreped authored Sep 10, 2021
1 parent 40c3fd9 commit 71f6d27
Showing 1 changed file with 12 additions and 23 deletions.
35 changes: 12 additions & 23 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,35 +7,21 @@

The figure shows a predicted liver mask with the corresponding patient CT in 3DSlicer. It is the Volume-10 from the LITS17 dataset.

### Credit
The LITS dataset can be accessible from [here](https://competitions.codalab.org), and the corresponding paper for the challenge from [here](https://arxiv.org/abs/1901.04056). If trained model is used, please consider citing this paper.

### Usage:
## Install

1) Clone repo:
```
git clone https://github.com/andreped/livermask.git
cd livermask
```
2) Create virtual environment and intall dependencies:
```
virtualenv -ppython3 venv
source venv/bin/activate
pip install -r /path/to/requirements.txt
```
3) Run livermask method:
```
cd livermask
python livermask.py "path_to_ct_nifti.nii" "output_name.nii"
pip install git+https://github.com/andreped/livermask.git
```

If you lack any modules after, try installing them through setup.py (could be done instead of using requirements.txt):
## Usage:

```
pip install wheel
python setup.py bdist_wheel
livermask --input path-to-nifti.nii --output path-to-output-file.nii
```

### DICOM/NIfTI format
In addition, there is the optional `--cpu` action to disable the GPU (force computations on CPU only) if necessary.

## DICOM/NIfTI format
Pipeline assumes input is in the NIfTI format, and output a binary volume in the same format (.nii).
DICOM can be converted to NIfTI using the CLI [dcm2niix](https://github.com/rordenlab/dcm2niix), as such:
```
Expand All @@ -44,9 +30,12 @@ dcm2niix -s y -m y -d 1 "path_to_CT_folder" "output_name"

Note that "-d 1" assumed that "path_to_CT_folder" is the folder just before the set of DICOM scans you want to import and convert. This can be removed if you want to convert multiple ones at the same time. It is possible to set "." for "output_name", which in theory should output a file with the same name as the DICOM folder, but that doesn't seem to happen...

### Troubleshooting
## Troubleshooting
You might have issues downloading the model when using VPN. If any issues are observed, try to disable VPN and try again.

## Acknowledgements
The LITS dataset can be accessible from [here](https://competitions.codalab.org), and the corresponding paper for the challenge from [here](https://arxiv.org/abs/1901.04056). If trained model is used, please consider citing this paper.

------

Made with :heart: and python

0 comments on commit 71f6d27

Please sign in to comment.