All Projects → InsightSoftwareConsortium → ITKPythonPackage

InsightSoftwareConsortium / ITKPythonPackage

Licence: Apache-2.0 license
A setup script to generate ITK Python Wheels

Programming Languages

CMake
9771 projects
shell
77523 projects
python
139335 projects - #7 most used programming language
powershell
5483 projects

Projects that are alternatives of or similar to ITKPythonPackage

papeR
A toolbox for writing Sweave or other LaTeX-based papers and reports and to prettify the output of various estimated models.
Stars: ✭ 26 (-55.93%)
Mutual labels:  reproducible-research
combining3Dmorphablemodels
Project Page of Combining 3D Morphable Models: A Large scale Face-and-Head Model - [CVPR 2019]
Stars: ✭ 80 (+35.59%)
Mutual labels:  registration
ITKPOCUS
An open source library for streaming and preprocessing point-of-care ultrasound video.
Stars: ✭ 16 (-72.88%)
Mutual labels:  itk
laravel-email-domain-rule
A package to validate email domains in a user registration form
Stars: ✭ 60 (+1.69%)
Mutual labels:  registration
panoptes
Monitor computational workflows in real time
Stars: ✭ 45 (-23.73%)
Mutual labels:  reproducible-research
software-dev
Coding Standards for the USC Biostats group
Stars: ✭ 33 (-44.07%)
Mutual labels:  reproducible-research
ITKWikiExamples
Scraped, buildable version of the wiki examples
Stars: ✭ 21 (-64.41%)
Mutual labels:  itk
superpose3d
register 3D point clouds using rotation, translation, and scale transformations.
Stars: ✭ 34 (-42.37%)
Mutual labels:  registration
reproducibility-guide
⛔ ARCHIVED ⛔
Stars: ✭ 119 (+101.69%)
Mutual labels:  reproducible-research
binderhub-deploy
Deploy a BinderHub from scratch on Microsoft Azure
Stars: ✭ 27 (-54.24%)
Mutual labels:  reproducible-research
renv
Creating virtual environments for R.
Stars: ✭ 18 (-69.49%)
Mutual labels:  reproducible-research
Non-rigid-ICP
Non-rigid iterative closest point, nricp.
Stars: ✭ 66 (+11.86%)
Mutual labels:  registration
dicom2stl
Python script to extract a STL surface from a DICOM image series.
Stars: ✭ 151 (+155.93%)
Mutual labels:  itk
Kervolution
Kervolution implementation using TF2.0
Stars: ✭ 20 (-66.1%)
Mutual labels:  reproducible-research
BRAINSTools
A suite of tools for medical image processing focused on brain analysis
Stars: ✭ 94 (+59.32%)
Mutual labels:  registration
benchmark VAE
Unifying Variational Autoencoder (VAE) implementations in Pytorch (NeurIPS 2022)
Stars: ✭ 1,211 (+1952.54%)
Mutual labels:  reproducible-research
ck-analytics
Collective Knowledge repository with actions to unify the access to different predictive analytics engines (scipy, R, DNN) from software, command line and web-services via CK JSON API:
Stars: ✭ 35 (-40.68%)
Mutual labels:  reproducible-research
WoWSimpleRegistration
Simple Registration page for TrinityCore/AzerothCore/AshamaneCore/CMangos
Stars: ✭ 121 (+105.08%)
Mutual labels:  registration
laravel-email-verification-app-boilerplate
Laravel app boilerplate with email verification process on registration
Stars: ✭ 41 (-30.51%)
Mutual labels:  registration
jupyter-guide
Guide for Reproducible Research and Data Science in Jupyter Notebooks
Stars: ✭ 111 (+88.14%)
Mutual labels:  reproducible-research

ITK Python Package

This project provides a setup.py script to build ITK Python binary packages and infrastructure to build ITK external module Python packages.

The Insight Toolkit (ITK) is an open-source, cross-platform system that provides developers with an extensive suite of software tools for image analysis. More information is available on the ITK website or at the ITK GitHub homepage.

