Python bindings of the gems segmentation package.
Project description
charm-gems
This repository contains the gems C++ code and python bindings used in Freesurfer's Sequence-Adaptive Multimodal SEGmentation (SAMSEG) (Puonti et al., NeuroImage, 2016) and in SimNIBS 4.0 Complete Head Anatomy Reconstruction Method (CHARM) (Puonti et al., NeuroImage, 2020) to create individualized head models for electric field simulations.
Installation
The compiled charm-gems library is available via pip ≥ 19.3, for python 3.6, 3.7 and 3.8
pip install --upgrade pip
pip install charm-gems
Afterwards the package can be imported by calling
import charm_gems as gems
Manual Installation
Requirements
- A C++ compiler compatible with C++ 11
- Python ≥ 3.6
- CMake
- Make (Linux/MacOS)
- Visual Studio (Windows)
- zlib (for windows, see https://github.com/horta/zlib.install)
Preparation
This repository uses submodules. To start it, use
git submodule init
git submodule update
Linux/MacOS
- Build ITK
mkdir ITK-build
cd ITK-build
cmake \
-DBUILD_SHARED_LIBS=OFF \
-DBUILD_TESTING=OFF \
-DBUILD_EXAMPLES=OFF \
-DCMAKE_BUILD_TYPE=Release \
-DCMAKE_INSTALL_PREFIX=../ITK-install \
../ITK
make install
cd ..
- Install charm-gems
ITK_DIR=ITK-install python setup.py install
Windows (Tested on Visual Studio 2019)
- Build ITK
md ITK-build
cd ITK-build
cmake.exe ^
-DBUILD_SHARED_LIBS=OFF ^
-DBUILD_TESTING=OFF ^
-DBUILD_EXAMPLES=OFF ^
-DCMAKE_BUILD_TYPE=Release ^
-DCMAKE_INSTALL_PREFIX=..\ITK-install ^
..\ITK
cmake --build . --config Release --target Install
cd ..
- Install charm-gems
set ITK_DIR=ITK-install
python setup.py install
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distributions
Built Distributions
File details
Details for the file charm_gems-1.0.5-cp38-cp38-win_amd64.whl
.
File metadata
- Download URL: charm_gems-1.0.5-cp38-cp38-win_amd64.whl
- Upload date:
- Size: 2.8 MB
- Tags: CPython 3.8, Windows x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.7.1 importlib_metadata/4.8.2 pkginfo/1.8.2 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.8.10
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | b18b75a91a9c7f015805788ab49401c09558f14f76d8de0de1a33c690517621e |
|
MD5 | f2cfdc446a3c31b16235b37117af406c |
|
BLAKE2b-256 | 2fbffd5a0f554ceffd6f481f8e05633a8e960ccd017e8373b109e9d981c7f3cc |
File details
Details for the file charm_gems-1.0.5-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
.
File metadata
- Download URL: charm_gems-1.0.5-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
- Upload date:
- Size: 5.5 MB
- Tags: CPython 3.8, manylinux: glibc 2.17+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.7.1 importlib_metadata/4.8.2 pkginfo/1.8.2 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.8.12
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 0352a43373ec81c607a8e13d3f61d65c12d6688161cde6a93fe3286eb9f2be41 |
|
MD5 | 2aef0cfee0245aed6070890535cd1def |
|
BLAKE2b-256 | 505ab1d1578d22be31077e47c1d8875a72fc49a232f1b80922234ec17783bdc2 |
File details
Details for the file charm_gems-1.0.5-cp38-cp38-macosx_10_9_x86_64.whl
.
File metadata
- Download URL: charm_gems-1.0.5-cp38-cp38-macosx_10_9_x86_64.whl
- Upload date:
- Size: 4.6 MB
- Tags: CPython 3.8, macOS 10.9+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.7.1 importlib_metadata/4.8.2 pkginfo/1.8.2 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.8.3
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | e84aff394f3ec8adeeffd29e15c07078af7adbd81c87e4e2e164fc7d7457868d |
|
MD5 | 419b7e947ac11a3efc47d1b59829813f |
|
BLAKE2b-256 | 761640930fbd3392a28b542aa855a8af3dc4ba340b0b67fa4b274418d45ed697 |
File details
Details for the file charm_gems-1.0.5-cp37-cp37m-win_amd64.whl
.
File metadata
- Download URL: charm_gems-1.0.5-cp37-cp37m-win_amd64.whl
- Upload date:
- Size: 2.8 MB
- Tags: CPython 3.7m, Windows x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.7.1 importlib_metadata/4.8.2 pkginfo/1.8.2 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.8.10
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | b50e3c3ec97dbe18280ee8964dccafd649321ec9a2a4576a5cdfafdd87d7a70b |
|
MD5 | f7aee429e28372a2eb6d74f370aa566c |
|
BLAKE2b-256 | 642b4c2b5c99d04992514d95ea66a8711f723d1df7f81df137fe81facde4be77 |
File details
Details for the file charm_gems-1.0.5-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
.
File metadata
- Download URL: charm_gems-1.0.5-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
- Upload date:
- Size: 5.5 MB
- Tags: CPython 3.7m, manylinux: glibc 2.17+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.7.1 importlib_metadata/4.8.2 pkginfo/1.8.2 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.8.12
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 9704a4f951edc8d31f1ad153b0912f3cbeac1420fd5cde31c88dbe177f748ecb |
|
MD5 | b9642285500ee4c7cdbc8e742c3ed2c4 |
|
BLAKE2b-256 | 1aae0a488c7c3aa87b7e75b6cd8821325c38ecc4e5f4c975e9b52bbc39f84ad7 |
File details
Details for the file charm_gems-1.0.5-cp37-cp37m-macosx_10_9_x86_64.whl
.
File metadata
- Download URL: charm_gems-1.0.5-cp37-cp37m-macosx_10_9_x86_64.whl
- Upload date:
- Size: 4.6 MB
- Tags: CPython 3.7m, macOS 10.9+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.7.1 importlib_metadata/4.8.2 pkginfo/1.8.2 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.8.3
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | c23d20d462acd324380555832c5810e13f8bc2197e0b867897d5ad22b04c4045 |
|
MD5 | 8414ee41c5521d0ba01da40461a1f23a |
|
BLAKE2b-256 | e2b13e021ea05cc187829ba0a63dfc729cb7bdd341f5fd0d9516f0ad033e9b05 |
File details
Details for the file charm_gems-1.0.5-cp36-cp36m-win_amd64.whl
.
File metadata
- Download URL: charm_gems-1.0.5-cp36-cp36m-win_amd64.whl
- Upload date:
- Size: 2.8 MB
- Tags: CPython 3.6m, Windows x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.7.1 importlib_metadata/4.8.2 pkginfo/1.8.2 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.8.10
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 5fbc9bcf4fddc6ee40c1f9448e9fb0cca72ac35c631436d98ffa37434651223f |
|
MD5 | fa826445a48b95c22b6998097eabda07 |
|
BLAKE2b-256 | e5b9ef5f6325fd1bdf63b8e569433cf93479ef52625142ea3084600b163fda68 |
File details
Details for the file charm_gems-1.0.5-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
.
File metadata
- Download URL: charm_gems-1.0.5-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
- Upload date:
- Size: 5.5 MB
- Tags: CPython 3.6m, manylinux: glibc 2.17+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.7.1 importlib_metadata/4.8.2 pkginfo/1.8.2 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.8.12
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 58a808694034549967e06b904e6e4bc567f183dd7b23bcd8d61afba8b787490f |
|
MD5 | 608202e96f44472d8037ddc54e7440ef |
|
BLAKE2b-256 | 1e2e43920d755bf142f34893f9808af75a978e262d12d7a66c66f12a8b5440a9 |
File details
Details for the file charm_gems-1.0.5-cp36-cp36m-macosx_10_9_x86_64.whl
.
File metadata
- Download URL: charm_gems-1.0.5-cp36-cp36m-macosx_10_9_x86_64.whl
- Upload date:
- Size: 4.6 MB
- Tags: CPython 3.6m, macOS 10.9+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.7.1 importlib_metadata/4.8.2 pkginfo/1.8.2 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.8.3
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | c818afa3db1e38003d3d551e382796b7ff5dcae29fa980cc56de91fb2ef17c00 |
|
MD5 | e68c298432fedf5141b77fc71cd601bd |
|
BLAKE2b-256 | b310d3e3ee063a6c9b58c99e4ceb1afab620794e1cdb4a6d5ba2b16bbd9d3832 |