from imageai.Detection.Custom import CustomObjectDetection detector = CustomObjectDetection() detector.setModelTypeAsYOLOv3() detector.setModelPath("roland_esl_3_440_ye/models/detection_model-ex-002--loss-0019.457.h5") detector.setJsonPath("roland_esl_3_440_ye/json/detection_config.json") detector.loadModel() detections = detector.detectObjectsFromImage(input_image="10120174_11.jpg", output_image_path="holo2-detected.jpg", minimum_percentage_probability=30) for detection in detections: print(detection["name"], ": ", detection["percentage_probability"], ": ", detection["box_points"])