Table of Contents

Using ITK Python Packages

ITKPythonPackage scripts can be used to produce Python packages for ITK and ITK external modules. The resulting packages can be hosted on the Python Package Index (PyPI) for easy distribution.

Installation

To install baseline ITK Python packages:

> pip install itk

To install ITK external module packages:

> pip install itk-<module_name>

Using ITK in Python scripts

    import itk
    import sys

    input_filename = sys.argv[1]
    output_filename = sys.argv[2]

    image = itk.imread(input_filename)

    median = itk.median_image_filter(image, radius=2)

    itk.imwrite(median, output_filename)

Other Resources for Using ITK in Python

See also the ITK Python Quick Start Guide. There are also many downloadable examples on the ITK examples website.

For more information on ITK's Python wrapping, an introduction is provided in the ITK Software Guide.

Building with ITKPythonPackage

ITK reusable workflows are available to build and package Python wheels as part of Continuous Integration (CI) via Github Actions runners. Those workflows can handle the overhead of fetching, configuring, and running ITKPythonPackage build scripts for most ITK external modules. See ITKRemoteModuleBuildTestPackageAction for more information.

For special cases where ITK reusable workflows are not a good fit, ITKPythonPackage scripts can be directly used to build Python wheels to target Windows, Linux, and MacOS platforms. See ITKPythonPackage ReadTheDocs documentation for more information on building wheels by hand.

Frequently Asked Questions

What target platforms and architectures are supported?

ITKPythonPackage currently supports building wheels for the following platforms and architectures:

  • Windows 10 x86_64 platforms
  • Windows 11 x86_64 platforms
  • MacOS 10.9+ x86_64 platforms
  • MacOS 11.0+ arm64 platforms
  • Linux glibc 2.17+ (E.g. Ubuntu 18.04+) x86_64 platforms
  • Linux glibc 2.28+ (E.g. Ubuntu 20.04+) aarch64 (ARMv8) platforms

What should I do if my target platform/architecture does not appear on the list above?

Please open an issue in the ITKPythonPackage issue tracker for discussion, and consider contributing either time or funding to support development. The ITK open source ecosystem is driven through contributions from its community members.

What is an ITK external module?

The Insight Toolkit consists of several baseline module groups for image analysis including filtering, I/O, registration, segmentation, and more. Community members can extend ITK by developing an ITK "external" module which stands alone in a separate repository and its independently built and tested. An ITK external module which meets community standards for documentation and maintenance may be included in the ITK build process as an ITK "remote" module to make it easier to retrieve and build.

Visit ITKModuleTemplate to get started creating a new ITK external module.

How can I make my ITK C++ filters available in Python?

ITK uses SWIG to wrap C++ filters for use in Python. See Chapter 9 in the ITK Software Guide or visit ITKModuleTemplate to get started on writing .wrap files.

After you've added wrappings for your external module C++ filters you may build and distribute Python packages automatically with ITKRemoteModuleBuildTestPackageAction or manually with ITKPythonPackage scripts.

What makes building ITK external module wheels different from building ITK wheels?

In order to build an ITK external module you must have first built ITK for the same target platform. However, building ITK modules and wrapping them for Python can take a very long time! To avoid having to rebuild ITK before building every individual external module, artifacts from the ITK build process (headers, source files, wrapper outputs, and more) are packaged and cached as ITKPythonBuilds releases.

In order to build Python wheels for an ITK external module, ITKPythonPackage scripts first fetch the appropriate ITK Python build artifacts along with other necessary tools. Then, the module can be built, packaged, and distributed on PyPI.

My external module has a complicated build process. Is it supported by ITKPythonPackage?

Start by consulting the ITKPythonPackage ReadTheDocs documentation and the ITKPythonPackage issue tracker for discussion related to your specific issue.

If you aren't able to find an answer for your specific case, please start a discussion the ITK Discourse forum for help.

Additional Information

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].