Skip to main content

normaltwinpet

Generate a whole-body normal twin PET from a CT image, using the CT-only model from:

Hinge et al., Normal twin PET: personalized generative modeling for confounder correction and anomaly detection in whole-body PET/CT, Scientific Reports 15, 42662 (2025). https://doi.org/10.1038/s41598-025-26827-y

Input is a CT, output is the normal twin PET, on the same voxel grid as the CT.

The output is normalized as image-derived lean-body-mass SUV (see ID-uptake-values).

Usage

pip install normaltwinpet
normaltwinpet -i ct.nii.gz -o ntpet.nii.gz

Uses CUDA if available, otherwise CPU (slow). Override with --device.

On first run the weights (~250 MB) are downloaded from the GitHub release and cached in the user cache directory (~/.cache/normaltwinpet on Linux). Set NORMALTWINPET_HOME to use another location.

Notes

The CT is resampled to 2 mm and cropped/padded to 256x256 in-plane for the network, then resampled back to the input grid. Anatomy outside the central 256x256 (512 mm) in-plane field of view is not predicted and will be zero.

Metadata

Release files for normaltwinpet 0.3.1

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

Source distribution (sdist)

Source distribution for normaltwinpet 0.3.1
File Size Uploaded Provenance Actions
normaltwinpet-0.3.1.tar.gz 7.0 kB Without provenance Details for normaltwinpet-0.3.1.tar.gz

Built distribution (wheel)

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

Total release size: 16.6 kB

Release files / normaltwinpet-0.3.1.tar.gz

Download URL normaltwinpet-0.3.1.tar.gz
Size 7.0 kB
Tags Source
SHA-256 checksum
How to use checksums
209b48eaed226b47a995df319d39000d3cb6b025f0aea28e80367c0ef17c07e1
BLAKE2b-256 checksum
How to use checksums
47c24f93ce72b1180aafbdf16368f53cbb2ef1638b319dcdf57e875dc6fe5400
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via uv/0.13.6 {"installer":{"name":"uv","version":"0.13.6","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Release files / normaltwinpet-0.3.1-py3-none-any.whl

Download URL normaltwinpet-0.3.1-py3-none-any.whl
Size 9.6 kB
Tags Python 3
SHA-256 checksum
How to use checksums
1ca14e5fd68ee02ec3e301ce9fde2d35d2aafdba1127962176addcb4ed6fb4ef
BLAKE2b-256 checksum
How to use checksums
1a1d589680ec6f2e007c234ba5f803abcabb25b9820c5f210b163f75516e92e1
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via uv/0.13.6 {"installer":{"name":"uv","version":"0.13.6","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Security for normaltwinpet 0.3.1

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

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