@@ -170,6 +170,7 @@ def submit_image_query(
170170 detector : Union [Detector , str ],
171171 image : Union [str , bytes , Image .Image , BytesIO , BufferedReader , np .ndarray ],
172172 wait : Optional [float ] = None ,
173+ human_review : Optional [bool ] = True ,
173174 ) -> ImageQuery :
174175 """Evaluates an image with Groundlight.
175176 :param detector: the Detector object, or string id of a detector like `det_12345`
@@ -182,14 +183,17 @@ def submit_image_query(
182183 Any binary format must be JPEG-encoded already. Any pixel format will get
183184 converted to JPEG at high quality before sending to service.
184185 :param wait: How long to wait (in seconds) for a confident answer.
186+ :param human_review: If set to False, do not escalate for human review
185187 """
186188 if wait is None :
187189 wait = self .DEFAULT_WAIT
188190 detector_id = detector .id if isinstance (detector , Detector ) else detector
189191
190192 image_bytesio : ByteStreamWrapper = parse_supported_image_types (image )
191193
192- raw_image_query = self .image_queries_api .submit_image_query (detector_id = detector_id , body = image_bytesio )
194+ raw_image_query = self .image_queries_api .submit_image_query (
195+ detector_id = detector_id , patience_time = wait , human_review = human_review , body = image_bytesio
196+ )
193197 image_query = ImageQuery .parse_obj (raw_image_query .to_dict ())
194198 if wait :
195199 threshold = self .get_detector (detector ).confidence_threshold
0 commit comments