Example of usage cv2.imread() in the darknet.py
| | |
| | | """ |
| | | #pylint: disable= C0321 |
| | | im = load_image(image, 0, 0) |
| | | #import cv2 |
| | | #custom_image = cv2.imread(image) # use: detect(,,imagePath,) |
| | | #import scipy.misc |
| | | #sci_image = scipy.misc.imread(image) |
| | | #im, arr = array_to_image(sci_image) # you should comment line below: free_image(im) |
| | | #custom_image = scipy.misc.imread(image) |
| | | #im, arr = array_to_image(custom_image) # you should comment line below: free_image(im) |
| | | if debug: print("Loaded image") |
| | | num = c_int(0) |
| | | if debug: print("Assigned num") |
| | |
| | | rem C:\Python27\Scripts\pip install numpy |
| | | rem C:\Python27\Scripts\pip install scikit-image |
| | | rem C:\Python27\Scripts\pip install scipy |
| | | rem C:\Python27\Scripts\pip install opencv-python |
| | | |
| | | C:\Python27\python.exe darknet.py |
| | | |
| | |
| | | rem C:\Users\Alex\AppData\Local\Programs\Python\Python36\Scripts\pip install numpy |
| | | rem C:\Users\Alex\AppData\Local\Programs\Python\Python36\Scripts\pip install scikit-image |
| | | rem C:\Users\Alex\AppData\Local\Programs\Python\Python36\Scripts\pip install scipy |
| | | rem C:\Users\Alex\AppData\Local\Programs\Python\Python36\Scripts\pip install opencv-python |
| | | |
| | | rem C:\Users\Alex\AppData\Local\Programs\Python\Python36\python.exe darknet.py |
| | | |
| | |
| | | """ |
| | | #pylint: disable= C0321 |
| | | im = load_image(image, 0, 0) |
| | | #import cv2 |
| | | #custom_image = cv2.imread(image) # use: detect(,,imagePath,) |
| | | #import scipy.misc |
| | | #sci_image = scipy.misc.imread(image) |
| | | #im, arr = array_to_image(sci_image) # you should comment line below: free_image(im) |
| | | #custom_image = scipy.misc.imread(image) |
| | | #im, arr = array_to_image(custom_image) # you should comment line below: free_image(im) |
| | | if debug: print("Loaded image") |
| | | num = c_int(0) |
| | | if debug: print("Assigned num") |