forked from CrayLabs/SmartSim
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
9c13783
commit 2950d32
Showing
5 changed files
with
102 additions
and
41 deletions.
There are no files selected for viewing
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
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
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
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