Skip to content

Commit

Permalink
Merge branch 'main' of https://github.com/Apra-Labs/ApraPipes into Fa…
Browse files Browse the repository at this point in the history
…celandmarksCV
  • Loading branch information
venkat0907 committed Jul 11, 2023
2 parents eb77b7a + 79edaf2 commit 7c06210
Show file tree
Hide file tree
Showing 29 changed files with 178 additions and 3,063 deletions.
1 change: 0 additions & 1 deletion .github/workflows/CI-Linux-ARM64.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@ jobs:
is-selfhosted: true
cuda: 'ON'
prep-cmd: 'echo skipping builder prep as I can not sudo'
is-build-gst: false
cache-path: './none'
cmake-conf-cmd: 'export VCPKG_FORCE_SYSTEM_BINARIES=1 && cmake -B . -DENABLE_ARM64=ON ../base'
nProc: 6
Expand Down
12 changes: 12 additions & 0 deletions .github/workflows/CI-Linux-CUDA-Docker.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,18 @@ env:
NOTE_TO_SELF: "environments can not be passed from here to reused workflows!"

jobs:
# linux-cuda-build-prep:
# this is in caching, not using it for now
# uses: ./.github/workflows/build-test-lin-container.yml
# with:
# runner: 'ubuntu-20.04'
# flav: 'Linux-Cuda'
# is-selfhosted: false
# cuda: 'ON'
# prep-cmd: 'echo skipping builder prep as I can not sudo'
# is-prep-phase: true
# cache-path: '/github/home/.cache/vcpkg/archives'
# nProc: 3
linux-cuda-build-no-test:
uses: ./.github/workflows/build-test-lin-container.yml
with:
Expand Down
1 change: 0 additions & 1 deletion .github/workflows/CI-Win-CUDA.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@ jobs:
flav: 'Windows-cuda'
cuda: 'ON'
is-selfhosted: true
is-build-gst: false # part of vcpkg on windows
nProc: 8
nTestTimeoutMins: 20
win-cuda-publish:
Expand Down
2 changes: 0 additions & 2 deletions .github/workflows/CI-Win-NoCUDA.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@ jobs:
flav: 'Win-nocuda'
cuda: 'OFF'
is-selfhosted: false
is-build-gst: false # part of vcpkg on windows
is-prep-phase: true
nProc: 3
win-nocuda-build-test:
Expand All @@ -28,7 +27,6 @@ jobs:
flav: 'Win-nocuda'
is-selfhosted: false
cuda: 'OFF'
is-build-gst: false # part of vcpkg on windows
is-prep-phase: false
nProc: 3
win-nocuda-publish:
Expand Down
47 changes: 13 additions & 34 deletions .github/workflows/build-test-lin-container.yml
Original file line number Diff line number Diff line change
Expand Up @@ -48,11 +48,6 @@ on:
description: 'this workflow is called for a prep phase: it will split vcpkg install into 2 portions to cache and save'
default: false
required: false
is-build-gst:
type: boolean
description: 'should we build GStreamer? we dont build on windows and ARM_Linux.'
default: true
required: false
cache-path:
type: string
description: 'the folder which needs to be cached e.g. .cache/vcpkg'
Expand All @@ -77,9 +72,8 @@ jobs:
build:
env:
TEST_EXE: build/aprapipesut
LD_LIB_PATH: '${{github.workspace}}/thirdparty/gst-build/gst-build-1.16/outInstall/lib/x86_64-linux-gnu:${{github.workspace}}/thirdparty/Video_Codec_SDK_10.0.26/Lib/linux/stubs/x86_64:/usr/local/cuda-10.2/compat/:/usr/local/cuda/lib64:${LD_LIBRARY_PATH-}'
CMAKE_TC_FILE: '../vcpkg/scripts/buildsystems/vcpkg.cmake' # Note: naming this variable as CMAKE_TOOLCHAIN_FILE can cause havoc!!!
container: ghcr.io/kumaakh/aprapipes-build-x86-ubutu18.04-cuda:latest
container: ghcr.io/kumaakh/aprapipes-build-x86-ubutu18.04-cuda:last-good
defaults:
run:
shell: bash
Expand Down Expand Up @@ -110,12 +104,14 @@ jobs:
submodules: 'recursive'
lfs: true
fetch-depth: 0
- name: Checkout submodule

