Hacktoberfest 2026 : les issues que les mainteneurs ont marquées pour octobre, ouvertes et accessibles aux débutants. Parcourir les issues Hacktoberfest

Implement ilabel: fast pixel-based region labelling (from the MATLAB MVTB C extension)

Ouverte
#119 0 commentaires 0 réactions 0 personnes assignées Voir sur GitHub

Les mainteneurs répondent en général sous 1 jour

Personne n'a encore pris cette issue.

Évaluation

Difficulté
5/5
Temps estimé
Plus d'une semaine
Accessibilité débutants
25/100
Type d'issue
Fonctionnalité
Clarté
À clarifier
Activité
Active
Stack technique
c, python
Domaine
computer-vision

Piste de recherche

Start by inspecting wip/ilabel/ilabel.c and wip/ilabel/ilabel.py-unopt, then read the existing blob/label functions and the TODO in tests/test_image_processing.py. Decide and document the Python API and implementation route, with tests comparing shared examples to the contour-based blob code. Done means ilabel is implemented, its return values are tested, and the build and Python-only support implications are addressed.

Rédigé par le modèle d'indexation à partir du texte de l'issue.

Description

tech-debt

Parked work, to be implemented later. The files are on branch feat/fast-label under wip/ilabel/ (not in main).

What it is

A pixel-based, rather than contour-based, approach to segmentation / region labelling, based on the ilabel C extension (Copyright 1995-2009 Peter Corke) from the MATLAB Machine Vision Toolbox. The MATLAB signature was [l, m, parents, color] = ilabel(im).

What exists

  • wip/ilabel/ilabel.c: Cython 3.0.11 output (2024-12), 592 KB. It was generated from an ilabel.pyx that is not in the repo, but Cython embeds the source as /* "ilabel.pyx":NN */ comments, so the .pyx can be reconstructed from this file.
  • wip/ilabel/ilabel.py-unopt: unoptimised pure-Python port, produced with Copilot (2024-12).
  • The Python toolbox has no implementation. The only reference is a TODO in tests/test_image_processing.py (# TODO [l,ml,p,c] = ilabel(im);).

To do

  1. Reconstruct ilabel.pyx from the embedded comments in ilabel.c (or port afresh), and decide the implementation route (Cython extension vs numba vs NumPy/SciPy). Note this package is pure Python and builds with hatchling, so a compiled extension changes the build/wheel story (and Pyodide/JupyterLite support); a pure-Python/NumPy route avoids that.
  2. Define the Python API (Image method, return values), consistent with the existing blob/label functions.
  3. Tests, including a comparison with the existing contour-based blob code on shared examples, and the TODO above.

Related: #45

Langage dominant
Python
Étoiles
223
Forks
30
Merge moyen
1 h 4 min
PR mergées (30 j)
9

Préparer son environnement

  • Aucun Dockerfile ni fichier Docker Compose
  • Propose un modèle de pull request
  • Aucun guide de contribution

Par où commencer

  1. Lisez l'issue en entier, puis le guide de contribution du projet.
  2. Signalez en commentaire que vous la prenez — cela évite que deux personnes fassent le même travail.
  3. Forkez le dépôt et travaillez sur une branche.
  4. Ouvrez une pull request qui référence le numéro de l'issue.

Autres issues de petercorke/machinevision-toolbox-python

Toutes les issues de petercorke/machinevision-toolbox-python

Issues similaires

Plus d'issues Python

Recevez les nouvelles issues par e-mail

Un résumé court des issues GitHub adaptées aux débutants.