Merge b8b98e3ff8
into 856dde20ae
commit
f38dee41a9
|
@ -154,7 +154,8 @@ class Model:
|
|||
image: np.ndarray,
|
||||
caption: str,
|
||||
box_threshold: float = 0.35,
|
||||
text_threshold: float = 0.25
|
||||
text_threshold: float = 0.25,
|
||||
remove_combined: bool = False
|
||||
) -> Tuple[sv.Detections, List[str]]:
|
||||
"""
|
||||
import cv2
|
||||
|
@ -181,7 +182,8 @@ class Model:
|
|||
caption=caption,
|
||||
box_threshold=box_threshold,
|
||||
text_threshold=text_threshold,
|
||||
device=self.device)
|
||||
device=self.device,
|
||||
remove_combined=remove_combined)
|
||||
source_h, source_w, _ = image.shape
|
||||
detections = Model.post_process_result(
|
||||
source_h=source_h,
|
||||
|
@ -194,8 +196,9 @@ class Model:
|
|||
self,
|
||||
image: np.ndarray,
|
||||
classes: List[str],
|
||||
box_threshold: float,
|
||||
text_threshold: float
|
||||
box_threshold: float = 0.35,
|
||||
text_threshold: float = 0.25,
|
||||
remove_combined: bool = False
|
||||
) -> sv.Detections:
|
||||
"""
|
||||
import cv2
|
||||
|
@ -224,7 +227,8 @@ class Model:
|
|||
caption=caption,
|
||||
box_threshold=box_threshold,
|
||||
text_threshold=text_threshold,
|
||||
device=self.device)
|
||||
device=self.device,
|
||||
remove_combined=remove_combined)
|
||||
source_h, source_w, _ = image.shape
|
||||
detections = Model.post_process_result(
|
||||
source_h=source_h,
|
||||
|
|
Loading…
Reference in New Issue