Skip to content

Commit

Permalink
adding m1 to normal tests and ci
Browse files Browse the repository at this point in the history
  • Loading branch information
udaij12 committed Feb 8, 2024
1 parent ddcee1e commit b10c3c2
Show file tree
Hide file tree
Showing 3 changed files with 68 additions and 56 deletions.
26 changes: 16 additions & 10 deletions .github/workflows/ci_cpu.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,10 @@ on:
workflow_dispatch:
push:
branches:
- master
- M1_changes
pull_request:
branches:
- master
- M1_changes
merge_group:


Expand All @@ -21,9 +21,15 @@ jobs:
strategy:
fail-fast: false
matrix:
os: [ubuntu-20.04, macOS-latest]
os: [ubuntu-20.04, macOS-latest, macos-14]
steps:
- name: Setup Python 3.8
- name: Setup Python for M1
if: matrix.os == 'macos-14'
uses: actions/setup-python@v5
with:
python-version: '3.10'
- name: Setup Python for all other OS
if: matrix.os != 'macos-14'
uses: actions/setup-python@v4
with:
python-version: 3.8
Expand All @@ -50,9 +56,9 @@ jobs:
python torchserve_sanity.py
# Any coverage.xml will be picked up by this step
# Just make sure each coverage.xml is in a different folder
- name: Upload codecov
if: matrix.os == 'ubuntu-20.04'
run : |
curl -Os https://uploader.codecov.io/latest/linux/codecov
chmod +x codecov
./codecov
# - name: Upload codecov
# if: matrix.os == 'ubuntu-20.04'
# run : |
# curl -Os https://uploader.codecov.io/latest/linux/codecov
# chmod +x codecov
# ./codecov
18 changes: 12 additions & 6 deletions .github/workflows/regression_tests_cpu.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,10 @@ name: Run Regression Tests on CPU
on:
push:
branches:
- master
- M1_changes
pull_request:
branches:
- master
- M1_changes
merge_group:

concurrency:
Expand All @@ -15,15 +15,21 @@ concurrency:

jobs:
regression-cpu:
# creates workflows for OS: ubuntu, macOS
# creates workflows for OS: ubuntu, macOS, macOS M1
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [ubuntu-20.04, macOS-latest]
os: [ubuntu-20.04, macOS-latest, macos-14]
steps:
- name: Setup Python 3.8
uses: actions/setup-python@v3
- name: Setup Python for M1
if: matrix.os == 'macos-14'
uses: actions/setup-python@v5
with:
python-version: '3.10'
- name: Setup Python for all other OS
if: matrix.os != 'macos-14'
uses: actions/setup-python@v4
with:
python-version: 3.8
architecture: x64
Expand Down
80 changes: 40 additions & 40 deletions .github/workflows/regression_tests_cpu_m1.yml
Original file line number Diff line number Diff line change
@@ -1,43 +1,43 @@
name: Run Regression Tests on CPU
# name: Run Regression Tests on CPU

on:
push:
branches:
- M1_changes
pull_request:
branches:
- M1_changes
merge_group:
# on:
# push:
# branches:
# - M1_changes
# pull_request:
# branches:
# - M1_changes
# merge_group:

concurrency:
group: ci-cpu-${{ github.workflow }}-${{ github.ref == 'refs/heads/master' && github.run_number || github.ref }}
cancel-in-progress: true
# concurrency:
# group: ci-cpu-${{ github.workflow }}-${{ github.ref == 'refs/heads/master' && github.run_number || github.ref }}
# cancel-in-progress: true

jobs:
regression-cpu:
# creates workflows for Mac OS M1
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [macos-14]
steps:
- name: Setup Python 3.10
uses: actions/setup-python@v5
with:
python-version: '3.10'
- name: Setup Java 17
uses: actions/setup-java@v3
with:
distribution: 'zulu'
java-version: '17'
- name: Checkout TorchServe
uses: actions/checkout@v3
with:
submodules: recursive
- name: Install dependencies
run: |
python ts_scripts/install_dependencies.py --environment=dev
- name: Torchserve Regression Tests
run: |
python test/regression_tests.py
# jobs:
# regression-cpu:
# # creates workflows for Mac OS M1
# runs-on: ${{ matrix.os }}
# strategy:
# fail-fast: false
# matrix:
# os: [macos-14]
# steps:
# - name: Setup Python 3.10
# uses: actions/setup-python@v5
# with:
# python-version: '3.10'
# - name: Setup Java 17
# uses: actions/setup-java@v3
# with:
# distribution: 'zulu'
# java-version: '17'
# - name: Checkout TorchServe
# uses: actions/checkout@v3
# with:
# submodules: recursive
# - name: Install dependencies
# run: |
# python ts_scripts/install_dependencies.py --environment=dev
# - name: Torchserve Regression Tests
# run: |
# python test/regression_tests.py

0 comments on commit b10c3c2

Please sign in to comment.