This repository provides a compiled version of MS-DAYOLO for Windows 10, based on the original project:
GitHub - Mazin-Hnewa/MS-DAYOLO
Here's something must install, please follow Preparation Steps:
- Visual Studio 2017 or 2019 (for CUDA Toolkit 10.1 installation)
- Windows 10
- OpenCV 4.9
- CUDA Toolkit 10.1
- cuDNN 7.6.5 (compatible with CUDA 10.1)
Download and install Visual Studio 2017 or 2019 with the Desktop Development with C++ workload.
👉 Visual Studio 2019 Release Notes
Download and install CUDA Toolkit 10.1 from the CUDA Toolkit Archive.
Note: Make sure Visual Studio is installed first.
Add the following system environment variables:
System Variable | Value |
---|---|
CUDA_PATH |
C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v10.1 |
CUDA_PATH_V10_1 |
C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v10.1 |
Update the Path
environment variable by adding these entries:
Path |
---|
C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v10.1\bin |
C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v10.1\libnvvp |
Open a Command Prompt and run the following command to verify the installation:
nvcc --version
You should see output similar to this:
Download cuDNN 7.6.5 for CUDA 10.1 from the cuDNN Archive.
After extraction, you should see files like this:
Copy the files to their respective directories in your CUDA installation path (C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v10.1
):
cuDNN File | Target Directory |
---|---|
bin\cudnn64_7.dll |
C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v10.1\bin |
include\cudnn.h |
C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v10.1\include |
lib\x64\cudnn.lib |
C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v10.1\lib\x64 |
Download OpenCV 4.9 from the OpenCV Releases page.
Run the .exe
and extract the files to C:\opencv
.
Add the following system environment variable:
System Variable | Value |
---|---|
OpenCV_DIR |
C:\opencv\build |
Copy the following files to build\darknet\x64
:
File | Source Directory |
---|---|
opencv_world490d.dll |
C:\opencv\build\x64\vc16\bin |
opencv_world490.dll |
C:\opencv\build\x64\vc16\bin |
opencv_videoio_ffmpeg490_64.dll |
C:\opencv\build\x64\vc16\bin |
Copy cudnn64_7.dll
to build\darknet\x64
.
-
YOLOv4 Weights:
Downloadyolov4.conv.137
from YOLOv4 Weights and place it inbuild\darknet\x64
. -
Cityscapes2Foggy Dataset:
DownloadCityscaples2Foggy.zip
from Google Drive and extract it tobuild\darknet\x64\data
.
Navigate to the x64
directory:
cd Project_dir\darknet\build\darknet\x64
To start training, run:
darknet detector train data/c2f.data cfg/ms-dayolo.cfg yolov4.conv.137 -dont_show -map -da
After training, evaluate the model with:
darknet detector map data/c2f.data cfg/ms-dayolo.cfg backup/ms-dayolo_best.weights
After evaluation, predict the model with:
darknet detector demo data/c2f.data cfg/ms-dayolo.cfg backup/ms-dayolo_best.weights <video_file>
For further details, refer to the original repository: GitHub - Mazin-Hnewa/MS-DAYOLO
Compiling can be more tedious, but following these steps with the compiled one will save you much trouble as long as you set the same environment to mine