nicetoolbox.evaluation.metrics.keypoint.BoneLength

class nicetoolbox.evaluation.metrics.keypoint.BoneLength(keypoints_mapping: Dict[str, Any])[source]

Bases: Metric

Calculates the bone lengths for each frame using 3D only keypoints.

Initializes the metric. Subclasses can use kwargs for specific setup.

Methods

compute

Compute the final metric from the stored state.

get_axis3

Get the bone names the metric is concerned with.

reset

Reset the metric's internal state.

update

Computes the bone lengths and stores them.

compute() Dict[Tuple[str, str, str], List[BatchResult] | AggregatedResult][source]

Compute the final metric from the stored state.

get_axis3() List[str][source]

Get the bone names the metric is concerned with.

reset() None[source]

Reset the metric’s internal state.

update(preds: torch.Tensor, gts: None, meta_chunk: ChunkWorkItem, meta_frames: List[FrameInfo]) None[source]

Computes the bone lengths and stores them.