-
Notifications
You must be signed in to change notification settings - Fork 37
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Adds various dimensions to the CI build matrix for SmartSim. The build matrix now uses MacOS & Ubuntu, GNU8, RedisAI 1.2.3 & 1.2.5, and Python 3.7-3.9. The build matrix excludes building with RedisAI 1.2.5 when on MacOS as RedisAI temporarily removed support for MacOS in 1.2.4 and 1.2.5 [ committed by @EricGustin and @Spartee ] [ reviewed by @Spartee ]
- Loading branch information
1 parent
ba824d3
commit 0c74aee
Showing
3 changed files
with
100 additions
and
105 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,65 @@ | ||
name: run-tests | ||
|
||
on: [push, pull_request] | ||
|
||
env: | ||
HOMEBREW_NO_ANALYTICS: "ON" # Make Homebrew installation a little quicker | ||
HOMEBREW_NO_AUTO_UPDATE: "ON" | ||
HOMEBREW_NO_BOTTLE_SOURCE_FALLBACK: "ON" | ||
HOMEBREW_NO_GITHUB_API: "ON" | ||
HOMEBREW_NO_INSTALL_CLEANUP: "ON" | ||
|
||
|
||
jobs: | ||
run_tests: | ||
name: Run tests with ${{ matrix.os }}, Python ${{ matrix.py_v}}, RedisAI ${{ matrix.rai }} | ||
runs-on: ${{ matrix.os }} | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
os: [macos-10.15, ubuntu-20.04] # Operating systems | ||
compiler: [8] # GNU compiler version | ||
rai: [1.2.3, 1.2.5] # Redis AI versions | ||
py_v: [3.7, 3.8, 3.9] # Python versions | ||
exclude: | ||
- os: macos-10.15 # Do not build with Redis AI 1.2.5 on MacOS | ||
rai: 1.2.5 | ||
|
||
env: | ||
SMARTSIM_REDISAI: ${{ matrix.rai }} | ||
|
||
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: actions/setup-python@v2 | ||
with: | ||
python-version: ${{ matrix.py_v }} | ||
|
||
- name: Install build-essentials for Ubuntu | ||
if: contains( matrix.os, 'ubuntu' ) | ||
run: | | ||
sudo add-apt-repository ppa:ubuntu-toolchain-r/test | ||
sudo apt-get update | ||
sudo apt-get install -y build-essential | ||
sudo apt-get install -y wget | ||
- name: Install GNU make for MacOS and set GITHUB_PATH | ||
if: "contains( matrix.os, 'macos' )" | ||
run: | | ||
brew install make || true | ||
echo "$(brew --prefix)/opt/make/libexec/gnubin" >> $GITHUB_PATH | ||
- name: Install SmartSim (with ML backends) | ||
run: python -m pip install .[dev,ml,ray] | ||
|
||
- name: Install ML Runtimes with Smart | ||
if: contains( matrix.os, 'macos' ) | ||
run: smart build --device cpu -v | ||
|
||
- name: Install ML Runtimes with Smart (with pt, tf, and onnx support) | ||
if: contains( matrix.os, 'ubuntu' ) | ||
run: smart build --device cpu --onnx -v | ||
|
||
- name: Run Pytest | ||
run: | | ||
echo "SMARTSIM_LOG_LEVEL=debug" >> $GITHUB_ENV | ||
py.test -s --import-mode=importlib -o log_cli=true |
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