OPFython

github.com/gugarosa/opfython AI for Education Open-source projectOpen source

A Python-inspired implementation of the Optimum-Path Forest classifier.

github.com/gugarosa/opfython
OPFython homepage screenshot

About OPFython

OPFython is a Python implementation of the Optimum-Path Forest family of classifiers, distributed as an open-source repository under the Apache License 2.0. It offers supervised, semi-supervised, unsupervised and KNN-supervised models, built on NumPy and Numba, and follows the LibOPF reference implementation. The package is installable with pip or UV and requires Python 3.11 or newer.

Key features

  • SupervisedOPF for complete-graph supervised classification
  • KNNSupervisedOPF using learned KNN adjacency
  • SemiSupervisedOPF learning from labeled and unlabeled samples
  • UnsupervisedOPF for density-based clustering and label propagation
  • 47 distance metrics, dataset loaders, splitters and LibOPF converters
  • Pre-computed distance matrices via pre_computed_distance constructor argument
Best for: Researchers, students and developers who need an open-source Python implementation of Optimum-Path Forest classifiers for experiments or coursework.
Good for
  • Open source under the Apache License 2.0
  • Cited in published research (Software Impacts, 2021) with a documented citation format
  • Accompanied by documentation, examples and application workflows
Watch out for
  • Requires Python 3.11 or newer
  • Labels must be zero-based and sequential
  • KNN models require 1

OPFython at a glance

Type
Open-source project
Pricing
Not confirmed. Check the site
Open source
Yes · Source code
Language
English
Last checked
Oct 6, 2026 · Online when checked
Listed
Oct 5, 2026

OPFython alternatives

Tools and sites you could use instead, ranked by how closely they match.

All 24 alternatives

Popular in AI for Education

Well-known listings from the same topic.

All 105

OPFython FAQ

What Python version does OPFython require?
Python 3.11 or newer.
How is OPFython installed?
With pip using python -m pip install opfython, by adding it to a UV-managed project with uv add opfython, or as an editable source checkout with python -m pip install -e .
What label format do the classifiers expect?
Labels must be zero-based and sequential; features, labels and optional sample indexes must also have matching sample counts, or a SizeError is raised.
Is something wrong or out of date?

Tell us and an editor will check it.

Own this website?

Claim the listing and suggest updates yourself. An editor checks every claim first.

Claim this listing