mirror of
https://github.com/browsermt/bergamot-translator.git
synced 2024-08-15 08:30:46 +03:00
Windows workflows and mac framework accelerate (#108)
Windows still failing but getting closer
This commit is contained in:
parent
7d2e74f3c0
commit
fdf9e66cef
74
.github/workflows/windows.yml
vendored
74
.github/workflows/windows.yml
vendored
@ -17,12 +17,6 @@ jobs:
|
||||
# Windows CPU-only build
|
||||
- name: "Windows CPU-only"
|
||||
cuda: ""
|
||||
gpu: false
|
||||
# GPU Builds are commented out, for bergamot-translator CI runs.
|
||||
# Windows CPU+GPU build
|
||||
# - name: "Windows CPU+CUDA"
|
||||
# cuda: "10.2"
|
||||
# gpu: true
|
||||
|
||||
runs-on: windows-2019
|
||||
name: ${{ matrix.name }}
|
||||
@ -42,89 +36,31 @@ jobs:
|
||||
echo "MKLROOT=${{ github.workspace }}\mkl" | Out-File -FilePath $env:GITHUB_ENV -Encoding utf8 -Append
|
||||
shell: powershell
|
||||
|
||||
- name: Install CUDA
|
||||
run: |
|
||||
.\3rd_party\marian-dev\scripts\ci\install_cuda_windows.ps1 "10.2"
|
||||
# Set CUDA_PATH environment variable so that CMake can find CUDA
|
||||
echo "CUDA_PATH=$env:CUDA_PATH" | Out-File -FilePath $env:GITHUB_ENV -Encoding utf8 -Append
|
||||
echo "$env:CUDA_PATH/bin" | Out-File -FilePath $env:GITHUB_PATH -Encoding utf8 -Append
|
||||
shell: powershell
|
||||
if: matrix.gpu == true
|
||||
|
||||
- name: Prepare vcpkg
|
||||
uses: lukka/run-vcpkg@v4
|
||||
with:
|
||||
vcpkgArguments: protobuf
|
||||
vcpkgGitCommitId: 6185aa76504a5025f36754324abf307cc776f3da
|
||||
vcpkgArguments: protobuf pcre2
|
||||
vcpkgGitCommitId: 6185aa76504a5025f36754324abf307cc776f3da
|
||||
vcpkgDirectory: ${{ github.workspace }}/vcpkg/
|
||||
vcpkgTriplet: x64-windows-static
|
||||
|
||||
# Windows CUDA builds use USE_NCCL=off due to compilation errors.
|
||||
# Windows CPU only minimal build
|
||||
- name: Build Debug
|
||||
uses: lukka/run-cmake@v3
|
||||
with:
|
||||
buildDirectory: ${{ github.workspace }}/build/Debug
|
||||
cmakeAppendedArgs: '-G Ninja
|
||||
-DCMAKE_BUILD_TYPE="Debug"
|
||||
-DOPENSSL_USE_STATIC_LIBS="TRUE"
|
||||
-DOPENSSL_MSVC_STATIC_RT="TRUE"
|
||||
-DCOMPILE_CPU="TRUE"
|
||||
-DCOMPILE_CUDA="${{ matrix.gpu }}"
|
||||
-DCOMPILE_SERVER="FALSE"
|
||||
-DCOMPILE_TESTS="TRUE"
|
||||
-DUSE_FBGEMM="TRUE"
|
||||
-DUSE_MPI="FALSE"
|
||||
-DUSE_NCCL="FALSE"
|
||||
-DUSE_SENTENCEPIECE="TRUE"
|
||||
-DUSE_STATIC_LIBS="TRUE"'
|
||||
cmakeListsOrSettingsJson: CMakeListsTxtAdvanced
|
||||
cmakeListsTxtPath: ${{ github.workspace }}/CMakeLists.txt
|
||||
useVcpkgToolchainFile: true
|
||||
# Building in Debug is sufficient for the all-in CPU+GPU compilation;
|
||||
# its main purpose is to detect warnings that the Release build is not
|
||||
# able to find sometimes.
|
||||
if: matrix.gpu == true
|
||||
|
||||
# Windows CUDA builds use USE_NCCL=off due to compilation errors
|
||||
# Boost is pre-installed on Azure/GitHub-hosted Windows runners
|
||||
# https://github.com/actions/virtual-environments/blob/main/images/win/Windows2019-Readme.md#boost
|
||||
# (not used yet)
|
||||
- name: Build Release
|
||||
uses: lukka/run-cmake@v3
|
||||
with:
|
||||
buildDirectory: ${{ github.workspace }}/build/
|
||||
cmakeAppendedArgs: '-G Ninja
|
||||
-DBOOST_ROOT="$(BOOST_ROOT_1_72_0)"
|
||||
-DBOOST_INCLUDEDIR="$(BOOST_ROOT_1_72_0)/include"
|
||||
-DBOOST_LIBRARYDIR="$(BOOST_ROOT_1_72_0)/lib"
|
||||
-DCMAKE_BUILD_TYPE="Release"
|
||||
-DOPENSSL_USE_STATIC_LIBS="TRUE"
|
||||
-DOPENSSL_MSVC_STATIC_RT="TRUE"
|
||||
-DCOMPILE_CPU="TRUE"
|
||||
-DCOMPILE_CUDA="${{ matrix.gpu }}"
|
||||
-DCOMPILE_SERVER="FALSE"
|
||||
-DCOMPILE_TESTS="TRUE"
|
||||
-DUSE_FBGEMM="TRUE"
|
||||
-DUSE_MPI="FALSE"
|
||||
-DUSE_NCCL="FALSE"
|
||||
-DUSE_SENTENCEPIECE="TRUE"
|
||||
-DUSE_WASM_COMPATIBLE_SOURCE="OFF"
|
||||
-DUSE_STATIC_LIBS="TRUE"'
|
||||
cmakeListsOrSettingsJson: CMakeListsTxtAdvanced
|
||||
cmakeListsTxtPath: ${{ github.workspace }}/CMakeLists.txt
|
||||
useVcpkgToolchainFile: true
|
||||
|
||||
# Removing unit-tests, taken care of in browsermt/marian-dev
|
||||
# - name: Run unit tests
|
||||
# working-directory: build/
|
||||
# run: ctest
|
||||
# # Not run in GPU builds because GitHub-hosted VMs do not have GPUs
|
||||
# if: matrix.gpu == false
|
||||
|
||||
- name: Print versions
|
||||
working-directory: build/
|
||||
run: |
|
||||
.\marian.exe --version
|
||||
.\marian-decoder.exe --version
|
||||
.\marian-scorer.exe --version
|
||||
.\app\bergamot-translator-app.exe --version
|
||||
dir *.exe
|
||||
shell: cmd
|
||||
|
2
3rd_party/marian-dev
vendored
2
3rd_party/marian-dev
vendored
@ -1 +1 @@
|
||||
Subproject commit 0f0bcf99626c660227bb68b76267a8d2451e7172
|
||||
Subproject commit 46a22187341ff51b3f11a8cb1edf51c995e583ca
|
Loading…
Reference in New Issue
Block a user