Skip to main content

mrid

mrid is a library for preprocessing of 3D images, particularly medical images.

It provide interfaces for many medical image processing tools such as SimpleElastix, HD-BET, SynthStrip, CTSeg. Note that those libraries are not bundled, installation instructions are included in all examples below.

Installation

Either run

pip install mrid-python

or

pip install git+https://github.com/inikishev/mrid

Registering images with SimpleITK-SimpleElastix

SimpleElastix is a robust tool for image registration which works really well out-of-the-box. It works on both Windows and Linux.

See this notebook for how to install and use it. image

Skullstripping MRI scans with HD-BET

HD-BET is a model that performs skullstripping of pre- and post-constrast T1, T2 and FALIR MRIs. It works on both Windows and Linux.

See this notebook for how to install and use it image

Skullstripping with SynthStrip

SynthStrip is a skull-stripping tool that works with many different image types and modalities, including MRI, DWI, CT, PET, etc.

See this notebook for how to install and use it image

Skullstripping and segmentation of CT images with CTseg

CTseg can skull-strip CT images and perform their segmentation, it also registers them to a common space (see its README). Note that it can be very slow for 512x512 series (can take few hours), but you can downsample to 256x256. If you only need to quickly skullstrip CT scans without warping them you can use SynthStrip.

TODO!!!

Example workflow - preprocessing MRIs to BraTS format

Many BraTS datasets are provided as skullstripped images in SRI24 space. See this notebook for how to process raw scans to this format.

image

(T1n image looks weird because that's just how it is in the zenodo dataset)

References

The MRIs for all images above are from https://zenodo.org/records/7213153.

Colin Vanden Bulcke. (2022). Open-Access DICOM MRI session (1.0) [Data set]. Zenodo. https://doi.org/10.5281/zenodo.7213153

Metadata

Release files for mrid-python 0.1.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 mrid-python 0.1.6
File Size Uploaded Provenance Actions
mrid_python-0.1.6.tar.gz 41.8 kB With provenance Details for mrid_python-0.1.6.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for mrid-python 0.1.6
File Interpreter ABI Platform Actions
mrid_python-0.1.6-py3-none-any.whl Python 3 none any Details for mrid_python-0.1.6-py3-none-any.whl

Total release size: 92.7 kB

Release files / mrid_python-0.1.6.tar.gz

Download URL mrid_python-0.1.6.tar.gz
Size 41.8 kB
Tags Source
SHA-256 checksum
How to use checksums
1d1c0c9343fe77fb0cf3d7adba4b3ab920b8ef1fb88b0d1e0a26520c89d45bf9
BLAKE2b-256 checksum
How to use checksums
1eb4ef3fcc7dd600f7bb6922302d257224332b5c59240fe54b760742dfbb885d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

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.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 9, 2026.

Transparency log

Release files / mrid_python-0.1.6-py3-none-any.whl

Download URL mrid_python-0.1.6-py3-none-any.whl
Size 50.9 kB
Tags Python 3
SHA-256 checksum
How to use checksums
c5c13942ccf7fd5b737c35834f14a7b487828434981bef4700f347abf074d572
BLAKE2b-256 checksum
How to use checksums
bdb9eeb620a70f0c0ae3f948a9b5ebda3d20f14b586b2240cc295644eb46411b
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

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.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 9, 2026.

Transparency log

Security for mrid-python 0.1.6

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.

Full provenance

Both files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for mrid_python-0.1.6.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 9, 2026.

Transparency log

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