Closed Haicaji closed 1 year ago
Try DetectCustomObjectsFromImage starting with a capital D
I looked at the code of the detectObjectsFromImage
function and found that it actually has the function of detectingCustomObjects FromImage
.
So we should change detectingCustomObjects FromImage
to detectObjectsFromImage
in the original code to run normally
When I tried Custom Object Detection,I encountered an error report:
AttributeError: 'ObjectDetection' object has no attribute 'detectCustomObjectsFromImage'
In this line of code:detections = detector.detectCustomObjectsFromImage(custom_objects=custom_objects, input_image=os.path.join(execution_path , "image3.jpg"), output_image_path=os.path.join(execution_path , "image3custom.jpg"), minimum_percentage_probability=30)
I can't find this function,detectCustomObjectsFromImage.What's more,I found a mistake in
custom_objects = detector.CustomObjects(car=True, motorcycle=True)
. 'motorcycle' should be 'motorbike'.Could you give me a hand? Thanks a lot.