Skip to main content

Thickness calculation on binary 3D images

Project description

Compute the thickness of a solid using Yezzi and Prince method described in the article “An Eulerian PDE Approach for Computing Tissue Thickness”, IEEE TRANSACTIONS ON MEDICAL IMAGING, VOL. 22, NO. 10, OCTOBER 2003. [1]

A C implementation by Rubén Cárdenes [2] helped me a lot writing this, especially the anisotropic part.

Requirements

numpy, cython, scikit-image. Tested with Debian Jessie and Fedora 27, miniconda-python 3.6, cython 0.24, numpy 1.11.2, scikit image 0.12.3

Installation instruction

Available on pypi. [3] Use pip: pip install pyezzi

Alternatively, clone the repository and build cython modules with python setup.py build_ext --inplace.

Usage

from pyezzi.thickness import compute_thickness
thickness = compute_thickness(labeled_image, debug=True)

labeled_image is a 3 dimensional numpy array where the wall is labeled 2 and the interior is labeled 1.

A spacing parameter specifying the spacing between voxels along the axes can optionnaly be specified.

Check out the included jupyter notebooks in the example folder for more details.

Contributions

Feel free to submit pull requests. I know the code is nowhere near optimal as it is.

License

This work is licensed under the french CeCILL license. [4] You’re free to use and modify the code, but please cite the original paper and me.

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

pyezzi-0.3.1.tar.gz (291.3 kB view details)

Uploaded Source

File details

Details for the file pyezzi-0.3.1.tar.gz.

File metadata

  • Download URL: pyezzi-0.3.1.tar.gz
  • Upload date:
  • Size: 291.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for pyezzi-0.3.1.tar.gz
Algorithm Hash digest
SHA256 4541d7642832d8649f75cf8281fc90fa1074fa9706045fb1122d542ea92fb0b1
MD5 1b360c47974340d3ce618315e0b82c37
BLAKE2b-256 9744a5b32b620dc11b423ea9783496cc6382e4c9ba9b91cae0eb80c803c8f8ae

See more details on using hashes here.

Supported by

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