Skip to main content

No project description provided

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

Runtime: numpy, OpenMP (e.g., the libgomp1 package on debian).

Build time: a C compiler (e.g., gcc + libc6-dev packages on debian). This is needed in case you are using a platform for which we do not provide binaries (“wheels”) on PyPI.

Test time: scikit-image, scipy.

Installation instruction

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

Alternatively, clone the repository and build cython modules with pip install ..

Usage

Command line

This package provides a basic CLI. Example usage:

pyezzi /path/to/endo.mha /path/to/epi.mha /path/to/output.mha [--weights /path/to/thickness_weights.mha]

If can use the excellent uvx, you can download and launch it in a single command:

uvx pyezzi[cli] --help

Python API

Full API documentation is available on gitlabpages.inria.fr.

from pyezzi import compute_thickness_cardiac

thickness = compute_thickness_cardiac(endo, epi)

endo and epi are numpy binary masks. endo represents the “inside” boundary of the domain, e.g., the cardiac ventricular blood pool. epi represents the “outside” boundary of the domain, e.g., the cardiac ventricular epicardium.

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

A weights parameter can be added to account for “holes” in the wall, cf “Cedilnik & Peyrat, Weighted tissue thickness, FIMH 2023”. [4]

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

Contributions

We recommend using uv for project management and pre-commit to ensure code quality.

After cloning, use uv sync --frozen --all-groups --all-extras to install dev dependencies. This will set up a virtualenv in .venv that you can activate with source .venv/bin/activate. Tests can then be run with pytest test.

To build the cython extension modules in place, use python setup.py develop.

License

This work is licensed under the french CeCILL license. [5] 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.8.2.post2.tar.gz (9.2 MB view details)

Uploaded Source

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

pyezzi-0.8.2.post2-cp313-cp313-win_amd64.whl (1.1 MB view details)

Uploaded CPython 3.13Windows x86-64

pyezzi-0.8.2.post2-cp313-cp313-manylinux_2_38_x86_64.whl (3.2 MB view details)

Uploaded CPython 3.13manylinux: glibc 2.38+ x86-64

pyezzi-0.8.2.post2-cp313-cp313-macosx_10_15_x86_64.whl (1.2 MB view details)

Uploaded CPython 3.13macOS 10.15+ x86-64

pyezzi-0.8.2.post2-cp312-cp312-win_amd64.whl (1.1 MB view details)

Uploaded CPython 3.12Windows x86-64

pyezzi-0.8.2.post2-cp312-cp312-manylinux_2_38_x86_64.whl (3.2 MB view details)

Uploaded CPython 3.12manylinux: glibc 2.38+ x86-64

pyezzi-0.8.2.post2-cp312-cp312-macosx_10_15_x86_64.whl (1.2 MB view details)

Uploaded CPython 3.12macOS 10.15+ x86-64

pyezzi-0.8.2.post2-cp311-cp311-win_amd64.whl (1.1 MB view details)

Uploaded CPython 3.11Windows x86-64

pyezzi-0.8.2.post2-cp311-cp311-manylinux_2_38_x86_64.whl (3.2 MB view details)

Uploaded CPython 3.11manylinux: glibc 2.38+ x86-64

pyezzi-0.8.2.post2-cp311-cp311-macosx_10_15_x86_64.whl (1.2 MB view details)

Uploaded CPython 3.11macOS 10.15+ x86-64

pyezzi-0.8.2.post2-cp310-cp310-win_amd64.whl (1.1 MB view details)

Uploaded CPython 3.10Windows x86-64

pyezzi-0.8.2.post2-cp310-cp310-manylinux_2_38_x86_64.whl (3.1 MB view details)

Uploaded CPython 3.10manylinux: glibc 2.38+ x86-64

pyezzi-0.8.2.post2-cp310-cp310-macosx_10_15_x86_64.whl (1.2 MB view details)

Uploaded CPython 3.10macOS 10.15+ x86-64

File details

Details for the file pyezzi-0.8.2.post2.tar.gz.

