get_keypoint_names

lightning_pose.utils.io.get_keypoint_names(cfg: DictConfig | ListConfig | None = None, csv_file: str | None = None, header_rows: list | None = [0, 1, 2]) list[str][source]

Return keypoint names from a label CSV file or from the config.

Parameters:
  • cfg – hydra config; used as a fallback when csv_file is not provided or does not exist.

  • csv_file – path to a labeled CSV file in DLC format; takes precedence over cfg.

  • header_rows – row indices in the CSV that form the MultiIndex header. Defaults to [0, 1, 2] (DLC format with scorer/bodypart/coords rows).

Returns:

List of keypoint name strings.