garmentiq.landmark
Garment landmark detection, refinement, and derivation.
Landmarks are the key points a measurement runs between, such as shoulders, sleeve ends, and hems. This module produces them in up to three steps:
detectpredicts the landmarks the pose model was trained on.refinesnaps those predictions onto the true garment boundary using a segmentation mask, correcting points that sit slightly off the edge.derivecomputes additional landmarks that the model does not predict at all, using geometric rules evaluated against the mask.
Refinement and derivation both require a segmentation mask.
1# garmentiq/landmark/__init__.py 2"""Garment landmark detection, refinement, and derivation. 3 4Landmarks are the key points a measurement runs between, such as shoulders, sleeve 5ends, and hems. This module produces them in up to three steps: 6 7- `detect` predicts the landmarks the pose model was trained on. 8- `refine` snaps those predictions onto the true garment boundary using a 9 segmentation mask, correcting points that sit slightly off the edge. 10- `derive` computes additional landmarks that the model does not predict at all, 11 using geometric rules evaluated against the mask. 12 13Refinement and derivation both require a segmentation mask. 14""" 15from .detect import detect 16from .detection import * 17from .derive import derive 18from .derivation import * 19from .refine import refine 20from .refinement import * 21from .plot import plot 22from .utils import ( 23 find_instruction_landmark_index, 24 fill_instruction_landmark_coordinate, 25)