File metadata

  • Download URL: pyezzi-0.8.2.post2.tar.gz
  • Upload date:
  • Size: 9.2 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.7.11

File hashes

Hashes for pyezzi-0.8.2.post2.tar.gz
Algorithm Hash digest
SHA256 33127a2b66db422ccb2619a898dd0658c9f48fd9636e87ad237d866caf546a38
MD5 4c96e99cc93a9dc6bef606e8b60f1a3e
BLAKE2b-256 faf9ce92148a44a26ba6ba1ef193631463eb776d9072d4a8f6f911becfabec36

See more details on using hashes here.

File details

Details for the file pyezzi-0.8.2.post2-cp313-cp313-win_amd64.whl.

File metadata

File hashes

Hashes for pyezzi-0.8.2.post2-cp313-cp313-win_amd64.whl
Algorithm Hash digest
SHA256 c564310550bb1cdf26663ebb25a9e9c60117fe0794c1a2f1e48a5d42565ead1c
MD5 7f0d9c521dac4df8b470c28fade1d92e
BLAKE2b-256 6384b8dc84fa15d658e9000151de7cc536cc7d4168a1147725c223041854b6af

See more details on using hashes here.

File details

Details for the file pyezzi-0.8.2.post2-cp313-cp313-manylinux_2_38_x86_64.whl.

File metadata

File hashes

Hashes for pyezzi-0.8.2.post2-cp313-cp313-manylinux_2_38_x86_64.whl
Algorithm Hash digest
SHA256 67476712c4493355492976c441dd2e5208c405001fe0ba9742c47bdba7c61126
MD5 be4536e297e168307e0c7619e6513ff6
BLAKE2b-256 7f6e8db683e025603316ec32dc5ab9075ee195a88d323bb6f7164894bc0b3fd7

See more details on using hashes here.

File details

Details for the file pyezzi-0.8.2.post2-cp313-cp313-macosx_10_15_x86_64.whl.

File metadata

File hashes

Hashes for pyezzi-0.8.2.post2-cp313-cp313-macosx_10_15_x86_64.whl
Algorithm Hash digest
SHA256 b28f56320baf7ae494be323944f6604cc4e347b3a166c87996ec2f475c18d9e6
MD5 c874e0466c47fbe744c76c5e4660b938
BLAKE2b-256 24487d1496af754680411ef36151375943c57bac10265c99f218af7d8849fb4e

See more details on using hashes here.

File details

Details for the file pyezzi-0.8.2.post2-cp312-cp312-win_amd64.whl.

File metadata

File hashes

Hashes for pyezzi-0.8.2.post2-cp312-cp312-win_amd64.whl
Algorithm Hash digest
SHA256 7a6440bd61141286ab97aa7f1efe30723a948be88fc3473b8600e08fec768347
MD5 ef4fa298da303451d25799c6c20eb5a8
BLAKE2b-256 57b2e0e8351925d3a6a6e94107ae95e5dbfe5544270f022456479f86430c9d34

See more details on using hashes here.

File details

Details for the file pyezzi-0.8.2.post2-cp312-cp312-manylinux_2_38_x86_64.whl.

File metadata

File hashes

Hashes for pyezzi-0.8.2.post2-cp312-cp312-manylinux_2_38_x86_64.whl
Algorithm Hash digest
SHA256 28aa610dc6f2bd5ab75f6e7327f00a6a9b32b6dba244844895d47cab82238f79
MD5 d248f0c3d8eb639525fb5fb0157dbd12
BLAKE2b-256 0658a2ea8f0d636130b3988da3a4817472b5e2850271b293bee3f90863c30473

See more details on using hashes here.

File details

Details for the file pyezzi-0.8.2.post2-cp312-cp312-macosx_10_15_x86_64.whl.

File metadata

File hashes

