Skip to main content

Pictologics

Pictologics logo

CI Docs PyPI Python Downloads License codecov Ruff Mypy

Pictologics is a Python library for radiomic feature extraction from medical images. It follows IBSI 1 (the features) and IBSI 2 (the filters), and it checks its results against the IBSI reference values.

Documentation (user guide, tutorials, API, benchmarks): https://martonkolossvary.github.io/pictologics/

Why Pictologics?

  • 🚀 Fast: Numba compiles the computations for your computer, and they run on its fast cores. The Benchmarks page gives the time of each part.
  • ✅ IBSI compliant: checked against the IBSI phantoms and data sets:
    • IBSI 1 (features): 675 feature values pass; 21 more have a reference value without a tolerance (report).
    • IBSI 2 Phase 1 (filters): 28 of 28 compared tests pass (report).
    • IBSI 2 Phase 2 (filtered features): 9 of 9 tests pass (report).
    • IBSI 2 Phase 3 (reproducibility): 153 scans, compared with 9 teams (report).
  • 🔧 Versatile: reads NIfTI, NRRD, MetaImage and DICOM images, DICOM SEG, DICOM RTSTRUCT and 3D Slicer segmentations, and DICOM SR reports.
  • ✨ Easy to use: pip installs it. One pipeline runs the preprocessing and the features, for one image or for a whole study.
  • 🛡️ Predictable results: each configuration gives all its feature columns, also when a step fails (the values are then NaN). A study table never has missing columns.
  • 🛠️ Maintained: Pictologics is developed to give robust radiomic features that describe the morphology of diseases on radiological images.

What Is New in 0.7.0

  • Speed: on a 512×512×200 CT, timed by turns with 0.6.0 on one computer, the configuration standard_fbn_32 takes 48 % less time, the six standard configurations 30 % less, and run_rois with 20 ROIs 60 % less.
  • Threads: Pictologics uses the fast cores by default, for example the performance cores of Apple silicon. set_num_threads(), get_num_threads() and PICTOLOGICS_NUM_THREADS set one number for all parallel parts.
  • First run: the import compiles every numba kernel that a run can use, so no code compiles during a run.
  • Installation: Intel Macs, and 3D Slicer under Rosetta, can install Pictologics again (with numba 0.62). Matplotlib is now the optional extra viz: pip install "pictologics[viz]". pandas 3, Pillow 12, SciPy 1.18 and numba 0.68 work.
  • Fixes: the DICOM database scan, big-endian and multi-frame DICOM series, the frame positions of DICOM SEG files, NRRD byte skips, and the percentiles of large ROIs (a rare case).
  • Changes: merged masks keep the type of their inputs (uint8 with binarize), and save_slices writes one pixel per voxel, with dpi as the tag of the file. Some texture and histogram values change in their last digits; the IBSI compliance is the same. See the Changelog.

Installation

Pictologics needs Python 3.12, 3.13 or 3.14.

pip install pictologics

From the source code:

git clone https://github.com/martonkolossvary/pictologics.git
cd pictologics
pip install .

Quick Start

from pictologics import RadiomicsPipeline, format_results, save_results

# 1. A pipeline with the six standard configurations
pipeline = RadiomicsPipeline()

# 2. Run the configurations on an image and its mask
results = pipeline.run(
    image="path/to/ct.nii.gz",
    mask="path/to/mask.nii.gz",
    subject_id="Subject_001",
    config_names=["all_standard"],  # the FBS configurations start at -1000 HU, for CT
)

# 3. One table row, with your own columns first
row = format_results(results, fmt="wide", meta={"subject_id": "Subject_001", "group": "control"})

# 4. Save the row to a CSV file
save_results([row], "results.csv")

For MR or PET images, use the FBN configurations (config_names=["standard_fbn_32"]) or your own. See the Quick Start and the Cookbook.

Performance Benchmarks

Task Size Time (median)
run(): one standard configuration (standard_fbn_32) CT of 512 × 512 × 200 11.7 ms
run(): the 6 standard configurations CT of 512 × 512 × 200 44.5 ms
Texture (all 6 families) 2,311,384 ROI voxels 27.4 ms
Morphology 2,311,384 ROI voxels 9.6 ms
LoG (sigma 2 mm) 256³ voxels 50.3 ms
Gabor (axial, rotation invariant) 256³ voxels 48.3 ms

The median of 5 runs on one computer, after a warm-up run. See the benchmark page for all results, plots and the computer.

Quality & Compliance

IBSI Compliance: IBSI 1 Features | IBSI 2 Phase 1 Filters | Phase 2 Features | Phase 3 Reproducibility

Code Health

  • Test Coverage: 100.00%
  • Mypy Errors: 0
  • Ruff Issues: 0

See Quality Report for full details.

Citation

Citation information will be added/updated.

License

Apache-2.0

Metadata

Release files for pictologics 0.7.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for pictologics 0.7.1
File Size Uploaded
pictologics-0.7.1.tar.gz 308.1 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for pictologics 0.7.1
File Interpreter ABI Platform
pictologics-0.7.1-py3-none-any.whl Python 3 none any Details

Total release size: 639.6 kB

Release files / pictologics-0.7.1.tar.gz

Download URL pictologics-0.7.1.tar.gz
Size 308.1 kB
Tags Source
SHA-256 checksum
How to use checksums
cfc521a16d43d3980de183f220efd6d4102ac01b0ce3e61d6d2e678e6547e384
BLAKE2b-256 checksum
How to use checksums
86195bbbd8e8609a0befb93b2f603e03ed81e8df7f91f15d290c56ea7bf52088
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 8, 2026.

Transparency log

Release files / pictologics-0.7.1-py3-none-any.whl

Download URL pictologics-0.7.1-py3-none-any.whl
Size 331.4 kB
Tags Python 3
SHA-256 checksum
How to use checksums
aa9bf3cff2ea22012732cb40f2ada17d49d0a87643c80db66667a10284537bfc
BLAKE2b-256 checksum
How to use checksums
4b5ba4d05411585e6a88093ed247859c39fc8a4522b575d96468cf273917fb34
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 8, 2026.

Transparency log

Release history Release notifications | RSS feed

This release

0.7.1 This release

2 release files

0.7.0

2 release files

0.6.0

2 release files

0.5.1

2 release files

0.5.0

2 release files

0.4.2

2 release files

0.4.1

2 release files

0.4.0

2 release files

0.3.5

2 release files

0.3.4

2 release files

0.3.3

2 release files

0.3.2

2 release files

0.3.1

2 release files

0.3.0

2 release files

0.2.0

2 release files

0.1.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page