A PyTorch tool kit for estimating the content area in endoscopic footage.
Project description
Torch Content Area
A PyTorch tool kit for estimating the circular content area in endoscopic footage. This implementation is released alongside our publication:
- Rapid and robust endoscopic content area estimation: A lean GPU-based pipeline and curated benchmark dataset,
Charlie Budd, Luis C. Garcia-Peraza-Herrera, Martin Huber, Sebastien Ourselin, Tom Vercauteren.
[ arXiv ]
If you make use of this work, please cite the paper.
Installation
To install the latest version, simply run...
pip install torchcontentarea
Usage
from torchvision.io import read_image
from torchcontentarea import estimate_area, get_points, fit_area
# Image in NCHW format, byte/uint8 type is expected
image = read_image("my_image.png").unsqueeze(0)
# Either directly estimate area from image...
area = estimate_area(image, strip_count=16)
# ...or get the set of points and then fit the area.
points = get_points(image, strip_count=16)
area = fit_area(points, image.shape[2:4])
Performance
Performance is measured against the CholecECA subset of the Endoscopic Content Area (ECA) dataset.
Performance Results (handcrafted cpu)...
- Avg Time (Intel(R) Xeon(R) CPU E5-1650 v3 @ 3.50GHz): 2.501ms
- Avg Error (Hausdorff Distance): 3.535
- Miss Rate (Error > 15): 2.1%
- Bad Miss Rate (Error > 25): 1.0%
Performance Results (learned cpu)...
- Avg Time (Intel(R) Xeon(R) CPU E5-1650 v3 @ 3.50GHz): 4.662ms
- Avg Error (Hausdorff Distance): 4.388
- Miss Rate (Error > 15): 2.6%
- Bad Miss Rate (Error > 25): 1.4%
Performance Results (handcrafted cuda)...
- Avg Time (NVIDIA GeForce GTX 980 Ti): 0.171ms
- Avg Error (Hausdorff Distance): 4.289
- Miss Rate (Error > 15): 2.4%
- Bad Miss Rate (Error > 25): 1.3%
Performance Results (learned cuda)...
- Avg Time (NVIDIA GeForce GTX 980 Ti): 1.349ms
- Avg Error (Hausdorff Distance): 4.641
- Miss Rate (Error > 15): 2.6%
- Bad Miss Rate (Error > 25): 1.3%
Project details
Release history Release notifications | RSS feed
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 torchcontentarea-0.4.0-cp39-cp39-manylinux2014_x86_64.manylinux_2_17_x86_64.whl
.
File metadata
- Download URL: torchcontentarea-0.4.0-cp39-cp39-manylinux2014_x86_64.manylinux_2_17_x86_64.whl
- Upload date:
- Size: 2.3 MB
- Tags: CPython 3.9, manylinux: glibc 2.17+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.1 CPython/3.9.15
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 4df83b0d0893abc840b8a350aa0f0fce2b2777fc89806895aa2ab5e33955fc7c |
|
MD5 | cb9c8ffb5a4a22a52300fb578a4e7a10 |
|
BLAKE2b-256 | 1d7035b09412e63d78b9fefb9b2c6687870b103e8fcca0678a1d5633c55eb0c5 |
File details
Details for the file torchcontentarea-0.4.0-cp38-cp38-manylinux2014_x86_64.manylinux_2_17_x86_64.whl
.
File metadata
- Download URL: torchcontentarea-0.4.0-cp38-cp38-manylinux2014_x86_64.manylinux_2_17_x86_64.whl
- Upload date:
- Size: 2.3 MB
- Tags: CPython 3.8, manylinux: glibc 2.17+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.1 CPython/3.9.15
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 442822b904d87ca007ad4fb06cac0fe6dae89a2453104ec9b0553586cbe3b51e |
|
MD5 | bb294367adf9ad11526b0f6bb10bbf2d |
|
BLAKE2b-256 | c0d6abf3a673b671500a9f96af49cc08e6c27d98fc91031d0070283b8bef7a28 |
File details
Details for the file torchcontentarea-0.4.0-cp37-cp37m-manylinux2014_x86_64.manylinux_2_17_x86_64.whl
.
File metadata
- Download URL: torchcontentarea-0.4.0-cp37-cp37m-manylinux2014_x86_64.manylinux_2_17_x86_64.whl
- Upload date:
- Size: 2.3 MB
- Tags: CPython 3.7m, manylinux: glibc 2.17+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.1 CPython/3.9.15
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 2edecb64d3a2c31d9c3f0c12cdfee72d225142f36c64c5d4a84f5badc29b4fca |
|
MD5 | 50a22f58ecebbf960c1543d2ff4d2988 |
|
BLAKE2b-256 | bed0d4dd291f2e6c911591ec9acc57bc6b5c060af4d32a806f9a96975d23eebf |
File details
Details for the file torchcontentarea-0.4.0-cp36-cp36m-manylinux2014_x86_64.manylinux_2_17_x86_64.whl
.
File metadata
- Download URL: torchcontentarea-0.4.0-cp36-cp36m-manylinux2014_x86_64.manylinux_2_17_x86_64.whl
- Upload date:
- Size: 1.0 MB
- Tags: CPython 3.6m, manylinux: glibc 2.17+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.1 CPython/3.9.15
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 1a585f1fc7bd2922b91083d63c95a5b1ec3836d8fff5378bc8cb7a388632ad3f |
|
MD5 | a7dedb19ef4fe93ef1c25354382cb6dd |
|
BLAKE2b-256 | 873693ed35000812004c4ebce8004c808e16a4b489382ebfd29dde02ec478680 |