Hashes for pyezzi-0.8.2.post2-cp312-cp312-macosx_10_15_x86_64.whl
Algorithm Hash digest
SHA256 3f7315e85389d6f9c2dac39a574dfc5e0aef5e13330d706ebe2d80e47f999125
MD5 f095dcd720fdf828f26823ac756b4758
BLAKE2b-256 49d88ab8f26f16c5a7b38f03f53429bb10ab84e2b533333e212267e51d8d1131

See more details on using hashes here.

File details

Details for the file pyezzi-0.8.2.post2-cp311-cp311-win_amd64.whl.

File metadata

File hashes

Hashes for pyezzi-0.8.2.post2-cp311-cp311-win_amd64.whl
Algorithm Hash digest
SHA256 5670f02b2690c95d4cb8921d415727267ba5030c990684b2c666eaf435b3f5d0
MD5 9834fedc7aacd830e2b630327608e68b
BLAKE2b-256 7486312c2cd1471c109cb2648557f04e14ece1ee5edd2ed44f278f9640eee246

See more details on using hashes here.

File details

Details for the file pyezzi-0.8.2.post2-cp311-cp311-manylinux_2_38_x86_64.whl.

File metadata

File hashes

Hashes for pyezzi-0.8.2.post2-cp311-cp311-manylinux_2_38_x86_64.whl
Algorithm Hash digest
SHA256 caf28e539ee602f9cea4f66160e8e9efc92d3efa5c72af071ace01e6ee0fce6d
MD5 1f840e8e6dabda0bcfeaf1b6e386ac4d
BLAKE2b-256 03ada5b23f42df3e4ea56ebfa06102efecc3d956ccb59eeae6b543a11177d149

See more details on using hashes here.

File details

Details for the file pyezzi-0.8.2.post2-cp311-cp311-macosx_10_15_x86_64.whl.

File metadata

File hashes

Hashes for pyezzi-0.8.2.post2-cp311-cp311-macosx_10_15_x86_64.whl
Algorithm Hash digest
SHA256 184a0344655c14e5840da2b7d898dc704720922bafde04d2c169249994bfadf8
MD5 a46982adec4b71662fc60445a822cd5d
BLAKE2b-256 3433e0f55cb6759432062ff1d75ddc55c12b3bec7ef7d1cd2cf06a94acdef350

See more details on using hashes here.

File details

Details for the file pyezzi-0.8.2.post2-cp310-cp310-win_amd64.whl.

File metadata

File hashes

Hashes for pyezzi-0.8.2.post2-cp310-cp310-win_amd64.whl
Algorithm Hash digest
SHA256 106f32593c47c40dcd4cc3fe3da3e1c77c556302818ec26cc4456d0e24abbdc1
MD5 8261bb5a995b8607d2df94d8c915996f
BLAKE2b-256 9656eff292c402a88ce8f56663d3076706a614e05b8a25e671f7b7df45a196ae

See more details on using hashes here.

File details

Details for the file pyezzi-0.8.2.post2-cp310-cp310-manylinux_2_38_x86_64.whl.

File metadata

File hashes

Hashes for pyezzi-0.8.2.post2-cp310-cp310-manylinux_2_38_x86_64.whl
Algorithm Hash digest
SHA256 8b07b827860ee1b9c9cd4530ede1641f4dc4bddd264b2d36a749bdc2c8e23016
MD5 71076d97194aa81f070475e1164477b8
BLAKE2b-256 f54ccd04d4e3a9d06d4e33e3fab6c54b985272becceb4bb7ffe2bc40f7804f32

See more details on using hashes here.

File details

Details for the file pyezzi-0.8.2.post2-cp310-cp310-macosx_10_15_x86_64.whl.

File metadata

File hashes

Hashes for pyezzi-0.8.2.post2-cp310-cp310-macosx_10_15_x86_64.whl
Algorithm Hash digest
SHA256 9e597a9e7447b571c37a72093bccfa96d8f5e6d2795316c0a51ab73ed9729da5
MD5 36fbfa2c4ab24cd633505866b8a6b41f
BLAKE2b-256 777cf9bdb0122369e73fa842492b434a632d4008d850cf43c34e6dc147d6e76d

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