116 lines
2.6 KiB
Python
116 lines
2.6 KiB
Python
from collections.abc import Sequence
|
|
from typing import TypeAlias, overload
|
|
|
|
import numpy as np
|
|
import numpy.typing as npt
|
|
|
|
from ._core import (
|
|
AssociationReport,
|
|
AssociationStatus,
|
|
Camera,
|
|
CameraModel,
|
|
CoreProposalDebug,
|
|
FinalPoseAssociationDebug,
|
|
FullProposalDebug,
|
|
GroupingDebug,
|
|
MergeDebug,
|
|
PairCandidate,
|
|
PreviousPoseFilterDebug,
|
|
PreviousPoseMatch,
|
|
ProposalGroupDebug,
|
|
TriangulationConfig,
|
|
TriangulationOptions,
|
|
TriangulationResult,
|
|
TriangulationTrace,
|
|
)
|
|
from ._helpers import CameraLike, CameraModelLike, Matrix3x3Like, PoseViewLike, RoomParamsLike, VectorLike
|
|
|
|
PoseArray2D: TypeAlias = npt.NDArray[np.float32]
|
|
PoseArray3D: TypeAlias = npt.NDArray[np.float32]
|
|
PersonCountArray: TypeAlias = npt.NDArray[np.uint32]
|
|
TrackIdArray: TypeAlias = npt.NDArray[np.int64]
|
|
|
|
|
|
def convert_cameras(cameras: Sequence[CameraLike]) -> list[Camera]: ...
|
|
|
|
|
|
def make_camera(
|
|
name: str,
|
|
K: Matrix3x3Like,
|
|
DC: VectorLike,
|
|
R: Matrix3x3Like,
|
|
T: Sequence[Sequence[float]],
|
|
width: int,
|
|
height: int,
|
|
model: CameraModel | CameraModelLike,
|
|
) -> Camera: ...
|
|
|
|
|
|
def build_pair_candidates(
|
|
poses_2d: PoseArray2D,
|
|
person_counts: PersonCountArray,
|
|
) -> list[PairCandidate]: ...
|
|
|
|
|
|
def pack_poses_2d(
|
|
views: Sequence[PoseViewLike],
|
|
*,
|
|
joint_count: int | None = None,
|
|
) -> tuple[npt.NDArray[np.float32], npt.NDArray[np.uint32]]: ...
|
|
|
|
|
|
def make_triangulation_config(
|
|
cameras: Sequence[CameraLike],
|
|
roomparams: RoomParamsLike,
|
|
joint_names: Sequence[str],
|
|
*,
|
|
min_match_score: float = 0.95,
|
|
min_group_size: int = 1,
|
|
) -> TriangulationConfig: ...
|
|
|
|
|
|
def filter_pairs_with_previous_poses(
|
|
poses_2d: PoseArray2D,
|
|
person_counts: PersonCountArray,
|
|
config: TriangulationConfig,
|
|
previous_poses_3d: PoseArray3D,
|
|
previous_track_ids: TrackIdArray,
|
|
) -> PreviousPoseFilterDebug: ...
|
|
|
|
|
|
@overload
|
|
def triangulate_debug(
|
|
poses_2d: PoseArray2D,
|
|
person_counts: PersonCountArray,
|
|
config: TriangulationConfig,
|
|
) -> TriangulationTrace: ...
|
|
|
|
|
|
@overload
|
|
def triangulate_debug(
|
|
poses_2d: PoseArray2D,
|
|
person_counts: PersonCountArray,
|
|
config: TriangulationConfig,
|
|
previous_poses_3d: PoseArray3D,
|
|
previous_track_ids: TrackIdArray,
|
|
) -> TriangulationTrace: ...
|
|
|
|
|
|
def triangulate_poses(
|
|
poses_2d: PoseArray2D,
|
|
person_counts: PersonCountArray,
|
|
config: TriangulationConfig,
|
|
) -> PoseArray3D: ...
|
|
|
|
|
|
def triangulate_with_report(
|
|
poses_2d: PoseArray2D,
|
|
person_counts: PersonCountArray,
|
|
config: TriangulationConfig,
|
|
previous_poses_3d: PoseArray3D,
|
|
previous_track_ids: TrackIdArray,
|
|
) -> TriangulationResult: ...
|
|
|
|
|
|
__all__: list[str]
|