Skip to main content

pyapetnet

A convolutional neurol network (CNN) to mimick the behavior of anatomy-guided PET reconstruction in image space.

architecture of pyapetnet

Authors

Georg Schramm, David Rigie

License

This project is licensed under the MIT License - see the LICENSE file for details.

Scientific Publication

Details about pyapetnet are published in Schramm et al., "Approximating anatomically-guided PET reconstruction in image space using a convolutional neural network" ,NeuroImage Vol 224 2021. If we you are using pyapetnet in scientific publications, we appreciate citation of this article.

Installation

We recommend to install pyapetnet from conda-forge via

conda -c conda-forge install pyapetnet

Alternatively, pyapetnet can be also installed from pypi via

pip install pyapetnet

Testing the installation

To test the installation activate your virtual environment and run

import pyapetnet
print(pyapetnet.__file__)

If the installation was successful, a number of command line scripts all starting with pyapetnet* to e.g. do predictions with the included trained models from nifti and dicom input images will be available.

Getting started - running your first prediction with pre-trained models

To run a prediction using one of included pre-trained networks and nifti images, run e.g.:

pyapetnet_predict_from_nifti osem.nii t1.nii S2_osem_b10_fdg_pe2i --show

Use the following to get information on the (optional) input arguments

pyapetnet_predict_from_nifti -h

To get a list of available pre-trained models run

pyapetnet_list_models

To make predictions from dicom images, use

pyapetnet_predict_from_dicom osem_dcm_dir t1_dcm_dir S2_osem_b10_fdg_pe2i --show

The source code of the prediction scripts can be found in the scripts subfolder here.

Training your own model

If you want to train your own model (from scratch or using transfer learning) using your own data, have a look at our training script. All input parameters (e.g. data sets to use) have to be specified in a config json file (example here). The input data sets have to be in nifti format and should be aligned already.

Release files for pyapetnet 1.5.6

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for pyapetnet 1.5.6
File Size Uploaded
pyapetnet-1.5.6.tar.gz 11.6 MB Details

Built distribution (wheel)

Table of built distributions (wheels) for pyapetnet 1.5.6
File Interpreter ABI Platform
pyapetnet-1.5.6-py3-none-any.whl Python 3 none any Details

Total release size: 23.2 MB

Release files / pyapetnet-1.5.6.tar.gz

Download URL pyapetnet-1.5.6.tar.gz
Size 11.6 MB
Tags Source
SHA-256 checksum
How to use checksums
ac2bc1cc22b47bf451c7b454f921691952d498bd89d13b6a2d816ce49e204ae9
BLAKE2b-256 checksum
How to use checksums
a744be85e8a1cee7abe1c59d2cda5b38fb4a7bbc92f65860a621459ec7d5182c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.0.1 CPython/3.12.8

Release files / pyapetnet-1.5.6-py3-none-any.whl

Download URL pyapetnet-1.5.6-py3-none-any.whl
Size 11.6 MB
Tags Python 3
SHA-256 checksum
How to use checksums
e89b9327bf56e8901d61c81102618a9e7042a0099db3b8d026e178e06240ef5e
BLAKE2b-256 checksum
How to use checksums
54461ca90de8bbc3d2f5477fb40c80e566ae69e425b29ef8647a0d3b1469a809
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.0.1 CPython/3.12.8

Release history Release notifications | RSS feed

This release

1.5.6 This release

2 release files

1.5.5

2 release files

1.5.4

2 release files

1.5.3

2 release files

1.5.1

2 release files

1.5

2 release files

1.4.1

2 release files

1.3.2

2 release files

1.3.1

2 release files

1.3

2 release files

1.2

2 release files

1.1.1

2 release files

1.1.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page