No project description provided
Project description
voxcov-py
Python bindings for voxcov.
Quick start
Clone voxcov
first.
Run maturin develop --release
to build and install the plugin. Use the --release
flag to get an optimized build.
Coverage example
Import the library
import voxcov as vc
Create a map.
apix = [1.0, 1.0, 1.0]
origin = [0.0, 0.0, 0.0]
# The maximum axis length
size = 256
vox_map = vc.Map(apix, origin, size)
Add and delete spheres.
# Add a sphere of radius 3.5 at (10,10,10)
vox_map.add_sphere([10.0, 10.0, 10.0], 3.5, lambda vox: print("Adding A Covered: ", vox))
# Add another sphere which overlaps mostly of radius 3.5 at (11,10,10)
vox_map.add_sphere([11.0, 10.0, 10.0], 3.5, lambda vox: print("Adding B Covered: ", vox))
# Delete sphere which overlaps mostly of radius 3.5 at (11,10,10)
vox_map.del_sphere([11.0, 10.0, 10.0], 3.5, lambda vox: print("Deleting B uncovered: ", vox))
Blur example
Import the library
import voxcov as vc
Create a blurrer. Note, the API is a bit clunky. Named parameters would be nice.
blurred_map = vc.BlurMap(
[1.084,1.084,1.084], # The cell dimensions
[0,0,0], # The origin
[256,256,256], # The size, 256^3
5.1, # Sigma for gaussian
# e.g. (sigma_coef * resolution)
4.0 # The number of sigma to cutoff at
)
Stick atoms in.
# We pass the center and scale of each gaussian.
blurred_map.add_gaussian([3,4,5], 10)
blurred_map.add_gaussian([4,5,3], 12)
Get a numpy array out.
blurred_map.to_numpy()
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 voxcov-0.2.8-cp311-none-win_amd64.whl
.
File metadata
- Download URL: voxcov-0.2.8-cp311-none-win_amd64.whl
- Upload date:
- Size: 221.0 kB
- Tags: CPython 3.11, Windows x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.11.5
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 3f603163d4c8a4dc44c79c54bf607e2f5811d09e269b7627d7605d4c07c66a95 |
|
MD5 | c0b823d66a6f61ddf195623dee57797f |
|
BLAKE2b-256 | d823a48edc5d7b106013906b7286b03c88db3b83624fe0c2dd5f6d8408093c94 |
File details
Details for the file voxcov-0.2.8-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
.
File metadata
- Download URL: voxcov-0.2.8-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
- Upload date:
- Size: 1.3 MB
- Tags: CPython 3.11, manylinux: glibc 2.17+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.11.5
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 506f25b0942feef9ee11880856582c128b6aef04e4c20d4f1b654addce7f03b1 |
|
MD5 | fd596156ab213237c5afe3977f1c3b5d |
|
BLAKE2b-256 | 61423f1fa28d75e407913905560d8b842942c857f5dd0df32c4ebccaf9848c04 |
File details
Details for the file voxcov-0.2.8-cp311-cp311-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl
.
File metadata
- Download URL: voxcov-0.2.8-cp311-cp311-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl
- Upload date:
- Size: 698.2 kB
- Tags: CPython 3.11, macOS 10.9+ universal2 (ARM64, x86-64), macOS 10.9+ x86-64, macOS 11.0+ ARM64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.11.5
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 9bff0056547c633f12506429a15283e97fbc55992de58882811984baa0290d1b |
|
MD5 | cf1d061935fb4ec78d1ecfac7d75d111 |
|
BLAKE2b-256 | 0eac8ee4d4b9220c64645e8975b19e45433bb00a1f956c17df9e581580f2909d |
File details
Details for the file voxcov-0.2.8-cp310-none-win_amd64.whl
.
File metadata
- Download URL: voxcov-0.2.8-cp310-none-win_amd64.whl
- Upload date:
- Size: 221.0 kB
- Tags: CPython 3.10, Windows x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.11.5
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 29ce0fe4cb9c6bdccba6b7c2219adcc103d73f1d8b6847f748219540fdd9a613 |
|
MD5 | 17ec6f9fbf4df64b2a814c6e224029fa |
|
BLAKE2b-256 | 669da129b4be177459382ff30617fb662c51d93b3b4ab8d1a77d6edefc5941b7 |
File details
Details for the file voxcov-0.2.8-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
.
File metadata
- Download URL: voxcov-0.2.8-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
- Upload date:
- Size: 1.3 MB
- Tags: CPython 3.10, manylinux: glibc 2.17+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.11.5
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 0bfadc94b7f581591afaa1336200f57b20ade90987848dab51bc54abe1d5d766 |
|
MD5 | d1a0b43382f18bee9d105d2e13ea4d67 |
|
BLAKE2b-256 | f31bdd7acb535399cbbffbdd6b877afa030bf11b95cc974aebcd1ed28af60f85 |
File details
Details for the file voxcov-0.2.8-cp310-cp310-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl
.
File metadata
- Download URL: voxcov-0.2.8-cp310-cp310-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl
- Upload date:
- Size: 698.2 kB
- Tags: CPython 3.10, macOS 10.9+ universal2 (ARM64, x86-64), macOS 10.9+ x86-64, macOS 11.0+ ARM64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.11.5
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 0334cc2f5c4ff470f78cd8b73008388938bb1edc15b2673d84cb1b5af406e937 |
|
MD5 | 5b34062301855c01b77376486f9ab58f |
|
BLAKE2b-256 | b2664acdb4931ac2e13063575ce749b4a05dcf50091ba01caab11fdd4760928e |
File details
Details for the file voxcov-0.2.8-cp39-none-win_amd64.whl
.
File metadata
- Download URL: voxcov-0.2.8-cp39-none-win_amd64.whl
- Upload date:
- Size: 221.1 kB
- Tags: CPython 3.9, Windows x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.11.5
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | f0ed6806562bcca0cbc7ec1e4572bcd1c50c0d4cd7e4a1ec9c4d2ff8f6be9195 |
|
MD5 | 6a8ca5d0e8b8e869548f1f62a0d25c08 |
|
BLAKE2b-256 | ef3d8b0e71a20eb1d2cdcbbea6c74587a1ff91029486acf7a6b02d5618fc81f1 |
File details
Details for the file voxcov-0.2.8-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
.
File metadata
- Download URL: voxcov-0.2.8-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
- Upload date:
- Size: 1.3 MB
- Tags: CPython 3.9, manylinux: glibc 2.17+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.11.5
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 18377001020fa9c1ffc1ae7416bf104b1bbb21c1065a9189f06168bcfc4769cf |
|
MD5 | f1fd4b0ddb8df26b905b5f68a686c262 |
|
BLAKE2b-256 | 511b2d1732c5a87d42ca003a225e8552b108b29a380a71148e5d8f409964f57d |
File details
Details for the file voxcov-0.2.8-cp39-cp39-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl
.
File metadata
- Download URL: voxcov-0.2.8-cp39-cp39-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl
- Upload date:
- Size: 698.3 kB
- Tags: CPython 3.9, macOS 10.9+ universal2 (ARM64, x86-64), macOS 10.9+ x86-64, macOS 11.0+ ARM64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.11.5
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 964b4120bbc5dfb4dd14ccbb92613efbaef4cc53cdd93404cf761c7a2637f20b |
|
MD5 | 19d0cea9644c208004e49765ce39532e |
|
BLAKE2b-256 | 73557b25c1d3d1084c63035a119fd75f326c7b16a172802a83f0f84476e65e9a |
File details
Details for the file voxcov-0.2.8-cp38-none-win_amd64.whl
.
File metadata
- Download URL: voxcov-0.2.8-cp38-none-win_amd64.whl
- Upload date:
- Size: 221.4 kB
- Tags: CPython 3.8, Windows x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.11.5
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | bbdf043c6ba48b5f0b14089aac75f2e878786969fef7c61fdc23482b7f09200d |
|
MD5 | c1bad2e24abbba4e4cbf43d0a725b11b |
|
BLAKE2b-256 | 19d0e3484f76974ecc07fb990d68c7bb93178c672ba11fa5bb5c67e59ed47141 |
File details
Details for the file voxcov-0.2.8-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
.
File metadata
- Download URL: voxcov-0.2.8-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
- Upload date:
- Size: 1.3 MB
- Tags: CPython 3.8, manylinux: glibc 2.17+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.11.5
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 3934bcf318245dd98b30fe43eef65a2a9f4fec194f8326385dc3ba1ffad7a396 |
|
MD5 | 074bf08739bcfe115de86c9cda49c7e9 |
|
BLAKE2b-256 | bf256585995d2e508414b8241e684301c21ad4edfbd31453ac74821a212d04b4 |
File details
Details for the file voxcov-0.2.8-cp38-cp38-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl
.
File metadata
- Download URL: voxcov-0.2.8-cp38-cp38-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl
- Upload date:
- Size: 697.6 kB
- Tags: CPython 3.8, macOS 10.9+ universal2 (ARM64, x86-64), macOS 10.9+ x86-64, macOS 11.0+ ARM64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.11.5
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 16fbbcfd1fa2b52d27919242b9372eda0684899d4397f80d5b24c730877395dc |
|
MD5 | 98e021a13b6a2326b7c6ad685de1e938 |
|
BLAKE2b-256 | a6634c6b119c775a2e62ef41942ce0be6423ab789e59f749acd88c142858cbcf |