- name: List Submodules
run: |
git config --global --add safe.directory "*"
git submodule status > submodule_ver.txt
cat submodule_ver.txt
git rev-list --all --count
- name: Run VCPKG bootstrap
run: ${{ inputs.bootstrap-cmd }}

Expand All @@ -131,34 +127,21 @@ jobs:
run: .\fix-vcpkg-json.ps1 -removeOpenCV
shell: pwsh

- name: cache init on container build
if: ${{ job.container != null }} # we are running on a cloud hosted container... move the cache "initially"
run: |
cp -R /root/.cache /github/home/ || true
ls ${{ inputs.cache-path }} || true
ls thirdparty/gst-build/gst-build-1.16/outInstall || true
continue-on-error: true
# - name: cache init on container build
# if: ${{ job.container != null }} # we are running on a cloud hosted container... move the cache "initially"
# run: |
# cp -R /root/.cache /github/home/ || true
# ls ${{ inputs.cache-path }} || true
# continue-on-error: true

- name: Cache dependencies for fast cloud build
id: cache-all
uses: actions/cache@v3
with:
path: |
${{ inputs.cache-path }}
./thirdparty/gst-build/gst-build-1.16/outInstall/
./thirdparty/libmp4/build
key: ${{ inputs.flav }}-4-${{ hashFiles( 'base/vcpkg.json', 'vcpkg/baseline.json', 'submodule_ver.txt') }}
restore-keys: ${{ inputs.flav }}-

- name: Build Gstreamer On Linux_x64 when it is not cached
if: ${{ inputs.is-build-gst && steps.cache-all.outputs.cache-hit != 'true'}}
working-directory: ${{github.workspace}}/thirdparty
run: sh ./build_gstreamer.sh

- name: Build libmp4 when it is not cached
if: ${{ steps.cache-all.outputs.cache-hit != 'true' }}
working-directory: ${{github.workspace}}/thirdparty/libmp4
run: ./build.cmd

- name: Make build folder
run: mkdir -p build
Expand All @@ -176,17 +159,13 @@ jobs:

- name: List Test cases
if: ${{!inputs.is-prep-phase}}
env:
LD_LIBRARY_PATH: ${{env.LD_LIB_PATH}}
run: |
ldd ${{env.TEST_EXE}} | grep 'not found' || true
${{env.TEST_EXE}} --list_content > tests.txt
ldd ${{env.TEST_EXE}} | tee >(grep 'not found') || true
${{env.TEST_EXE}} --list_content > tests.txt || true
timeout-minutes: 1

- name: Run Tests
if: ${{!inputs.is-prep-phase && !inputs.skip-test}}
env:
LD_LIBRARY_PATH: ${{env.LD_LIB_PATH}}
run: |
${{env.TEST_EXE}} --log_format=JUNIT --log_sink=CI_test_result_${{inputs.flav}}.xml -p -l all || echo 'test execution returned error'
timeout-minutes: ${{ inputs.nTestTimeoutMins}}
Expand Down
49 changes: 12 additions & 37 deletions .github/workflows/build-test-lin-wsl.yml
Original file line number Diff line number Diff line change
Expand Up @@ -48,11 +48,6 @@ on:
description: 'this workflow is called for a prep phase: it will split vcpkg install into 2 portions to cache and save'
default: false
required: false
is-build-gst:
type: boolean
description: 'should we build GStreamer? we dont build on windows and ARM_Linux.'
default: true
required: false
cache-path:
type: string
description: 'the folder which needs to be cached e.g. .cache/vcpkg'
Expand All @@ -77,7 +72,6 @@ jobs:
build:
env:
TEST_EXE: build/aprapipesut
LD_LIB_PATH: './thirdparty/gst-build/gst-build-1.16/outInstall/lib/x86_64-linux-gnu:./thirdparty/Video_Codec_SDK_10.0.26/Lib/linux/stubs/x86_64:/usr/local/cuda-10.2/compat/:/usr/local/cuda/lib64:${LD_LIBRARY_PATH-}'
CMAKE_TC_FILE: '../vcpkg/scripts/buildsystems/vcpkg.cmake' # Note: naming this variable as CMAKE_TOOLCHAIN_FILE can cause havoc!!!
runs-on: ${{ inputs.runner }}
steps:
Expand Down Expand Up @@ -112,12 +106,14 @@ jobs:
submodules: 'recursive'
lfs: true
fetch-depth: 0
- name: Checkout submodule

