From c262f0528bbe581a4db8113f36ef3980226c98de Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=D0=9C=D0=B8=D1=85=D0=B0=D0=B8=D0=BB?= Date: Fri, 13 Sep 2024 16:14:07 +0300 Subject: [PATCH] Update mask.py fix Literal --- faster_coco_eval/core/mask.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/faster_coco_eval/core/mask.py b/faster_coco_eval/core/mask.py index 728f4d9..3f2b818 100644 --- a/faster_coco_eval/core/mask.py +++ b/faster_coco_eval/core/mask.py @@ -1,6 +1,6 @@ # Original work Copyright (c) Piotr Dollar and Tsung-Yi Lin, 2014. # Modified work Copyright (c) 2024 MiXaiLL76 -from typing import Dict, List, Literal, Union +from typing import Dict, List, Union import numpy as np @@ -70,7 +70,7 @@ def rleToBoundaryCV(rle: dict, dilation_ratio: float = 0.02) -> dict: def rleToBoundary( rle: dict, dilation_ratio: float = 0.02, - backend: Literal["mask_api", "opencv"] = "mask_api", + backend: str = "mask_api", ) -> dict: """Convert run-length encoding to boundary rle.