Support for reading and writing images in MetaIO file format.
Project description
MetaImageIO
Support for reading and writing images in MetaIO file format.
Getting started in Python
Install using pip install metaimageio or conda install -c conda-forge metaimageio.
import metaimageio as mio
image, meta = mio.read('/path/to/input.mha')
mio.write('/path/to/output.mha', image, ElementSpacing=meta['ElementSpacing'])
(Highly optional) Add to imageio plugins.
import imageio.v2 as iio
mio.imageio.add_format()
image = iio.imread('/path/to/input.mha', format='MetaImageIO')
meta = image.meta
import imageio.v3 as iio
from metaimageio.imageio import MetaImageIOPlugin
image = iio.imread('/path/to/input.mha', plugin=MetaImageIOPlugin)
meta = iio.immeta('/path/to/input.mha', plugin=MetaImageIOPlugin)
Getting started in MATLAB
Install using the Add-On Manager.
[image, meta] = metaimageio.read('/path/to/input.mha');
metaimageio.write('/path/to/output.mha', image, 'ElementSpacing', meta.ElementSpacing);
(Optional) Add to image file format registry.
metaimageio.imformats();
image = imread('/path/to/input.mha');
meta = imfinfo('/path/to/input.mha');
Releasing a new version
- Update
project.versioninpyproject.tomlandCHANGELOGwith commit message "Release vX.X.X". - Add tag vX.X.X with message "Release vX.X.X".
- Push the tag and create a new release on metaimageio.
- Merge the auto-generated pull request on metaimageio-feedstock.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file metaimageio-1.3.2.tar.gz.
File metadata
- Download URL: metaimageio-1.3.2.tar.gz
- Upload date:
- Size: 10.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.11.13
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
fddd289c1c18326b3fabf678688c973f12fde4134fd9efcda28b167e68a4c342
|
|
| MD5 |
a88694cbd7b2d64de00e70ee29755e60
|
|
| BLAKE2b-256 |
9abaf1c88ee5973127104189451bf1535f3370e63cea327219b94c65c2605507
|
File details
Details for the file metaimageio-1.3.2-py3-none-any.whl.
File metadata
- Download URL: metaimageio-1.3.2-py3-none-any.whl
- Upload date:
- Size: 12.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.11.13
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
7dba2c3d35538f0891d397a766bd816f0658d161ee9b096cd0bd83aab88a6d56
|
|
| MD5 |
0a04ad9fa6aa262ddc12a95ebf284818
|
|
| BLAKE2b-256 |
891d7b1e462f1d92722e5bd20d963eba5af5aaeee3b4eefc0c7f008b2b2c9f91
|