- name: List Submodules
run: |
git config --global --add safe.directory "*"
git submodule status > submodule_ver.txt
cat submodule_ver.txt
git rev-list --all --count
- name: Run VCPKG bootstrap
run: ${{ inputs.bootstrap-cmd }}
shell: wsl-bash {0}
Expand All @@ -134,44 +130,25 @@ jobs:
run: .\fix-vcpkg-json.ps1 -removeOpenCV
shell: pwsh

- name: cache init on container build
if: ${{ job.container != null }} # we are running on a cloud hosted container... move the cache "initially"
run: |
cp -R /root/.cache /github/home/ || true
ls ${{ inputs.cache-path }} || true
ls thirdparty/gst-build/gst-build-1.16/outInstall || true
continue-on-error: true
# - name: cache init on container build
# if: ${{ job.container != null }} # we are running on a cloud hosted container... move the cache "initially"
# run: |
# cp -R /root/.cache /github/home/ || true
# ls ${{ inputs.cache-path }} || true
# continue-on-error: true

- name: Cache dependencies for fast cloud build
id: cache-all
uses: actions/cache@v3
with:
path: |
${{ inputs.cache-path }}
./thirdparty/gst-build/gst-build-1.16/outInstall/
./thirdparty/libmp4/build
key: ${{ inputs.flav }}-4-${{ hashFiles( 'base/vcpkg.json', 'vcpkg/baseline.json', 'submodule_ver.txt') }}
restore-keys: ${{ inputs.flav }}-

- name: On WSL prep the thirdparty build scripts
working-directory: ${{github.workspace}}/thirdparty
run: |
(dos2unix ./build_gstreamer.sh) || true
chmod a+x ./build_gstreamer.sh
(dos2unix libmp4/build.cmd) || true
chmod a+x libmp4/build.cmd
shell: wsl-bash {0}

- name: Build Gstreamer On Linux_x64 when it is not cached
if: ${{ inputs.is-build-gst && steps.cache-all.outputs.cache-hit != 'true'}}
working-directory: ${{github.workspace}}/thirdparty
run: sh ./build_gstreamer.sh
shell: wsl-bash {0}

- name: Build libmp4 when it is not cached
if: ${{ steps.cache-all.outputs.cache-hit != 'true' }}
working-directory: ${{github.workspace}}/thirdparty/libmp4
run: ./build.cmd
shell: wsl-bash {0}

- name: Make build folder
Expand All @@ -193,16 +170,14 @@ jobs:
- name: List Test cases
if: ${{!inputs.is-prep-phase}}
run: |
export LD_LIBRARY_PATH=${{env.LD_LIB_PATH}}
ldd ${{env.TEST_EXE}} | grep 'not found' || true
${{env.TEST_EXE}} --list_content > tests.txt
ldd ${{env.TEST_EXE}} | tee >(grep 'not found') || true
${{env.TEST_EXE}} --list_content > tests.txt || true
timeout-minutes: 1
shell: wsl-bash {0}

