I’m struggle with step :“for image_file in image_files:
detect_and_draw_box(image_file)”
How can I solve it, thank you!
I’m struggle with step :“for image_file in image_files:
detect_and_draw_box(image_file)”
How can I solve it, thank you!
hi @happeddy , the error message said “Could not establish connection.”
It means the library cannot connect to the internet to download the file.
Do you have any network connection during running it or do you have any proxy settings in place?
@tranvinhcuong can we place these files manually ?
hi @chopra1.raman, I think we can. But you need to read the source code to figure out where should you put the files.
For your reference, above is the source code for the detect_common_objects
function.
@tranvinhcuong can you please help me to get the exact path. Where I need to put these downloaded files.
according to code which you provided path : /home/jovyan/.cvlib/object_detection/yolo/yolov3
@tranvinhcuong thanks for the hint
If anyone using ubuntu and facing same issue then he/she can use below commands.
download all the required files from below commands in ubuntu
wget https://github.com/pjreddie/darknet/raw/master/cfg/yolov3-tiny.cfg
wget https://pjreddie.com/media/files/yolov3-tiny.weights
wget https://github.com/arunponnusamy/object-detection-opencv/raw/master/yolov3.txt
copy all these downloaded files in running container
docker cp yolov3_classes.txt container_id:/home/jovyan/.cvlib/object_detection/yolo/yolov3
docker cp yolov3-tiny.weights container_id:/home/jovyan/.cvlib/object_detection/yolo/yolov3
docker cp yolov3-tiny.cfg container_id:/home/jovyan/.cvlib/object_detection/yolo/yolov3
glad it helps and thank you for sharing your solution!