hhaentze/RenalVision

Modular Framework for Lesion Classification

1

stars

115

commits

Python

primary language

Aug 25, 2026

updated

README

Renal Vision Logo Renal Vision

The Modular Lesion Analysis Platform

RenalVision is a modular platform for quantifying and classifying renal lesions. It keeps feature extraction (Radiomics, Neural Embeddings) cleanly separated from model training and evaluation, so swapping in a different backbone or classifier is straightforward. Trained models are packaged as self-contained bundles that carry their own preprocessing config and class mappings, making inference portable and reproducible. The platform ships with eight pre-trained models out of the box: radiomics_binary, radiomics, mevis, mevis_unicorn, fmcib, ctfm, spectre, and renalclip. Read more about the bundles in their readme.md.

Workflow

🛠️ Installation

We recommend Python 3.10. The base install covers radiomics support. If you want to run foundation models please specify these as additional dependencies: run make install once, then any number of the commands below. Run make list-models for the current list. (Our implementations of M3 default and M3 unicorn are incompatible with each other. If you want to run both, please specify independent virtual environments.)

ModelCommandNotes
Radiomicsmake installincluded in base
M3 (default)make model-mevis⚠️ conflicts with M3 UNICORN
M3 (UNICORN)make model-mevis_unicorn⚠️ conflicts with M3 default
RenalCLIPmake installincluded in base
SPECTREmake model-spectre
CT-FMmake model-ctfminstalled --no-deps
FMCIBmake model-fmcibinstalled --no-deps
# Clone or download the repository
git clone https://github.com/hhaentze/RenalVision.git
cd RenalVision

# Base install (radiomics only)
make install

# [Optional] install other dependencies, for example the M3 (unicorn) model
make model-mevis_unicorn

🔬 Inference

The platform exposes a unified command-line interface: rv.

rv infer \
    --image scan_001.nii.gz \
    --seg mask_001.nii.gz \
    --output prediction_001.nii.gz \
    --model "RADIOMICS"

Alternatively, use our python interface! You can choose between image-level classification that returns an updated segmentation mask, or lesion-level, which returns details information about a specific lesion prediction.

from renal_vision.modeling.inference import LesionPredictor

# 1. Initialize Predictor
predictor = LesionPredictor(model_identifier="RADIOMICS_BINARY")

# 2. Predict full mask (multi-lesion)
mask = predictor.infer_mask(
    image="scan.nii.gz", seg="full_mask.nii.gz", output_path="predictions.nii.gz"
)

# 3. Predict a single lesion
result = predictor.infer_lesion(image="scan.nii.gz", seg="lesion_mask.nii.gz")
print(result)
{
  'class_id': 0,                    # predicted class
  'class_name': 'Tumor',            # predicted class name
  'confidence': 0.997,              # proability of predicted class
  'probability': [0.997, 0.003],    # proabilities of all classes
  'volume': 8726                    # volume of target lesions in mm^3
 }

🔧 Useful Tools from our Lab:

  • Automatic segmentation of kidneys and masses: RenalNet
  • Pre-annotated TCGA kidney tumour data: RCC-AID

📦 Demo Workflow

Test the pretrained model directly on data from RCC-AID: Inference.ipynb

Train and evaluate your own classification model on the KiTS23 data. No GPU needed! Training.ipynb

📋 Citation

Paper under Review. Please cite this preprint: arXiv.

If you used any of the FM based classifiers in your research please refer to their GitHub for citation guidelines:

⚖️ Licensing

RenalVision's own code and trained classifier heads are licensed Apache-2.0.

Feature extractors are third-party works with their own licenses. RenalVision distributes no third-party weights — they are fetched at runtime from the original providers. The terms of the extractor you choose apply to your use of that pipeline:

BundleCode usedWeights licenseCommercial use
radiomics, radiomics_binaryPyRadiomics (BSD-3-Clause)
ctfmctfm pip pkg (MIT)Apache-2.0
renalclipreimplementationMIT
fmcibfmcib pip pkg + adapted snippets (MIT)CC-BY-4.0✅ with attribution
spectrespectre-fm pip pkg (MIT)CC-BY-NC-SA-4.0❌ non-commercial
mevis, mevis_unicornmedicalmultitaskmodeling pip pkg (Fraunhofer non-commercial research license)same❌ non-commercial, no redistribution, research institutions only

Note: This table is provided for orientation only. It reflects our reading of the upstream licenses at the time of writing and carries no guarantee of accuracy or completeness. Before relying on any pipeline — especially commercially or clinically — consult the upstream license texts directly and seek your own legal advice.

RenalVision is research software. It is not CE-marked or FDA-cleared, and no conformity assessment has been performed for it or for any of the included feature extractors. The M3 (mevis, mevis_unicorn) license additionally prohibits the use of any results obtained from that model for diagnostic or therapeutic purposes.

Contributors

hhaentze

115 commits

hhaentze/RenalVision