- name: Run Tests
if: ${{!inputs.is-prep-phase && !inputs.skip-test}}
run: |
export LD_LIBRARY_PATH=${{env.LD_LIB_PATH}}
${{env.TEST_EXE}} --log_format=JUNIT --log_sink=CI_test_result_${{inputs.flav}}.xml -p -l all || echo 'test execution returned error'
timeout-minutes: ${{ inputs.nTestTimeoutMins}}
shell: wsl-bash {0}
Expand Down
45 changes: 12 additions & 33 deletions .github/workflows/build-test-lin.yml
Original file line number Diff line number Diff line change
Expand Up @@ -48,11 +48,6 @@ on:
description: 'this workflow is called for a prep phase: it will split vcpkg install into 2 portions to cache and save'
default: false
required: false
is-build-gst:
type: boolean
description: 'should we build GStreamer? we dont build on windows and ARM_Linux.'
default: true
required: false
cache-path:
type: string
description: 'the folder which needs to be cached e.g. .cache/vcpkg'
Expand All @@ -77,7 +72,6 @@ jobs:
build:
env:
TEST_EXE: build/aprapipesut
LD_LIB_PATH: '${{github.workspace}}/thirdparty/gst-build/gst-build-1.16/outInstall/lib/x86_64-linux-gnu:${{github.workspace}}/thirdparty/Video_Codec_SDK_10.0.26/Lib/linux/stubs/x86_64:/usr/local/cuda-10.2/compat/:/usr/local/cuda/lib64:${LD_LIBRARY_PATH-}'
CMAKE_TC_FILE: '../vcpkg/scripts/buildsystems/vcpkg.cmake' # Note: naming this variable as CMAKE_TOOLCHAIN_FILE can cause havoc!!!
runs-on: ${{ inputs.runner }}
steps:
Expand Down Expand Up @@ -106,12 +100,14 @@ jobs:
submodules: 'recursive'
lfs: true
fetch-depth: 0
- name: Checkout submodule

- name: List Submodules
run: |
git config --global --add safe.directory "*"
git submodule status > submodule_ver.txt
cat submodule_ver.txt
git rev-list --all --count
- name: Run VCPKG bootstrap
run: ${{ inputs.bootstrap-cmd }}

Expand All @@ -127,34 +123,21 @@ jobs:
run: .\fix-vcpkg-json.ps1 -removeOpenCV
shell: pwsh

- name: cache init on container build
if: ${{ job.container != null }} # we are running on a cloud hosted container... move the cache "initially"
run: |
cp -R /root/.cache /github/home/ || true
ls ${{ inputs.cache-path }} || true
ls thirdparty/gst-build/gst-build-1.16/outInstall || true
continue-on-error: true
# - name: cache init on container build
# if: ${{ job.container != null }} # we are running on a cloud hosted container... move the cache "initially"
# run: |
# cp -R /root/.cache /github/home/ || true
# ls ${{ inputs.cache-path }} || true
# continue-on-error: true

- name: Cache dependencies for fast cloud build
id: cache-all
uses: actions/cache@v3
with:
path: |
${{ inputs.cache-path }}
./thirdparty/gst-build/gst-build-1.16/outInstall/
./thirdparty/libmp4/build
key: ${{ inputs.flav }}-4-${{ hashFiles( 'base/vcpkg.json', 'vcpkg/baseline.json', 'submodule_ver.txt') }}
restore-keys: ${{ inputs.flav }}-

- name: Build Gstreamer On Linux_x64 when it is not cached
if: ${{ inputs.is-build-gst && steps.cache-all.outputs.cache-hit != 'true'}}
working-directory: ${{github.workspace}}/thirdparty
run: sh ./build_gstreamer.sh

- name: Build libmp4 when it is not cached
if: ${{ steps.cache-all.outputs.cache-hit != 'true' }}
working-directory: ${{github.workspace}}/thirdparty/libmp4
run: ./build.cmd

- name: Make build folder
run: mkdir -p build
Expand All @@ -172,17 +155,13 @@ jobs:

- name: List Test cases
if: ${{!inputs.is-prep-phase}}
env:
LD_LIBRARY_PATH: ${{env.LD_LIB_PATH}}
run: |
ldd ${{env.TEST_EXE}} | grep 'not found' || true
${{env.TEST_EXE}} --list_content > tests.txt
ldd ${{env.TEST_EXE}} | tee >(grep 'not found') || true
${{env.TEST_EXE}} --list_content > tests.txt || true
timeout-minutes: 1

- name: Run Tests
if: ${{!inputs.is-prep-phase && !inputs.skip-test}}
env:
LD_LIBRARY_PATH: ${{env.LD_LIB_PATH}}
run: |
${{env.TEST_EXE}} --log_format=JUNIT --log_sink=CI_test_result_${{inputs.flav}}.xml -p -l all || echo 'test execution returned error'
timeout-minutes: ${{ inputs.nTestTimeoutMins}}
Expand Down
Loading

0 comments on commit 7c06210

Please sign in to comment.