lightning_pose
lightning_pose.callbacks Module
Custom Lightning callbacks for training schedule, backbone unfreezing, and augmentation.
Functions
|
Build and return the list of training callbacks based on the config. |
Classes
Callback to change weight value during training. |
|
Callback that ramps up the backbone learning rate from 0 to upsampling_lr on unfreeze_epoch or unfreeze_step. |
|
Callback to apply curriculum patch masking during training. |
lightning_pose.metrics Module
Evaluation metrics for assessing pose estimation model quality.
CSV format conventions
- Labels CSV (DLC format, 3-row MultiIndex header: scorer / bodyparts / coords):
coord values are
x,y, and optionallyvisible.visibleencodes per-keypoint visibility: 2 = labeled, 1 = present but unlabeled in this dataset, 0 = keypoint does not belong to this dataset.Functions that consume labels filter coords to
x/ybefore any reshape, so CSVs with avisiblecolumn are handled transparently.
- Predictions CSV (same 3-row MultiIndex header):
coord values are
x,y,likelihood.An optional trailing column whose first MultiIndex level is
'set'signals that the file comes from a labeled dataset (not a video). Its presence setsis_video = False, which triggers pixel-error computation instead of temporal-norm computation incompute_metrics_single.get_keypoint_namesidentifies keypoints by finding columns whose coord level equals'x', so the'set'column is automatically excluded from the returned keypoint list.
Functions
|
Root mean square error between true and predicted keypoints. |
|
Norm of difference between keypoints on successive time bins. |
PCA reprojection error. |
|
PCA reprojection error. |
|
|
Compute various metrics on a predictions csv file from a single view. |
lightning_pose.train Module
Example model training function.
Functions
|
Train a model using the configuration |