Open LucyChen0228 opened 4 years ago
On the macOS you may try my fork at https://github.com/sowson/darknet I am afraid OpenCV 4 is not supported on any fork I know. thanks!
Hello, I downloaded opencv 2.4.13.7_6, but my error is the same as you. Do you have any solution to this yet?
On the macOS you may try my fork at https://github.com/sowson/darknet I am afraid OpenCV 4 is not supported on any fork I know. thanks!
sure i got this error:
mkdir -p obj
mkdir -p results
gcc -Iinclude/ -Isrc/ -DOPENCV pkg-config --cflags opencv
-DGPU -DOPENCL -DGPU_FAST -Wall -Wno-unknown-pragmas -Wno-unused-variable -Wno-unused-result -Wfatal-errors -fPIC -openmp -O2 -DOPENCV -DGPU -DOPENCL -I/usr/include/ -I/usr/local/cuda/include/ -DGPU_FAST -c ./src/gemm.c -o obj/gemm.o
Package opencv was not found in the pkg-config search path.
Perhaps you should add the directory containing `opencv.pc'
to the PKG_CONFIG_PATH environment variable
No package 'opencv' found
In file included from ./src/gemm.c:2:
In file included from src/utils.h:5:
include/darknet.h:17:14: fatal error: 'opencv2/highgui/highgui_c.h' file not found
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
1 error generated. make: *** [obj/gemm.o] Error 1
/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
brew install opencv@2 brew link –force opencv@2
brew install opencv@3 brew link –force opencv@3
brew install libomp brew install clblas brew install clfft brew install cmake brew install wget
mkdir github; cd github; git clone https://github.com/sowson/darknet.git
cd darknet; mkdir build; cmake -Bbuild -H.; cd build; make; cd ..; cp build/darknet .; rm -r build
FROM: https://iblog.isowa.io/2018/05/26/darknet-training/
Thanks!
/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
OpenCV2
brew install opencv@2 brew link –force opencv@2
OpenCV3 (if you do not want OpenCV2)
brew install opencv@3 brew link –force opencv@3
brew install libomp brew install clblas brew install clfft brew install cmake brew install wget
mkdir github; cd github; git clone https://github.com/sowson/darknet.git
cd darknet; mkdir build; cmake -Bbuild -H.; cd build; make; cd ..; cp build/darknet .; rm -r build
FROM: https://iblog.isowa.io/2018/05/26/darknet-training/
Thanks!
Yay! It worked. Thx so much!!
But when running a detect task, this error happens:
$ ./darknet detect cfg/yolov3.cfg weights/yolov3.weights data/dog.jpg
Device IDs: 1 Device ID: 0 Device name: Intel(R) UHD Graphics 617 Device vendor: Intel Inc. Device opencl availability: OpenCL 1.2 Device opencl used: 1.2(May 26 2020 20:51:24) Device double precision: NO Device max group size: 256 Device address bits: 64 layer filters size input output 0 conv 32 3 x 3 / 1 608 x 608 x 3 -> 608 x 608 x 32 0.639 BFLOPs 1 conv 64 3 x 3 / 2 608 x 608 x 32 -> 304 x 304 x 64 3.407 BFLOPs 2 conv 32 1 x 1 / 1 304 x 304 x 64 -> 304 x 304 x 32 0.379 BFLOPs 3 conv 64 3 x 3 / 1 304 x 304 x 32 -> 304 x 304 x 64 3.407 BFLOPs 4 res 1 304 x 304 x 64 -> 304 x 304 x 64 5 conv 128 3 x 3 / 2 304 x 304 x 64 -> 152 x 152 x 128 3.407 BFLOPs 6 conv 64 1 x 1 / 1 152 x 152 x 128 -> 152 x 152 x 64 0.379 BFLOPs 7 conv 128 3 x 3 / 1 152 x 152 x 64 -> 152 x 152 x 128 3.407 BFLOPs 8 res 5 152 x 152 x 128 -> 152 x 152 x 128 9 conv 64 1 x 1 / 1 152 x 152 x 128 -> 152 x 152 x 64 0.379 BFLOPs 10 conv 128 3 x 3 / 1 152 x 152 x 64 -> 152 x 152 x 128 3.407 BFLOPs 11 res 8 152 x 152 x 128 -> 152 x 152 x 128 12 conv 256 3 x 3 / 2 152 x 152 x 128 -> 76 x 76 x 256 3.407 BFLOPs 13 conv 128 1 x 1 / 1 76 x 76 x 256 -> 76 x 76 x 128 0.379 BFLOPs 14 conv 256 3 x 3 / 1 76 x 76 x 128 -> 76 x 76 x 256 3.407 BFLOPs 15 res 12 76 x 76 x 256 -> 76 x 76 x 256 16 conv 128 1 x 1 / 1 76 x 76 x 256 -> 76 x 76 x 128 0.379 BFLOPs 17 conv 256 3 x 3 / 1 76 x 76 x 128 -> 76 x 76 x 256 3.407 BFLOPs 18 res 15 76 x 76 x 256 -> 76 x 76 x 256 19 conv 128 1 x 1 / 1 76 x 76 x 256 -> 76 x 76 x 128 0.379 BFLOPs 20 conv 256 3 x 3 / 1 76 x 76 x 128 -> 76 x 76 x 256 3.407 BFLOPs 21 res 18 76 x 76 x 256 -> 76 x 76 x 256 22 conv 128 1 x 1 / 1 76 x 76 x 256 -> 76 x 76 x 128 0.379 BFLOPs 23 conv 256 3 x 3 / 1 76 x 76 x 128 -> 76 x 76 x 256 3.407 BFLOPs 24 res 21 76 x 76 x 256 -> 76 x 76 x 256 25 conv 128 1 x 1 / 1 76 x 76 x 256 -> 76 x 76 x 128 0.379 BFLOPs 26 conv 256 3 x 3 / 1 76 x 76 x 128 -> 76 x 76 x 256 3.407 BFLOPs 27 res 24 76 x 76 x 256 -> 76 x 76 x 256 28 conv 128 1 x 1 / 1 76 x 76 x 256 -> 76 x 76 x 128 0.379 BFLOPs 29 conv 256 3 x 3 / 1 76 x 76 x 128 -> 76 x 76 x 256 3.407 BFLOPs 30 res 27 76 x 76 x 256 -> 76 x 76 x 256 31 conv 128 1 x 1 / 1 76 x 76 x 256 -> 76 x 76 x 128 0.379 BFLOPs 32 conv 256 3 x 3 / 1 76 x 76 x 128 -> 76 x 76 x 256 3.407 BFLOPs 33 res 30 76 x 76 x 256 -> 76 x 76 x 256 34 conv 128 1 x 1 / 1 76 x 76 x 256 -> 76 x 76 x 128 0.379 BFLOPs 35 conv 256 3 x 3 / 1 76 x 76 x 128 -> 76 x 76 x 256 3.407 BFLOPs 36 res 33 76 x 76 x 256 -> 76 x 76 x 256 37 conv 512 3 x 3 / 2 76 x 76 x 256 -> 38 x 38 x 512 3.407 BFLOPs 38 conv 256 1 x 1 / 1 38 x 38 x 512 -> 38 x 38 x 256 0.379 BFLOPs 39 conv 512 3 x 3 / 1 38 x 38 x 256 -> 38 x 38 x 512 3.407 BFLOPs 40 res 37 38 x 38 x 512 -> 38 x 38 x 512 41 conv 256 1 x 1 / 1 38 x 38 x 512 -> 38 x 38 x 256 0.379 BFLOPs 42 conv 512 3 x 3 / 1 38 x 38 x 256 -> 38 x 38 x 512 3.407 BFLOPs 43 res 40 38 x 38 x 512 -> 38 x 38 x 512 44 conv 256 1 x 1 / 1 38 x 38 x 512 -> 38 x 38 x 256 0.379 BFLOPs 45 conv 512 3 x 3 / 1 38 x 38 x 256 -> 38 x 38 x 512 3.407 BFLOPs 46 res 43 38 x 38 x 512 -> 38 x 38 x 512 47 conv 256 1 x 1 / 1 38 x 38 x 512 -> 38 x 38 x 256 0.379 BFLOPs 48 conv 512 3 x 3 / 1 38 x 38 x 256 -> 38 x 38 x 512 3.407 BFLOPs 49 res 46 38 x 38 x 512 -> 38 x 38 x 512 50 conv 256 1 x 1 / 1 38 x 38 x 512 -> 38 x 38 x 256 0.379 BFLOPs 51 conv 512 3 x 3 / 1 38 x 38 x 256 -> 38 x 38 x 512 3.407 BFLOPs 52 res 49 38 x 38 x 512 -> 38 x 38 x 512 53 conv 256 1 x 1 / 1 38 x 38 x 512 -> 38 x 38 x 256 0.379 BFLOPs 54 conv 512 3 x 3 / 1 38 x 38 x 256 -> 38 x 38 x 512 3.407 BFLOPs 55 res 52 38 x 38 x 512 -> 38 x 38 x 512 56 conv 256 1 x 1 / 1 38 x 38 x 512 -> 38 x 38 x 256 0.379 BFLOPs 57 conv 512 3 x 3 / 1 38 x 38 x 256 -> 38 x 38 x 512 3.407 BFLOPs 58 res 55 38 x 38 x 512 -> 38 x 38 x 512 59 conv 256 1 x 1 / 1 38 x 38 x 512 -> 38 x 38 x 256 0.379 BFLOPs 60 conv 512 3 x 3 / 1 38 x 38 x 256 -> 38 x 38 x 512 3.407 BFLOPs 61 res 58 38 x 38 x 512 -> 38 x 38 x 512 62 conv 1024 3 x 3 / 2 38 x 38 x 512 -> 19 x 19 x1024 3.407 BFLOPs 63 conv 512 1 x 1 / 1 19 x 19 x1024 -> 19 x 19 x 512 0.379 BFLOPs 64 conv 1024 3 x 3 / 1 19 x 19 x 512 -> 19 x 19 x1024 3.407 BFLOPs 65 res 62 19 x 19 x1024 -> 19 x 19 x1024 66 conv 512 1 x 1 / 1 19 x 19 x1024 -> 19 x 19 x 512 0.379 BFLOPs 67 conv 1024 3 x 3 / 1 19 x 19 x 512 -> 19 x 19 x1024 3.407 BFLOPs 68 res 65 19 x 19 x1024 -> 19 x 19 x1024 69 conv 512 1 x 1 / 1 19 x 19 x1024 -> 19 x 19 x 512 0.379 BFLOPs 70 conv 1024 3 x 3 / 1 19 x 19 x 512 -> 19 x 19 x1024 3.407 BFLOPs 71 res 68 19 x 19 x1024 -> 19 x 19 x1024 72 conv 512 1 x 1 / 1 19 x 19 x1024 -> 19 x 19 x 512 0.379 BFLOPs 73 conv 1024 3 x 3 / 1 19 x 19 x 512 -> 19 x 19 x1024 3.407 BFLOPs 74 res 71 19 x 19 x1024 -> 19 x 19 x1024 75 conv 512 1 x 1 / 1 19 x 19 x1024 -> 19 x 19 x 512 0.379 BFLOPs 76 conv 1024 3 x 3 / 1 19 x 19 x 512 -> 19 x 19 x1024 3.407 BFLOPs 77 conv 512 1 x 1 / 1 19 x 19 x1024 -> 19 x 19 x 512 0.379 BFLOPs 78 conv 1024 3 x 3 / 1 19 x 19 x 512 -> 19 x 19 x1024 3.407 BFLOPs 79 conv 512 1 x 1 / 1 19 x 19 x1024 -> 19 x 19 x 512 0.379 BFLOPs 80 conv 1024 3 x 3 / 1 19 x 19 x 512 -> 19 x 19 x1024 3.407 BFLOPs 81 conv 255 1 x 1 / 1 19 x 19 x1024 -> 19 x 19 x 255 0.189 BFLOPs 82 yolo 83 route 79 84 conv 256 1 x 1 / 1 19 x 19 x 512 -> 19 x 19 x 256 0.095 BFLOPs 85 upsample 2x 19 x 19 x 256 -> 38 x 38 x 256 86 route 85 61 87 conv 256 1 x 1 / 1 38 x 38 x 768 -> 38 x 38 x 256 0.568 BFLOPs 88 conv 512 3 x 3 / 1 38 x 38 x 256 -> 38 x 38 x 512 3.407 BFLOPs 89 conv 256 1 x 1 / 1 38 x 38 x 512 -> 38 x 38 x 256 0.379 BFLOPs 90 conv 512 3 x 3 / 1 38 x 38 x 256 -> 38 x 38 x 512 3.407 BFLOPs 91 conv 256 1 x 1 / 1 38 x 38 x 512 -> 38 x 38 x 256 0.379 BFLOPs 92 conv 512 3 x 3 / 1 38 x 38 x 256 -> 38 x 38 x 512 3.407 BFLOPs 93 conv 255 1 x 1 / 1 38 x 38 x 512 -> 38 x 38 x 255 0.377 BFLOPs 94 yolo 95 route 91 96 conv 128 1 x 1 / 1 38 x 38 x 256 -> 38 x 38 x 128 0.095 BFLOPs 97 upsample 2x 38 x 38 x 128 -> 76 x 76 x 128 98 route 97 36 99 conv 128 1 x 1 / 1 76 x 76 x 384 -> 76 x 76 x 128 0.568 BFLOPs 100 conv 256 3 x 3 / 1 76 x 76 x 128 -> 76 x 76 x 256 3.407 BFLOPs 101 conv 128 1 x 1 / 1 76 x 76 x 256 -> 76 x 76 x 128 0.379 BFLOPs 102 conv 256 3 x 3 / 1 76 x 76 x 128 -> 76 x 76 x 256 3.407 BFLOPs 103 conv 128 1 x 1 / 1 76 x 76 x 256 -> 76 x 76 x 128 0.379 BFLOPs 104 conv 256 3 x 3 / 1 76 x 76 x 128 -> 76 x 76 x 256 3.407 BFLOPs 105 conv 255 1 x 1 / 1 76 x 76 x 256 -> 76 x 76 x 255 0.754 BFLOPs 106 yolo Loading weights from weights/yolov3.weights...Done! data/dog.jpg: Predicted in 4.825347 seconds. libc++abi.dylib: terminating with uncaught exception of type cv::Exception: OpenCV(3.4.10) /tmp/opencv@3-20200531-50368-18xulee/opencv-3.4.10/modules/core/src/matrix_wrap.cpp:801: error: (-215:Assertion failed) (flags & FIXED_TYPE) != 0 in function 'type'
[1] 82461 abort ./darknet detect cfg/yolov3.cfg weights/yolov3.weights data/dog.jpg
For me (I am still on OpenCL v2) /Users/piotr/github/sowson/darknet/cmake-build-debug/darknet detect cfg/yolov3.cfg ../../../weights/yolov3.weights data/dog.jpg Device IDs: 3 Device ID: 0 Device name: Intel(R) UHD Graphics 630 Device vendor: Intel Inc. Device opencl availability: OpenCL 1.2 Device opencl used: 1.2(May 26 2020 20:51:24) Device double precision: NO Device max group size: 256 Device address bits: 64 layer filters size input output 0 conv 32 3 x 3 / 1 608 x 608 x 3 -> 608 x 608 x 32 0.639 BFLOPs 1 conv 64 3 x 3 / 2 608 x 608 x 32 -> 304 x 304 x 64 3.407 BFLOPs 2 conv 32 1 x 1 / 1 304 x 304 x 64 -> 304 x 304 x 32 0.379 BFLOPs 3 conv 64 3 x 3 / 1 304 x 304 x 32 -> 304 x 304 x 64 3.407 BFLOPs 4 res 1 304 x 304 x 64 -> 304 x 304 x 64 5 conv 128 3 x 3 / 2 304 x 304 x 64 -> 152 x 152 x 128 3.407 BFLOPs 6 conv 64 1 x 1 / 1 152 x 152 x 128 -> 152 x 152 x 64 0.379 BFLOPs 7 conv 128 3 x 3 / 1 152 x 152 x 64 -> 152 x 152 x 128 3.407 BFLOPs 8 res 5 152 x 152 x 128 -> 152 x 152 x 128 9 conv 64 1 x 1 / 1 152 x 152 x 128 -> 152 x 152 x 64 0.379 BFLOPs 10 conv 128 3 x 3 / 1 152 x 152 x 64 -> 152 x 152 x 128 3.407 BFLOPs 11 res 8 152 x 152 x 128 -> 152 x 152 x 128 12 conv 256 3 x 3 / 2 152 x 152 x 128 -> 76 x 76 x 256 3.407 BFLOPs 13 conv 128 1 x 1 / 1 76 x 76 x 256 -> 76 x 76 x 128 0.379 BFLOPs 14 conv 256 3 x 3 / 1 76 x 76 x 128 -> 76 x 76 x 256 3.407 BFLOPs 15 res 12 76 x 76 x 256 -> 76 x 76 x 256 16 conv 128 1 x 1 / 1 76 x 76 x 256 -> 76 x 76 x 128 0.379 BFLOPs 17 conv 256 3 x 3 / 1 76 x 76 x 128 -> 76 x 76 x 256 3.407 BFLOPs 18 res 15 76 x 76 x 256 -> 76 x 76 x 256 19 conv 128 1 x 1 / 1 76 x 76 x 256 -> 76 x 76 x 128 0.379 BFLOPs 20 conv 256 3 x 3 / 1 76 x 76 x 128 -> 76 x 76 x 256 3.407 BFLOPs 21 res 18 76 x 76 x 256 -> 76 x 76 x 256 22 conv 128 1 x 1 / 1 76 x 76 x 256 -> 76 x 76 x 128 0.379 BFLOPs 23 conv 256 3 x 3 / 1 76 x 76 x 128 -> 76 x 76 x 256 3.407 BFLOPs 24 res 21 76 x 76 x 256 -> 76 x 76 x 256 25 conv 128 1 x 1 / 1 76 x 76 x 256 -> 76 x 76 x 128 0.379 BFLOPs 26 conv 256 3 x 3 / 1 76 x 76 x 128 -> 76 x 76 x 256 3.407 BFLOPs 27 res 24 76 x 76 x 256 -> 76 x 76 x 256 28 conv 128 1 x 1 / 1 76 x 76 x 256 -> 76 x 76 x 128 0.379 BFLOPs 29 conv 256 3 x 3 / 1 76 x 76 x 128 -> 76 x 76 x 256 3.407 BFLOPs 30 res 27 76 x 76 x 256 -> 76 x 76 x 256 31 conv 128 1 x 1 / 1 76 x 76 x 256 -> 76 x 76 x 128 0.379 BFLOPs 32 conv 256 3 x 3 / 1 76 x 76 x 128 -> 76 x 76 x 256 3.407 BFLOPs 33 res 30 76 x 76 x 256 -> 76 x 76 x 256 34 conv 128 1 x 1 / 1 76 x 76 x 256 -> 76 x 76 x 128 0.379 BFLOPs 35 conv 256 3 x 3 / 1 76 x 76 x 128 -> 76 x 76 x 256 3.407 BFLOPs 36 res 33 76 x 76 x 256 -> 76 x 76 x 256 37 conv 512 3 x 3 / 2 76 x 76 x 256 -> 38 x 38 x 512 3.407 BFLOPs 38 conv 256 1 x 1 / 1 38 x 38 x 512 -> 38 x 38 x 256 0.379 BFLOPs 39 conv 512 3 x 3 / 1 38 x 38 x 256 -> 38 x 38 x 512 3.407 BFLOPs 40 res 37 38 x 38 x 512 -> 38 x 38 x 512 41 conv 256 1 x 1 / 1 38 x 38 x 512 -> 38 x 38 x 256 0.379 BFLOPs 42 conv 512 3 x 3 / 1 38 x 38 x 256 -> 38 x 38 x 512 3.407 BFLOPs 43 res 40 38 x 38 x 512 -> 38 x 38 x 512 44 conv 256 1 x 1 / 1 38 x 38 x 512 -> 38 x 38 x 256 0.379 BFLOPs 45 conv 512 3 x 3 / 1 38 x 38 x 256 -> 38 x 38 x 512 3.407 BFLOPs 46 res 43 38 x 38 x 512 -> 38 x 38 x 512 47 conv 256 1 x 1 / 1 38 x 38 x 512 -> 38 x 38 x 256 0.379 BFLOPs 48 conv 512 3 x 3 / 1 38 x 38 x 256 -> 38 x 38 x 512 3.407 BFLOPs 49 res 46 38 x 38 x 512 -> 38 x 38 x 512 50 conv 256 1 x 1 / 1 38 x 38 x 512 -> 38 x 38 x 256 0.379 BFLOPs 51 conv 512 3 x 3 / 1 38 x 38 x 256 -> 38 x 38 x 512 3.407 BFLOPs 52 res 49 38 x 38 x 512 -> 38 x 38 x 512 53 conv 256 1 x 1 / 1 38 x 38 x 512 -> 38 x 38 x 256 0.379 BFLOPs 54 conv 512 3 x 3 / 1 38 x 38 x 256 -> 38 x 38 x 512 3.407 BFLOPs 55 res 52 38 x 38 x 512 -> 38 x 38 x 512 56 conv 256 1 x 1 / 1 38 x 38 x 512 -> 38 x 38 x 256 0.379 BFLOPs 57 conv 512 3 x 3 / 1 38 x 38 x 256 -> 38 x 38 x 512 3.407 BFLOPs 58 res 55 38 x 38 x 512 -> 38 x 38 x 512 59 conv 256 1 x 1 / 1 38 x 38 x 512 -> 38 x 38 x 256 0.379 BFLOPs 60 conv 512 3 x 3 / 1 38 x 38 x 256 -> 38 x 38 x 512 3.407 BFLOPs 61 res 58 38 x 38 x 512 -> 38 x 38 x 512 62 conv 1024 3 x 3 / 2 38 x 38 x 512 -> 19 x 19 x1024 3.407 BFLOPs 63 conv 512 1 x 1 / 1 19 x 19 x1024 -> 19 x 19 x 512 0.379 BFLOPs 64 conv 1024 3 x 3 / 1 19 x 19 x 512 -> 19 x 19 x1024 3.407 BFLOPs 65 res 62 19 x 19 x1024 -> 19 x 19 x1024 66 conv 512 1 x 1 / 1 19 x 19 x1024 -> 19 x 19 x 512 0.379 BFLOPs 67 conv 1024 3 x 3 / 1 19 x 19 x 512 -> 19 x 19 x1024 3.407 BFLOPs 68 res 65 19 x 19 x1024 -> 19 x 19 x1024 69 conv 512 1 x 1 / 1 19 x 19 x1024 -> 19 x 19 x 512 0.379 BFLOPs 70 conv 1024 3 x 3 / 1 19 x 19 x 512 -> 19 x 19 x1024 3.407 BFLOPs 71 res 68 19 x 19 x1024 -> 19 x 19 x1024 72 conv 512 1 x 1 / 1 19 x 19 x1024 -> 19 x 19 x 512 0.379 BFLOPs 73 conv 1024 3 x 3 / 1 19 x 19 x 512 -> 19 x 19 x1024 3.407 BFLOPs 74 res 71 19 x 19 x1024 -> 19 x 19 x1024 75 conv 512 1 x 1 / 1 19 x 19 x1024 -> 19 x 19 x 512 0.379 BFLOPs 76 conv 1024 3 x 3 / 1 19 x 19 x 512 -> 19 x 19 x1024 3.407 BFLOPs 77 conv 512 1 x 1 / 1 19 x 19 x1024 -> 19 x 19 x 512 0.379 BFLOPs 78 conv 1024 3 x 3 / 1 19 x 19 x 512 -> 19 x 19 x1024 3.407 BFLOPs 79 conv 512 1 x 1 / 1 19 x 19 x1024 -> 19 x 19 x 512 0.379 BFLOPs 80 conv 1024 3 x 3 / 1 19 x 19 x 512 -> 19 x 19 x1024 3.407 BFLOPs 81 conv 255 1 x 1 / 1 19 x 19 x1024 -> 19 x 19 x 255 0.189 BFLOPs 82 yolo 83 route 79 84 conv 256 1 x 1 / 1 19 x 19 x 512 -> 19 x 19 x 256 0.095 BFLOPs 85 upsample 2x 19 x 19 x 256 -> 38 x 38 x 256 86 route 85 61 87 conv 256 1 x 1 / 1 38 x 38 x 768 -> 38 x 38 x 256 0.568 BFLOPs 88 conv 512 3 x 3 / 1 38 x 38 x 256 -> 38 x 38 x 512 3.407 BFLOPs 89 conv 256 1 x 1 / 1 38 x 38 x 512 -> 38 x 38 x 256 0.379 BFLOPs 90 conv 512 3 x 3 / 1 38 x 38 x 256 -> 38 x 38 x 512 3.407 BFLOPs 91 conv 256 1 x 1 / 1 38 x 38 x 512 -> 38 x 38 x 256 0.379 BFLOPs 92 conv 512 3 x 3 / 1 38 x 38 x 256 -> 38 x 38 x 512 3.407 BFLOPs 93 conv 255 1 x 1 / 1 38 x 38 x 512 -> 38 x 38 x 255 0.377 BFLOPs 94 yolo 95 route 91 96 conv 128 1 x 1 / 1 38 x 38 x 256 -> 38 x 38 x 128 0.095 BFLOPs 97 upsample 2x 38 x 38 x 128 -> 76 x 76 x 128 98 route 97 36 99 conv 128 1 x 1 / 1 76 x 76 x 384 -> 76 x 76 x 128 0.568 BFLOPs 100 conv 256 3 x 3 / 1 76 x 76 x 128 -> 76 x 76 x 256 3.407 BFLOPs 101 conv 128 1 x 1 / 1 76 x 76 x 256 -> 76 x 76 x 128 0.379 BFLOPs 102 conv 256 3 x 3 / 1 76 x 76 x 128 -> 76 x 76 x 256 3.407 BFLOPs 103 conv 128 1 x 1 / 1 76 x 76 x 256 -> 76 x 76 x 128 0.379 BFLOPs 104 conv 256 3 x 3 / 1 76 x 76 x 128 -> 76 x 76 x 256 3.407 BFLOPs 105 conv 255 1 x 1 / 1 76 x 76 x 256 -> 76 x 76 x 255 0.754 BFLOPs 106 yolo Loading weights from ../../../weights/yolov3.weights...Done! data/dog.jpg: Predicted in 6.740298 seconds.
Process finished with exit code 0
IMAGE
There is one more thing. Usually newer like OpenCV v4 or v3 it not means better. Once in darknet usage of OpenCV is very limited. So v2 for me is very stable and I am using it. 99% is on GPU acceleration no it OpenCV itself.
For sure, I agree with you. The solution for me was to run OpenCV3 with YOLOv3 through DNN module running on CUDA backend.
I see, just wonder if on the latest macOS, but I understand your sarcasm... enjoy then the CUDA and your power bills :P. I prefer my 2x AMD Radeon VII and wonder about the new AMD Radeon Pro VII... In my case, 90% load consumes ~400W only, not like my 2x Titans RTX with 800W and 90 Celcius degree each, it is like an oven in the workstation case... but again good for you! Cheers!
It wasn't sarcasm, I'm evaluating all possibilities and as you showed above, it could be a new possibility for me, once can I have gains in terms of performance and on my power bill. :)
is there someone have the following problems? thx ./darknet detector test cfg/coco.data cfg/yolov4-tiny.cfg weights/yolov4-tiny.weights data/dog.jpg
37 yolo Unused field: 'scale_x_y = 1.05' Unused field: 'cls_normalizer = 1.0' Unused field: 'iou_normalizer = 0.07' Unused field: 'iou_loss = ciou' Unused field: 'resize = 1.5' Unused field: 'nms_kind = greedynms' Unused field: 'beta_nms = 0.6' Loading weights from weights/yolov4-tiny.weights...done! Assertion failed: (n == x_gpu.len && x && x_gpu.ptr && x && n), function opencl_push_array, file /Users/frank/soft_learn/c_plus_plus_code/darknet/src/opencl.c, line 784. [1] 39521 abort ./darknet detector test cfg/coco.data cfg/yolov4-tiny.cfg data/dog.jpg
/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
OpenCV2
brew install opencv@2 brew link –force opencv@2
OpenCV3 (if you do not want OpenCV2)
brew install opencv@3 brew link –force opencv@3
brew install libomp brew install clblas brew install clfft brew install cmake brew install wget
mkdir github; cd github; git clone https://github.com/sowson/darknet.git
cd darknet; mkdir build; cmake -Bbuild -H.; cd build; make; cd ..; cp build/darknet .; rm -r build
FROM: https://iblog.isowa.io/2018/05/26/darknet-training/
Thanks!
i follow the solutions, thx, but i have the following problems>
is there someone have the following problems? thx ./darknet detector test cfg/coco.data cfg/yolov4-tiny.cfg weights/yolov4-tiny.weights data/dog.jpg
37 yolo Unused field: 'scale_x_y = 1.05' Unused field: 'cls_normalizer = 1.0' Unused field: 'iou_normalizer = 0.07' Unused field: 'iou_loss = ciou' Unused field: 'resize = 1.5' Unused field: 'nms_kind = greedynms' Unused field: 'beta_nms = 0.6' Loading weights from weights/yolov4-tiny.weights...done! Assertion failed: (n == x_gpu.len && x && x_gpu.ptr && x && n), function opencl_push_array, file /Users/frank/soft_learn/c_plus_plus_code/darknet/src/opencl.c, line 784. [1] 39521 abort ./darknet detector test cfg/coco.data cfg/yolov4-tiny.cfg data/dog.jpg
/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
OpenCV2
brew install opencv@2 brew link –force opencv@2
OpenCV3 (if you do not want OpenCV2)
brew install opencv@3 brew link –force opencv@3 brew install libomp brew install clblas brew install clfft brew install cmake brew install wget mkdir github; cd github; git clone https://github.com/sowson/darknet.git cd darknet; mkdir build; cmake -Bbuild -H.; cd build; make; cd ..; cp build/darknet .; rm -r build FROM: https://iblog.isowa.io/2018/05/26/darknet-training/ Thanks!
i follow the solutions, thx, but i have the following problems>
is there someone have the following problems? thx ./darknet detector test cfg/coco.data cfg/yolov4-tiny.cfg weights/yolov4-tiny.weights data/dog.jpg
37 yolo Unused field: 'scale_x_y = 1.05' Unused field: 'cls_normalizer = 1.0' Unused field: 'iou_normalizer = 0.07' Unused field: 'iou_loss = ciou' Unused field: 'resize = 1.5' Unused field: 'nms_kind = greedynms' Unused field: 'beta_nms = 0.6' Loading weights from weights/yolov4-tiny.weights...done! Assertion failed: (n == x_gpu.len && x && x_gpu.ptr && x && n), function opencl_push_array, file /Users/frank/soft_learn/c_plus_plus_code/darknet/src/opencl.c, line 784. [1] 39521 abort ./darknet detector test cfg/coco.data cfg/yolov4-tiny.cfg data/dog.jpg
Hi! Have you found a solution to your problem?
Hi, take a look at https://github.com/sowson/darknet-vNext there is OpenCV4 support implemented. Thanks!
OpenCV has already been set up in my laptop. (4.2.0.32)
Mac OS: 10.14.5
After darknet has been successfully set up in my laptop, I changed opencv =1 in makefile. Here is the error:
/bin/sh: pkg-config: command not found ./src/image_opencv.cpp:5:10: fatal error: 'opencv2/opencv.hpp' file not found
include "opencv2/opencv.hpp"
1 error generated. make: *** [obj/image_opencv.o] Error 1