Skip to main content

Brain imaging surface mesh file format converter

Project description

mni2mz3

crates.io MIT License test codecov

Converts a file from MNI polygonal surface mesh format (.obj*) or vertex-wise data (e.g. curvature, cortical thickness, *.txt) to Surf-Ice MZ3 (.mz3). Useful for visualizing surfaces using Surf-Ice or NiiVue.

[!WARNING] *Not to be confused with Wavefront .obj, which is a different spec but with the same file extension.

Installation

There are many ways to install and use mni2mz3. Linux, Mac, and Windows are supported.

Using ChRIS

The easiest way to run mni2mz3 is on ChRIS, no installation needed. Simply upload your data to a feed in https://app.chrisproject.org, then run pl-mni2common.

Using Apptainer

pl-mni2common is a ChRIS plugin wrapper for mni2mz3, which means you can use its container image to run mni2mz3.

apptainer run docker://ghcr.io/fnndsc/pl-mni2common:latest mni2mz3 input.obj output.mz3

Call the wrapper script mni2mz3 instead to do bulk processing on an input directory.

apptainer run docker://ghcr.io/fnndsc/pl-mni2common:latest mni2mz3 inputdir/ outputdir/

Using cargo-binstall

cargo binstall mni2mz3

Using pip

pip install mni2mz3

Manual Download

Select and download the right binary for your architecture and OS from GitHub Releases: https://github.com/FNNDSC/mni2mz3/releases/latest

Compile From Source

Install Rust, then run

cargo install mni2mz3

Usage

# convert mesh
mni2mz3 surface_81920.obj surface.mz3

# convert data
mni2mz3 thickness.txt thickness.mz3

To do bulk conversions, use the ChRIS plugin wrapper.

Details

  • Output file will be gzip compressed.
  • For surfaces, only triangle meshes are supported.
  • For data, only 32-bit single-precision "float" is supported.

Testing

It is recommended to install cargo-nextest.

cargo nextest run

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

mni2mz3-1.0.0.tar.gz (16.4 kB view details)

Uploaded Source

Built Distributions

mni2mz3-1.0.0-py3-none-win_amd64.whl (155.8 kB view details)

Uploaded Python 3 Windows x86-64

mni2mz3-1.0.0-py3-none-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (240.6 kB view details)

Uploaded Python 3 manylinux: glibc 2.17+ x86-64

mni2mz3-1.0.0-py3-none-manylinux_2_17_armv7l.manylinux2014_armv7l.whl (233.7 kB view details)

Uploaded Python 3 manylinux: glibc 2.17+ ARMv7l

mni2mz3-1.0.0-py3-none-manylinux_2_17_aarch64.manylinux2014_aarch64.whl (232.5 kB view details)

Uploaded Python 3 manylinux: glibc 2.17+ ARM64

mni2mz3-1.0.0-py3-none-macosx_11_0_arm64.whl (210.5 kB view details)

Uploaded Python 3 macOS 11.0+ ARM64

mni2mz3-1.0.0-py3-none-macosx_10_7_x86_64.whl (222.5 kB view details)

Uploaded Python 3 macOS 10.7+ x86-64

File details

Details for the file mni2mz3-1.0.0.tar.gz.

File metadata

  • Download URL: mni2mz3-1.0.0.tar.gz
  • Upload date:
  • Size: 16.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: maturin/1.3.2

File hashes

Hashes for mni2mz3-1.0.0.tar.gz
Algorithm Hash digest
SHA256 c279a57f54b8b99c1909ca8067682f40da03a60a0dbea13843af17ac4f0c317c
MD5 b7a753b2f62f42fd60dad30b3d42207d
BLAKE2b-256 2fefe9725c9fc98cf184e368d51f3aab5a9327c9b86fb0a333cec6dc33caefb2

See more details on using hashes here.

File details

Details for the file mni2mz3-1.0.0-py3-none-win_amd64.whl.

File metadata

  • Download URL: mni2mz3-1.0.0-py3-none-win_amd64.whl
  • Upload date:
  • Size: 155.8 kB
  • Tags: Python 3, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: maturin/1.3.2

File hashes

Hashes for mni2mz3-1.0.0-py3-none-win_amd64.whl
Algorithm Hash digest
SHA256 008d5ca79e27ff0f5951021cd7cab603fc0a139da86d67e252c350bc385ff08b
MD5 c086cc9feae5b8b14d59b9fd510ef9f7
BLAKE2b-256 ce5f5d113aeff76b1e3b0e1593c8fde3c5cac624aee582eec0d744d216c9d183

See more details on using hashes here.

File details

Details for the file mni2mz3-1.0.0-py3-none-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for mni2mz3-1.0.0-py3-none-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 9c211ec7c8dbceb95c8416475885eb62e7786326e36e41a34213cdd2070b73fa
MD5 3ccb4358d868fbea703cb89409e334f6
BLAKE2b-256 e37bbabdb14b0e37191ab347b72b24adebffc5d5d6a82df3edd9100c4aa44e4d

See more details on using hashes here.

File details

Details for the file mni2mz3-1.0.0-py3-none-manylinux_2_17_armv7l.manylinux2014_armv7l.whl.

File metadata

File hashes

Hashes for mni2mz3-1.0.0-py3-none-manylinux_2_17_armv7l.manylinux2014_armv7l.whl
Algorithm Hash digest
SHA256 882ada27c95c4238c503a581b5005d901b7a6f739858e0fa909dfba4100387c7
MD5 1a2fc5c6ea15550d6e88eb40238b43d9
BLAKE2b-256 500b80438875b18205beb4094d2ed2d6c1fed71c9ff1ccb730582d8a0b0e414d

See more details on using hashes here.

File details

Details for the file mni2mz3-1.0.0-py3-none-manylinux_2_17_aarch64.manylinux2014_aarch64.whl.

File metadata

File hashes

Hashes for mni2mz3-1.0.0-py3-none-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
Algorithm Hash digest
SHA256 086e1e6552e7352b715d9e8c3dccb066968aedefe1314bbc070ad9fca430e842
MD5 86509c455e96f39608059c32740078ca
BLAKE2b-256 6088fed7235d87ba6ea18a8dc2c293ab9155fc2aa0de67254cbd1a64e8dad266

See more details on using hashes here.

File details

Details for the file mni2mz3-1.0.0-py3-none-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for mni2mz3-1.0.0-py3-none-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 c314cd3339fcbb291a2e11e82658fa6728c1adf6021ef0245480c0bb27075ab2
MD5 5bdbec8b95135c90ed84ed09cf26e46b
BLAKE2b-256 e9ce49570b467ecfe84c1f0b5bbb5e954d4065e1461c363d58488877f15b274b

See more details on using hashes here.

File details

Details for the file mni2mz3-1.0.0-py3-none-macosx_10_7_x86_64.whl.

File metadata

File hashes

Hashes for mni2mz3-1.0.0-py3-none-macosx_10_7_x86_64.whl
Algorithm Hash digest
SHA256 c03c2c4f9b01210514b6b015a0b273e007faa21cbbe72572b9061222cf139728
MD5 1a30cfee0d89abd6f04f874190914059
BLAKE2b-256 d0ccd2b14ae01ffca351c8177fca049bc03e564a3fe68282d00f57322cec6bf2

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page