Improve Numerical Stability of Bernoulli CDF functions #3496
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Windows Rtools40 | |
on: | |
pull_request: | |
branches: [ develop, master ] | |
push: | |
branches: [ develop ] | |
paths-ignore: | |
- 'doygen/**' | |
- 'hooks/**' | |
- 'licenses/**' | |
- 'LICENSE.md' | |
- 'README.md' | |
- 'RELEASE-NOTES.txt' | |
permissions: | |
contents: read | |
concurrency: | |
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }} | |
cancel-in-progress: true | |
jobs: | |
prim-rev: | |
name: prim and rev tests | |
runs-on: windows-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: actions/setup-python@v4 | |
with: | |
python-version: '3.x' | |
- uses: r-lib/actions/setup-r@v2 | |
with: | |
r-version: 4.1.3 | |
- name: Set path for Rtools40 | |
if: runner.os == 'Windows' | |
run: echo "C:/rtools40/usr/bin;C:/rtools40/mingw64/bin" | Out-File -Append -FilePath $env:GITHUB_PATH -Encoding utf8 | |
- name: Install mingw32-make and check toolchain path | |
if: runner.os == 'Windows' | |
run: | | |
pacman -Syu mingw-w64-x86_64-make --noconfirm | |
g++ --version | |
Get-Command g++ | Select-Object -ExpandProperty Definition | |
mingw32-make --version | |
Get-Command mingw32-make | Select-Object -ExpandProperty Definition | |
shell: powershell | |
- name: Build Math libs | |
shell: powershell | |
run: | | |
Add-Content make\local "O=1`n" | |
mingw32-make -f make/standalone math-libs -j2 | |
- name: Add TBB to PATH | |
shell: powershell | |
run: echo "D:/a/math/math/lib/tbb" | Out-File -Append -FilePath $env:GITHUB_PATH -Encoding utf8 | |
- name: Run prim and rev unit tests | |
shell: powershell | |
run: | | |
python.exe runTests.py -j2 test/unit/*_test.cpp | |
python.exe runTests.py -j2 test/unit/math/*_test.cpp | |
python.exe runTests.py -j2 test/unit/math/prim | |
python.exe runTests.py -j2 test/unit/math/rev | |
python.exe runTests.py -j2 test/unit/math/memory | |
- name: Upload gtest_output xml | |
uses: actions/upload-artifact@v3 | |
if: failure() | |
with: | |
name: gtest_outputs_xml | |
path: '**/*_test.xml' | |
fwd-non-fun-mix: | |
name: fwd tests and non-fun mix tests | |
runs-on: windows-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: actions/setup-python@v4 | |
with: | |
python-version: '3.x' | |
- uses: r-lib/actions/setup-r@v2 | |
with: | |
r-version: 4.1.3 | |
- name: Set path for Rtools40 | |
if: runner.os == 'Windows' | |
run: echo "C:/rtools40/usr/bin;C:/rtools40/mingw64/bin" | Out-File -Append -FilePath $env:GITHUB_PATH -Encoding utf8 | |
- name: Install mingw32-make and check toolchain path | |
if: runner.os == 'Windows' | |
run: | | |
pacman -Syu mingw-w64-x86_64-make --noconfirm | |
g++ --version | |
Get-Command g++ | Select-Object -ExpandProperty Definition | |
mingw32-make --version | |
Get-Command mingw32-make | Select-Object -ExpandProperty Definition | |
shell: powershell | |
- name: Build Math libs | |
shell: powershell | |
run: | | |
Add-Content make\local "O=1`n" | |
mingw32-make -f make/standalone math-libs -j2 | |
- name: Add TBB to PATH | |
shell: powershell | |
run: echo "D:/a/math/math/lib/tbb" | Out-File -Append -FilePath $env:GITHUB_PATH -Encoding utf8 | |
- name: Disable running fwd/mix tests | |
shell: powershell | |
run: echo "CXXFLAGS+= -DSTAN_MATH_TESTS_REV_ONLY" | Out-File -Append -FilePath make/local -Encoding utf8 | |
- name: Run fwd unit tests and all the mix tests except those in mix/fun | |
shell: powershell | |
run: | | |
python.exe runTests.py test/unit/math/fwd -j2 | |
python.exe runTests.py test/unit/math/mix/core -j2 | |
python.exe runTests.py test/unit/math/mix/functor -j2 | |
python.exe runTests.py test/unit/math/mix/meta -j2 | |
python.exe runTests.py test/unit/math/mix/prob -j2 | |
python.exe runTests.py test/unit/math/mix/*_test.cpp -j2 | |
- name: Upload gtest_output xml | |
uses: actions/upload-artifact@v3 | |
if: failure() | |
with: | |
name: gtest_outputs_xml | |
path: '**/*_test.xml' | |
mix-fun-1: | |
name: mix/fun tests 1 | |
runs-on: windows-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: actions/setup-python@v4 | |
with: | |
python-version: '3.x' | |
- uses: r-lib/actions/setup-r@v2 | |
with: | |
r-version: 4.1.3 | |
- name: Set path for Rtools40 | |
if: runner.os == 'Windows' | |
run: echo "C:/rtools40/usr/bin;C:/rtools40/mingw64/bin" | Out-File -Append -FilePath $env:GITHUB_PATH -Encoding utf8 | |
- name: Install mingw32-make and check toolchain path | |
if: runner.os == 'Windows' | |
run: | | |
pacman -Syu mingw-w64-x86_64-make --noconfirm | |
g++ --version | |
Get-Command g++ | Select-Object -ExpandProperty Definition | |
mingw32-make --version | |
Get-Command mingw32-make | Select-Object -ExpandProperty Definition | |
shell: powershell | |
- name: Build Math libs | |
shell: powershell | |
run: | | |
Add-Content make\local "O=1`n" | |
mingw32-make -f make/standalone math-libs -j2 | |
- name: Add TBB to PATH | |
shell: powershell | |
run: echo "D:/a/math/math/lib/tbb" | Out-File -Append -FilePath $env:GITHUB_PATH -Encoding utf8 | |
- name: Run mix/fun unit tests | |
shell: powershell | |
run: | | |
$MixFunTests = Get-ChildItem -Path test\unit\math\mix\fun\* -Include *.cpp | Resolve-Path -Relative | |
$NumberTests = $MixFunTests.Length | |
$HalfNumberTests = [math]::Floor($NumberTests / 2) | |
python.exe runTests.py $MixFunTests[0..$HalfNumberTests] | |
- name: Upload gtest_output xml | |
uses: actions/upload-artifact@v3 | |
if: failure() | |
with: | |
name: gtest_outputs_xml | |
path: '**/*_test.xml' | |
mix-fun-2: | |
name: mix/fun tests 2 | |
runs-on: windows-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: actions/setup-python@v4 | |
with: | |
python-version: '3.x' | |
- uses: r-lib/actions/setup-r@v2 | |
with: | |
r-version: 4.1.3 | |
- name: Set path for Rtools40 | |
if: runner.os == 'Windows' | |
run: echo "C:/rtools40/usr/bin;C:/rtools40/mingw64/bin" | Out-File -Append -FilePath $env:GITHUB_PATH -Encoding utf8 | |
- name: Install mingw32-make and check toolchain path | |
if: runner.os == 'Windows' | |
run: | | |
pacman -Syu mingw-w64-x86_64-make --noconfirm | |
g++ --version | |
Get-Command g++ | Select-Object -ExpandProperty Definition | |
mingw32-make --version | |
Get-Command mingw32-make | Select-Object -ExpandProperty Definition | |
shell: powershell | |
- name: Build Math libs | |
shell: powershell | |
run: | | |
Add-Content make\local "O=1`n" | |
mingw32-make -f make/standalone math-libs -j2 | |
- name: Add TBB to PATH | |
shell: powershell | |
run: echo "D:/a/math/math/lib/tbb" | Out-File -Append -FilePath $env:GITHUB_PATH -Encoding utf8 | |
- name: Run mix/fun unit tests | |
shell: powershell | |
run: | | |
$MixFunTests = Get-ChildItem -Path test\unit\math\mix\fun\* -Include *.cpp | Resolve-Path -Relative | |
$NumberTests = $MixFunTests.Length | |
$HalfNumberTests = [math]::Floor($NumberTests / 2) | |
python.exe runTests.py $MixFunTests[($HalfNumberTests + 1)..($NumberTests - 1)] | |
- name: Upload gtest_output xml | |
uses: actions/upload-artifact@v3 | |
if: failure() | |
with: | |
name: gtest_outputs_xml | |
path: '**/*_test.xml' |