Fix type mismatch in ConfusionMatrix default parameter (#23138)

This commit is contained in:
Murat Raimbekov 2026-01-09 00:17:04 +06:00 committed by GitHub
parent 779b4319fa
commit cf29418918
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -315,7 +315,7 @@ class ConfusionMatrix(DataExportMixin):
matches (dict): Contains the indices of ground truths and predictions categorized into TP, FP and FN.
"""
def __init__(self, names: dict[int, str] = [], task: str = "detect", save_matches: bool = False):
def __init__(self, names: dict[int, str] = {}, task: str = "detect", save_matches: bool = False):
"""Initialize a ConfusionMatrix instance.
Args: