From 00b8e29b6802cc085e30f64b48f4a693e6019235 Mon Sep 17 00:00:00 2001 From: Alexey Date: Sat, 12 Jun 2021 02:53:08 +0300 Subject: [PATCH 1/5] Update README.md --- README.md | 1 + 1 file changed, 1 insertion(+) diff --git a/README.md b/README.md index 337d095d44f..2d1bbc52e6c 100644 --- a/README.md +++ b/README.md @@ -28,6 +28,7 @@ About Darknet framework: http://pjreddie.com/darknet/ [![License: Unlicense](https://img.shields.io/badge/license-Unlicense-blue.svg)](https://github.com/AlexeyAB/darknet/blob/master/LICENSE) [![DOI](https://zenodo.org/badge/75388965.svg)](https://zenodo.org/badge/latestdoi/75388965) [![arxiv.org](http://img.shields.io/badge/cs.CV-arXiv%3A2004.10934-B31B1B.svg)](https://arxiv.org/abs/2004.10934) +[![arxiv.org](http://img.shields.io/badge/cs.CV-arXiv%3A2011.08036-B31B1B.svg)](https://arxiv.org/abs/2011.08036) [![colab](https://user-images.githubusercontent.com/4096485/86174089-b2709f80-bb29-11ea-9faf-3d8dc668a1a5.png)](https://colab.research.google.com/drive/12QusaaRj_lUwCGDvQNfICpa7kA7_a2dE) [![colab](https://user-images.githubusercontent.com/4096485/86174097-b56b9000-bb29-11ea-9240-c17f6bacfc34.png)](https://colab.research.google.com/drive/1_GdoqCJWXsChrOiY8sZMr_zbr_fH-0Fg) From 396b5299a79f6401c0657128ec6ff6d78816d78f Mon Sep 17 00:00:00 2001 From: Double Date: Thu, 17 Jun 2021 00:25:00 +0800 Subject: [PATCH 2/5] fix: flush buffer to weights-file when writing each layer (#7747) Co-authored-by: Double.c --- src/parser.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/parser.c b/src/parser.c index 8f8f584268e..a2d133382c4 100644 --- a/src/parser.c +++ b/src/parser.c @@ -2026,6 +2026,7 @@ void save_weights_upto(network net, char *filename, int cutoff, int save_ema) fwrite(l.biases, sizeof(float), l.outputs, fp); fwrite(l.weights, sizeof(float), size, fp); } + fflush(fp); } fclose(fp); } From 6c171a4ceaaf508568a90fe8f2d01014c2c62f34 Mon Sep 17 00:00:00 2001 From: Stefano Sinigardi Date: Fri, 18 Jun 2021 00:15:55 +0200 Subject: [PATCH 3/5] add automatic rebase github action (#7809) * add automatic rebase action * do not upload artifacts from PRs * use proper symbol in build.ps1 * fix lib naming * fix folder for dll artifacts --- .github/workflows/ccpp.yml | 2 +- .github/workflows/on_pr.yml | 127 ------------------ .github/workflows/rebase.yml | 19 +++ build.ps1 | 2 +- src/csharp/CMakeLists.txt | 2 +- .../{YoloWrapper.cs => YoloCSharpWrapper.cs} | 2 +- 6 files changed, 23 insertions(+), 131 deletions(-) create mode 100644 .github/workflows/rebase.yml rename src/csharp/{YoloWrapper.cs => YoloCSharpWrapper.cs} (97%) diff --git a/.github/workflows/ccpp.yml b/.github/workflows/ccpp.yml index 21ff07296fb..92fb50375b3 100644 --- a/.github/workflows/ccpp.yml +++ b/.github/workflows/ccpp.yml @@ -458,7 +458,7 @@ jobs: - uses: actions/upload-artifact@v2 with: name: darknet-vcpkg-${{ runner.os }} - path: ${{ runner.workspace }}/buildDirectory/Release/*.dll + path: ${{ github.workspace }}/build_release/*.dll - uses: actions/upload-artifact@v2 with: name: darknet-vcpkg-${{ runner.os }} diff --git a/.github/workflows/on_pr.yml b/.github/workflows/on_pr.yml index 6b6aface5b8..9f0a664ebcb 100644 --- a/.github/workflows/on_pr.yml +++ b/.github/workflows/on_pr.yml @@ -100,23 +100,6 @@ jobs: LD_LIBRARY_PATH: "/usr/local/cuda/lib64:/usr/local/cuda/lib64/stubs:$LD_LIBRARY_PATH" run: ./build.ps1 -UseVCPKG -DoNotUpdateVCPKG -EnableOPENCV -EnableCUDA -EnableCUDNN -DisableInteractive -DoNotUpdateDARKNET - - uses: actions/upload-artifact@v2 - with: - name: darknet-vcpkg-cuda-${{ runner.os }} - path: cfg - - uses: actions/upload-artifact@v2 - with: - name: darknet-vcpkg-cuda-${{ runner.os }} - path: data - - uses: actions/upload-artifact@v2 - with: - name: darknet-vcpkg-cuda-${{ runner.os }} - path: ${{ github.workspace }}/*dark* - - uses: actions/upload-artifact@v2 - with: - name: darknet-vcpkg-cuda-${{ runner.os }} - path: ${{ github.workspace }}/uselib* - ubuntu-vcpkg-opencv3-cuda: runs-on: ubuntu-20.04 @@ -219,23 +202,6 @@ jobs: LD_LIBRARY_PATH: "/usr/local/cuda/lib64:/usr/local/cuda/lib64/stubs:$LD_LIBRARY_PATH" run: ./build.ps1 -EnableOPENCV -DisableInteractive -DoNotUpdateDARKNET - - uses: actions/upload-artifact@v2 - with: - name: darknet-${{ runner.os }} - path: cfg - - uses: actions/upload-artifact@v2 - with: - name: darknet-${{ runner.os }} - path: data - - uses: actions/upload-artifact@v2 - with: - name: darknet-${{ runner.os }} - path: ${{ github.workspace }}/*dark* - - uses: actions/upload-artifact@v2 - with: - name: darknet-${{ runner.os }} - path: ${{ github.workspace }}/uselib* - ubuntu-cuda: runs-on: ubuntu-20.04 @@ -267,23 +233,6 @@ jobs: LD_LIBRARY_PATH: "/usr/local/cuda/lib64:/usr/local/cuda/lib64/stubs:$LD_LIBRARY_PATH" run: ./build.ps1 -EnableOPENCV -EnableCUDA -EnableCUDNN -DisableInteractive -DoNotUpdateDARKNET - - uses: actions/upload-artifact@v2 - with: - name: darknet-cuda-${{ runner.os }} - path: cfg - - uses: actions/upload-artifact@v2 - with: - name: darknet-cuda-${{ runner.os }} - path: data - - uses: actions/upload-artifact@v2 - with: - name: darknet-cuda-${{ runner.os }} - path: ${{ github.workspace }}/*dark* - - uses: actions/upload-artifact@v2 - with: - name: darknet-cuda-${{ runner.os }} - path: ${{ github.workspace }}/uselib* - ubuntu-no-ocv-cpp: runs-on: ubuntu-20.04 @@ -339,23 +288,6 @@ jobs: shell: pwsh run: ./build.ps1 -UseVCPKG -DoNotUpdateVCPKG -DisableInteractive -DoNotUpdateDARKNET - - uses: actions/upload-artifact@v2 - with: - name: darknet-vcpkg-${{ runner.os }} - path: cfg - - uses: actions/upload-artifact@v2 - with: - name: darknet-vcpkg-${{ runner.os }} - path: data - - uses: actions/upload-artifact@v2 - with: - name: darknet-vcpkg-${{ runner.os }} - path: ${{ github.workspace }}/*dark* - - uses: actions/upload-artifact@v2 - with: - name: darknet-vcpkg-${{ runner.os }} - path: ${{ github.workspace }}/uselib* - osx: runs-on: macos-latest @@ -371,23 +303,6 @@ jobs: shell: pwsh run: ./build.ps1 -EnableOPENCV -DisableInteractive -DoNotUpdateDARKNET - - uses: actions/upload-artifact@v2 - with: - name: darknet-${{ runner.os }} - path: cfg - - uses: actions/upload-artifact@v2 - with: - name: darknet-${{ runner.os }} - path: data - - uses: actions/upload-artifact@v2 - with: - name: darknet-${{ runner.os }} - path: ${{ github.workspace }}/*dark* - - uses: actions/upload-artifact@v2 - with: - name: darknet-${{ runner.os }} - path: ${{ github.workspace }}/uselib* - osx-no-ocv-no-omp-cpp: runs-on: macos-latest @@ -421,27 +336,6 @@ jobs: shell: pwsh run: ./build.ps1 -UseVCPKG -DoNotUpdateVCPKG -EnableOPENCV -DisableInteractive -DoNotUpdateDARKNET - - uses: actions/upload-artifact@v2 - with: - name: darknet-vcpkg-${{ runner.os }} - path: cfg - - uses: actions/upload-artifact@v2 - with: - name: darknet-vcpkg-${{ runner.os }} - path: data - - uses: actions/upload-artifact@v2 - with: - name: darknet-vcpkg-${{ runner.os }} - path: ${{ github.workspace }}/*dark* - - uses: actions/upload-artifact@v2 - with: - name: darknet-vcpkg-${{ runner.os }} - path: ${{ runner.workspace }}/buildDirectory/Release/*.dll - - uses: actions/upload-artifact@v2 - with: - name: darknet-vcpkg-${{ runner.os }} - path: ${{ github.workspace }}/uselib* - win-intlibs: runs-on: windows-latest @@ -454,27 +348,6 @@ jobs: shell: pwsh run: ./build.ps1 -DisableInteractive -DoNotUpdateDARKNET - - uses: actions/upload-artifact@v2 - with: - name: darknet-${{ runner.os }} - path: cfg - - uses: actions/upload-artifact@v2 - with: - name: darknet-${{ runner.os }} - path: data - - uses: actions/upload-artifact@v2 - with: - name: darknet-${{ runner.os }} - path: ${{ github.workspace }}/*dark* - - uses: actions/upload-artifact@v2 - with: - name: darknet-${{ runner.os }} - path: ${{ github.workspace }}/3rdparty/pthreads/bin/*.dll - - uses: actions/upload-artifact@v2 - with: - name: darknet-${{ runner.os }} - path: ${{ github.workspace }}/uselib* - win-setup-ps1: runs-on: windows-latest diff --git a/.github/workflows/rebase.yml b/.github/workflows/rebase.yml new file mode 100644 index 00000000000..608904374ef --- /dev/null +++ b/.github/workflows/rebase.yml @@ -0,0 +1,19 @@ +name: Automatic Rebase +on: + issue_comment: + types: [created] +jobs: + rebase: + name: Rebase + if: github.event.issue.pull_request != '' && contains(github.event.comment.body, '/rebase') && github.event.comment.author_association == 'MEMBER' + runs-on: ubuntu-latest + steps: + - name: Checkout the latest code + uses: actions/checkout@v2 + with: + token: ${{ secrets.GITHUB_TOKEN }} + fetch-depth: 0 # otherwise, you will fail to push refs to dest repo + - name: Automatic Rebase + uses: cirrus-actions/rebase@1.4 + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} diff --git a/build.ps1 b/build.ps1 index d230622e9a5..b5115cabc15 100755 --- a/build.ps1 +++ b/build.ps1 @@ -603,7 +603,7 @@ if (-Not $EnableOPENCV_CUDA) { } if ($EnableCSharpWrapper) { - $additional_build_setup = $additional_build_setup + " -DENABLE_CSHARP_WRAPPER:BOOL=ON" + $AdditionalBuildSetup = $AdditionalBuildSetup + " -DENABLE_CSHARP_WRAPPER:BOOL=ON" } $build_folder = "./build_release" diff --git a/src/csharp/CMakeLists.txt b/src/csharp/CMakeLists.txt index 971725b227d..1b591a16dab 100644 --- a/src/csharp/CMakeLists.txt +++ b/src/csharp/CMakeLists.txt @@ -1,5 +1,5 @@ -project(YoloWrapper LANGUAGES CSharp) +project(YoloCSharpWrapper LANGUAGES CSharp) include(CSharpUtilities) add_library(${PROJECT_NAME} diff --git a/src/csharp/YoloWrapper.cs b/src/csharp/YoloCSharpWrapper.cs similarity index 97% rename from src/csharp/YoloWrapper.cs rename to src/csharp/YoloCSharpWrapper.cs index 52c12adb80f..35d23a9c2e1 100644 --- a/src/csharp/YoloWrapper.cs +++ b/src/csharp/YoloCSharpWrapper.cs @@ -5,7 +5,7 @@ namespace Darknet { public class YoloWrapper : IDisposable { - private const string YoloLibraryName = "yolo_cpp_dll.dll"; + private const string YoloLibraryName = "darknet.dll"; private const int MaxObjects = 1000; [DllImport(YoloLibraryName, EntryPoint = "init")] From 3fafd211b908fd84a66f3723c77119351ed656a5 Mon Sep 17 00:00:00 2001 From: Stefano Sinigardi Date: Mon, 21 Jun 2021 11:07:31 +0200 Subject: [PATCH 4/5] [autorebase] bump to v1.5 (#7819) --- .github/workflows/rebase.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/rebase.yml b/.github/workflows/rebase.yml index 608904374ef..251a259ffcf 100644 --- a/.github/workflows/rebase.yml +++ b/.github/workflows/rebase.yml @@ -5,7 +5,7 @@ on: jobs: rebase: name: Rebase - if: github.event.issue.pull_request != '' && contains(github.event.comment.body, '/rebase') && github.event.comment.author_association == 'MEMBER' + if: github.event.issue.pull_request != '' && contains(github.event.comment.body, '/rebase') && (github.event.comment.author_association == 'MEMBER' || github.event.comment.author_association == 'OWNER' || github.event.comment.author_association == 'CONTRIBUTOR') runs-on: ubuntu-latest steps: - name: Checkout the latest code @@ -14,6 +14,6 @@ jobs: token: ${{ secrets.GITHUB_TOKEN }} fetch-depth: 0 # otherwise, you will fail to push refs to dest repo - name: Automatic Rebase - uses: cirrus-actions/rebase@1.4 + uses: cirrus-actions/rebase@1.5 env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} From 070ed01e26e5568ad5183321881d3b26380f5345 Mon Sep 17 00:00:00 2001 From: Alexey Date: Mon, 21 Jun 2021 23:47:53 +0300 Subject: [PATCH 5/5] Update README.md --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 2d1bbc52e6c..42007e975d6 100644 --- a/README.md +++ b/README.md @@ -33,7 +33,7 @@ About Darknet framework: http://pjreddie.com/darknet/ [![colab](https://user-images.githubusercontent.com/4096485/86174097-b56b9000-bb29-11ea-9240-c17f6bacfc34.png)](https://colab.research.google.com/drive/1_GdoqCJWXsChrOiY8sZMr_zbr_fH-0Fg) - [YOLOv4 model zoo](https://github.com/AlexeyAB/darknet/wiki/YOLOv4-model-zoo) -- [Requirements (and how to install dependencies)](#requirements) +- [Requirements (and how to install dependencies)](#requirements-for-windows-linux-and-macos) - [Pre-trained models](#pre-trained-models) - [FAQ - frequently asked questions](https://github.com/AlexeyAB/darknet/wiki/FAQ---frequently-asked-questions) - [Explanations in issues](https://github.com/AlexeyAB/darknet/issues?q=is%3Aopen+is%3Aissue+label%3AExplanations)