Add global settings.yaml in USER_CONFIG_DIR (#125)

This commit is contained in:
Glenn Jocher 2022-12-31 21:40:41 +01:00 committed by GitHub
parent a9b9fe7618
commit 598f17a472
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
16 changed files with 127 additions and 45 deletions

View file

@ -162,13 +162,15 @@ class Bboxes:
class Instances:
def __init__(self, bboxes, segments=[], keypoints=None, bbox_format="xywh", normalized=True) -> None:
def __init__(self, bboxes, segments=None, keypoints=None, bbox_format="xywh", normalized=True) -> None:
"""
Args:
bboxes (ndarray): bboxes with shape [N, 4].
segments (list | ndarray): segments.
keypoints (ndarray): keypoints with shape [N, 17, 2].
"""
if segments is None:
segments = []
self._bboxes = Bboxes(bboxes=bboxes, format=bbox_format)
self.keypoints = keypoints
self.normalized = normalized