Metadata-Version: 2.4
Name: miblab-dl
Version: 0.0.10
Summary: Python API for miblab's trained deep-learning models
Author-email: Steven Sourbron <s.sourbron@sheffield.ac.uk>, Joao Periquito <j.s.periquito@sheffield.ac.uk>
License-Expression: Apache-2.0
Project-URL: Homepage, https://miblab.org/
Project-URL: Source Code, https://github.com/openmiblab/docs-miblab-dl
Keywords: python,medical imaging,MRI,deep learning
Classifier: Development Status :: 3 - Alpha
Classifier: Intended Audience :: Developers
Classifier: Intended Audience :: Science/Research
Classifier: Topic :: Scientific/Engineering
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python
Classifier: Programming Language :: Python :: 3
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: platformdirs
Requires-Dist: numpy
Requires-Dist: nibabel
Requires-Dist: miblab-data
Requires-Dist: nnunetv2
Requires-Dist: vreg
Requires-Dist: TotalSegmentator
Requires-Dist: torch
Requires-Dist: monai==1.3.2
Requires-Dist: scipy
Requires-Dist: tqdm
Dynamic: license-file

# miblab-dl

Python API for miblab's trained deep-learning models

## Installation in a working environment

If you are working in an existing environment with pytorch already installed, 
then all you need is this:

```bash
pip install miblab-dl
```

## Installation from scratch

If you start from scratch, first create a virtual environment, activate it 
and make sure you have the latest pip version. 

On Windows:

```bash
python -m venv myenv
myenv/Scripts/activate
python -m pip install --upgrade pip
```

On Mac or Linux:

```bash
python -m venv myenv
source myenv/bin/activate
python -m pip install --upgrade pip
```

Now install pytorch in your environment:

```bash
pip install torch torchvision torchaudio --index-url https://download.pytorch.org/whl/cu118
```

Then install the `miblab-dl` package:

```bash
pip install miblab-dl
```

## Usage

You can import `miblab-dl` functionality in a python script like this:

```python
import miblab_dl as dl
```

Then to compute fat and water maps from numpy arrays representing 
`in_phase` and `opposed_phase` Dixon images:

```python
fat, water = dl.fatwater(opposed_phase, in_phase)
```
