Skip to content

API overview

Everything you need for simple use is importable from the top-level medpipe package. The other classes documented in this reference are the building blocks behind those entry points.

Entry points

Object Purpose
MedpipeClassifier Run, fit, predict, evaluate and plot binary classification pipelines.
MedpipeRegressor Same workflow for regression outcomes with predictive distributions.
MedpipeClassifierConfig Validated configuration for a classifier, built from a TOML file or in code.
MedpipeRegressorConfig Validated configuration for a regressor.
from medpipe import MedpipeClassifier

pipe = MedpipeClassifier("config.toml")
pipe.run()

Extension points

Object Purpose
ModelRegistry Look up or register the estimators available to the algorithm setting.
MetricRegistry Look up or register the metrics available to the metrics setting.

Building blocks

Use these when you need more control than the entry points give you, for example to run only the evaluation step or to build your own figures.

Object Purpose
MedpipeOrchestrator Reads the configuration, loads the data, builds the splits and manages run artifacts.
MedpipeClassifierRunner, MedpipeRegressorRunner Cross-validation and model fitting.
MedpipeClassifierEvaluator, MedpipeRegressorEvaluator Predictions, metrics and bootstrapped confidence intervals.
MedpipeClassifierDisplayer, MedpipeRegressorDisplayer Figures built from evaluation results.

Reference pages

  • Pipeline: entry points, orchestrator, runners and evaluators.
  • Configuration: the configuration schemas behind each section of the TOML file.
  • Data: preprocessing registry, label extraction and dataset splitting.
  • Models: the model registry.
  • Metrics: the available metrics and how to add your own.
  • Visualisation: displayers, plotting functions and themes.
  • Utils: bootstrapping, I/O, logging, reproducibility and validation.