Modular Framework for Lesion Classification

1

stars

115

commits

Python

primary language

Aug 25, 2026

updated

README

Renal Vision Logo Renal Vision

The Modular Lesion Analysis Platform

RenalVision is a modular platform for quantifying and classifying renal lesions. It keeps feature extraction (Radiomics, Neural Embeddings) cleanly separated from model training and evaluation, so swapping in a different backbone or classifier is straightforward. Trained models are packaged as self-contained bundles that carry their own preprocessing config and class mappings, making inference portable and reproducible. The platform ships with eight pre-trained models out of the box: radiomics_binary, radiomics, mevis, mevis_unicorn, fmcib, ctfm, spectre, and renalclip. Read more about the bundles in their readme.md.

Workflow

🛠️ Installation

We recommend Python 3.10. The base install covers radiomics support. If you want to run foundation models please specify these as additional dependencies: run make install once, then any number of the commands below. Run make list-models for the current list. (Our implementations of M3 default and M3 unicorn are incompatible with each other. If you want to run both, please specify independent virtual environments.)

ModelCommandNotes
Radiomicsmake installincluded in base
M3 (default)make model-mevis⚠️ conflicts with M3 UNICORN
M3 (UNICORN)make model-mevis_unicorn⚠️ conflicts with M3 default
RenalCLIPmake installincluded in base
SPECTREmake model-spectre
CT-FMmake model-ctfminstalled --no-deps
FMCIBmake model-fmcibinstalled --no-deps
# Clone or download the repository
git clone https://github.com/hhaentze/RenalVision.git
cd RenalVision

# Base install (radiomics only)
make install

# [Optional] install other dependencies, for example the M3 (unicorn) model
make model-mevis_unicorn

🔬 Inference

The platform exposes a unified command-line interface: rv.

rv infer \
    --image scan_001.nii.gz \
    --seg mask_001.nii.gz \
    --output prediction_001.nii.gz \
    --model "RADIOMICS"

Alternatively, use our python interface! You can choose between image-level classification that returns an updated segmentation mask, or lesion-level, which returns details information about a specific lesion prediction.

from renal_vision.modeling.inference import LesionPredictor

# 1. Initialize Predictor
predictor = LesionPredictor(model_identifier="RADIOMICS_BINARY")

# 2. Predict full mask (multi-lesion)
mask = predictor.infer_mask(
    image="scan.nii.gz", seg="full_mask.nii.gz", output_path="predictions.nii.gz"
)

# 3. Predict a single lesion
result = predictor.infer_lesion(image="scan.nii.gz", seg="lesion_mask.nii.gz")
print(result)
{
  'class_id': 0,                    # predicted class
  'class_name': 'Tumor',            # predicted class name
  'confidence': 0.997,              # proability of predicted class
  'probability': [0.997, 0.003],    # proabilities of all classes
  'volume': 8726                    # volume of target lesions in mm^3
 }

🔧 Useful Tools from our Lab:

  • Automatic segmentation of kidneys and masses: RenalNet
  • Pre-annotated TCGA kidney tumour data: RCC-AID

📦 Demo Workflow

Test the pretrained model directly on data from RCC-AID: Inference.ipynb

Train and evaluate your own classification model on the KiTS23 data. No GPU needed! Training.ipynb

📋 Citation

Paper under Review. Please cite this preprint: arXiv.

If you used any of the FM based classifiers in your research please refer to their GitHub for citation guidelines:

⚖️ Licensing

RenalVision's own code and trained classifier heads are licensed Apache-2.0.

Feature extractors are third-party works with their own licenses. RenalVision distributes no third-party weights — they are fetched at runtime from the original providers. The terms of the extractor you choose apply to your use of that pipeline:

BundleCode usedWeights licenseCommercial use
radiomics, radiomics_binaryPyRadiomics (BSD-3-Clause)
ctfmctfm pip pkg (MIT)Apache-2.0
renalclipreimplementationMIT
fmcibfmcib pip pkg + adapted snippets (MIT)CC-BY-4.0✅ with attribution
spectrespectre-fm pip pkg (MIT)CC-BY-NC-SA-4.0❌ non-commercial
mevis, mevis_unicornmedicalmultitaskmodeling pip pkg (Fraunhofer non-commercial research license)same❌ non-commercial, no redistribution, research institutions only

Note: This table is provided for orientation only. It reflects our reading of the upstream licenses at the time of writing and carries no guarantee of accuracy or completeness. Before relying on any pipeline — especially commercially or clinically — consult the upstream license texts directly and seek your own legal advice.

RenalVision is research software. It is not CE-marked or FDA-cleared, and no conformity assessment has been performed for it or for any of the included feature extractors. The M3 (mevis, mevis_unicorn) license additionally prohibits the use of any results obtained from that model for diagnostic or therapeutic purposes.

Contributors

hhaentze

115 commits

Languages

Python

93.4%

Jupyter Notebook

5.6%

Makefile

1.0%