Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: new Test Dashboard workflow #28750

Merged
merged 36 commits into from
May 22, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
36 commits
Select commit Hold shift + click to select a range
4e1697c
initial workflow to run tests on a cron schedule
Sam-Armstrong May 19, 2024
fcd2ec4
test
Sam-Armstrong May 19, 2024
7deeb65
add tensorflow frontends to workflow
Sam-Armstrong May 19, 2024
5515891
change default num-examples to 15
Sam-Armstrong May 19, 2024
114a706
only fail each job if the pytest command itself doesn't run correctly
Sam-Armstrong May 19, 2024
e246c7d
fix
Sam-Armstrong May 19, 2024
1533e8c
print the pytest exit code
Sam-Armstrong May 19, 2024
965bb51
fix
Sam-Armstrong May 19, 2024
94ebd4d
check this fails the torch frontend jobs
Sam-Armstrong May 19, 2024
edf5c5e
fix
Sam-Armstrong May 19, 2024
7169136
fix
Sam-Armstrong May 19, 2024
31b71a9
fix
Sam-Armstrong May 19, 2024
8895791
fix
Sam-Armstrong May 19, 2024
a65af51
default exit code to 2
Sam-Armstrong May 19, 2024
0b35cdb
fix
Sam-Armstrong May 19, 2024
ed502c9
fix
Sam-Armstrong May 19, 2024
d09b714
fix
Sam-Armstrong May 19, 2024
f62ffa5
fix
Sam-Armstrong May 19, 2024
984795e
fix
Sam-Armstrong May 19, 2024
a3ddca7
fix
Sam-Armstrong May 19, 2024
fba64d6
fix pytest exiting the script prematurely
Sam-Armstrong May 19, 2024
eae2958
simplify workflow
Sam-Armstrong May 19, 2024
904208d
add ivy functional api tests to workflow
Sam-Armstrong May 19, 2024
b44c3cc
populate the scripts
Sam-Armstrong May 20, 2024
4399375
split workflow into submodules to reduce likelihood of segfaults
Sam-Armstrong May 20, 2024
3110e72
fix workflow error check bug
Sam-Armstrong May 20, 2024
7890a82
add json reporting to pytest in the scripts
Sam-Armstrong May 20, 2024
86c566c
run job for each backend
Sam-Armstrong May 20, 2024
2f4a8df
initial job to commit test results
Sam-Armstrong May 20, 2024
2aae662
push test results to remote database
Sam-Armstrong May 20, 2024
010e6df
Merge branch 'main' into test-dashboard
Sam-Armstrong May 20, 2024
4170a4d
fix incorrect filter criteria
Sam-Armstrong May 20, 2024
919317d
update workflow link
Sam-Armstrong May 20, 2024
60e3030
do not run on push
Sam-Armstrong May 21, 2024
75cd402
cleanup
Sam-Armstrong May 21, 2024
13200b1
lint
Sam-Armstrong May 21, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
371 changes: 371 additions & 0 deletions .github/workflows/update-test-dashboard.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,371 @@
# Workflow to run all the tests for the ivy frontends and functional api,
# and update the remote database with the results

name: update-test-dashboard
on:
workflow_dispatch:
schedule:
- cron: "0 0 * * *"
permissions:
actions: read
jobs:
update-frontends-torch:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
submodule : [ blas_and_lapack_ops, comparison_ops, creation_ops, dtype, func_wrapper,
indexing_slicing_joining_mutating_ops, linalg, miscellaneous_ops,
pointwise_ops, random_sampling, reduction_ops, special_funcs,
spectral_ops, tensor_functions, tensor, utilities ]
backend : [ jax, numpy, tensorflow, torch ]
steps:
- name: Checkout 🛎️Ivy
uses: actions/checkout@v3
with:
path: ivy
persist-credentials: false

- name: Install ivy
run: |
cd ivy
sudo pip3 install -e .

- name: Run Tests
id: tests
run: |
cd ivy
pip3 install pymongo
pip3 install pytest-json-report
docker run --rm -v "$(pwd)":/ivy -v "$(pwd)"/.hypothesis:/.hypothesis unifyai/ivy:latest scripts/update_test_dashboard/update_torch_frontends.sh ${{ matrix.submodule }} ${{ matrix.backend }} https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}/job/${{ github.job }}?check_suite_focus=true ${{ secrets.IVY_DASHBOARD_DB_KEY }}

update-frontends-torch-nn-functional:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
submodule : [ convolution_functions, distance_functions, dropout_functions, layer_functions,
linear_functions, loss_functions, non_linear_activation_functions, norms,
pooling_functions, sparse_functions, vision_functions ]
backend : [ jax, numpy, tensorflow, torch ]
steps:
- name: Checkout 🛎️Ivy
uses: actions/checkout@v3
with:
path: ivy
persist-credentials: false

- name: Install ivy
run: |
cd ivy
sudo pip3 install -e .

- name: Run Tests
id: tests
run: |
cd ivy
pip3 install pymongo
pip3 install pytest-json-report
docker run --rm -v "$(pwd)":/ivy -v "$(pwd)"/.hypothesis:/.hypothesis unifyai/ivy:latest scripts/update_test_dashboard/update_torch_nn_functional_frontends.sh ${{ matrix.submodule }} ${{ matrix.backend }} https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}/job/${{ github.job }}?check_suite_focus=true ${{ secrets.IVY_DASHBOARD_DB_KEY }}

update-frontends-tensorflow:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
submodule : [ __operators__, dtypes, func_wrapper, general_functions, linalg, math, nest, nn,
random, raw_ops, signal, tensor, tensorarray, tensorshape ]
backend : [ jax, numpy, tensorflow, torch ]
steps:
- name: Checkout 🛎️Ivy
uses: actions/checkout@v3
with:
path: ivy
persist-credentials: false

- name: Install ivy
run: |
cd ivy
sudo pip3 install -e .

- name: Run Tests
id: tests
run: |
cd ivy
pip3 install pymongo
pip3 install pytest-json-report
docker run --rm -v "$(pwd)":/ivy -v "$(pwd)"/.hypothesis:/.hypothesis unifyai/ivy:latest scripts/update_test_dashboard/update_tensorflow_frontends.sh ${{ matrix.submodule }} ${{ matrix.backend }} https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}/job/${{ github.job }}?check_suite_focus=true ${{ secrets.IVY_DASHBOARD_DB_KEY }}

update-frontends-tensorflow-keras:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
submodule : [ activations, backend ]
backend : [ jax, numpy, tensorflow, torch ]
steps:
- name: Checkout 🛎️Ivy
uses: actions/checkout@v3
with:
path: ivy
persist-credentials: false

- name: Install ivy
run: |
cd ivy
sudo pip3 install -e .

- name: Run Tests
id: tests
run: |
cd ivy
pip3 install pymongo
pip3 install pytest-json-report
docker run --rm -v "$(pwd)":/ivy -v "$(pwd)"/.hypothesis:/.hypothesis unifyai/ivy:latest scripts/update_test_dashboard/update_tensorflow_keras_frontends.sh ${{ matrix.submodule }} ${{ matrix.backend }} https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}/job/${{ github.job }}?check_suite_focus=true ${{ secrets.IVY_DASHBOARD_DB_KEY }}

update-frontends-jax:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
submodule : [ array, func_wrapper, general_functions, random ]
backend : [ jax, numpy, tensorflow, torch ]
steps:
- name: Checkout 🛎️Ivy
uses: actions/checkout@v3
with:
path: ivy
persist-credentials: false

- name: Install ivy
run: |
cd ivy
sudo pip3 install -e .

- name: Run Tests
id: tests
run: |
cd ivy
pip3 install pymongo
pip3 install pytest-json-report
docker run --rm -v "$(pwd)":/ivy -v "$(pwd)"/.hypothesis:/.hypothesis unifyai/ivy:latest scripts/update_test_dashboard/update_jax_frontends.sh ${{ matrix.submodule }} ${{ matrix.backend }} https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}/job/${{ github.job }}?check_suite_focus=true ${{ secrets.IVY_DASHBOARD_DB_KEY }}

update-frontends-jax-lax:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
submodule : [ control_flow_operators, custom_gradient_operators, linalg, operators ]
backend : [ jax, numpy, tensorflow, torch ]
steps:
- name: Checkout 🛎️Ivy
uses: actions/checkout@v3
with:
path: ivy
persist-credentials: false

- name: Install ivy
run: |
cd ivy
sudo pip3 install -e .

- name: Run Tests
id: tests
run: |
cd ivy
pip3 install pymongo
pip3 install pytest-json-report
docker run --rm -v "$(pwd)":/ivy -v "$(pwd)"/.hypothesis:/.hypothesis unifyai/ivy:latest scripts/update_test_dashboard/update_jax_lax_frontends.sh ${{ matrix.submodule }} ${{ matrix.backend }} https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}/job/${{ github.job }}?check_suite_focus=true ${{ secrets.IVY_DASHBOARD_DB_KEY }}

update-frontends-jax-nn:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
submodule : [ non_linear_activations ]
backend : [ jax, numpy, tensorflow, torch ]
steps:
- name: Checkout 🛎️Ivy
uses: actions/checkout@v3
with:
path: ivy
persist-credentials: false

- name: Install ivy
run: |
cd ivy
sudo pip3 install -e .

- name: Run Tests
id: tests
run: |
cd ivy
pip3 install pymongo
pip3 install pytest-json-report
docker run --rm -v "$(pwd)":/ivy -v "$(pwd)"/.hypothesis:/.hypothesis unifyai/ivy:latest scripts/update_test_dashboard/update_jax_nn_frontends.sh ${{ matrix.submodule }} ${{ matrix.backend }} https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}/job/${{ github.job }}?check_suite_focus=true ${{ secrets.IVY_DASHBOARD_DB_KEY }}

update-frontends-jax-numpy:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
submodule : [ creation, dtype, fft, indexing, linalg, logic, manipulations,
mathematical_functions, searching_sorting, statistical ]
backend : [ jax, numpy, tensorflow, torch ]
steps:
- name: Checkout 🛎️Ivy
uses: actions/checkout@v3
with:
path: ivy
persist-credentials: false

- name: Install ivy
run: |
cd ivy
sudo pip3 install -e .

- name: Run Tests
id: tests
run: |
cd ivy
pip3 install pymongo
pip3 install pytest-json-report
docker run --rm -v "$(pwd)":/ivy -v "$(pwd)"/.hypothesis:/.hypothesis unifyai/ivy:latest scripts/update_test_dashboard/update_jax_numpy_frontends.sh ${{ matrix.submodule }} ${{ matrix.backend }} https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}/job/${{ github.job }}?check_suite_focus=true ${{ secrets.IVY_DASHBOARD_DB_KEY }}

update-frontends-numpy:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
submodule : [ broadcast, data_type_routines, fft, indexing_routines, linalg, logic, manipulation_routines,
mathematical_functions, matrix, ndarray, random, sorting_searching_counting, statistics, ufunc ]
backend : [ jax, numpy, tensorflow, torch ]
steps:
- name: Checkout 🛎️Ivy
uses: actions/checkout@v3
with:
path: ivy
persist-credentials: false

- name: Install ivy
run: |
cd ivy
sudo pip3 install -e .

- name: Run Tests
id: tests
run: |
cd ivy
pip3 install pymongo
pip3 install pytest-json-report
docker run --rm -v "$(pwd)":/ivy -v "$(pwd)"/.hypothesis:/.hypothesis unifyai/ivy:latest scripts/update_test_dashboard/update_numpy_frontends.sh ${{ matrix.submodule }} ${{ matrix.backend }} https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}/job/${{ github.job }}?check_suite_focus=true ${{ secrets.IVY_DASHBOARD_DB_KEY }}

update-ivy-core:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
submodule : [ creation, device, dtype, elementwise, general, gradients, linalg, manipulation, meta,
nest, random, searching, set, sorting, statistical, utility ]
backend : [ jax, numpy, tensorflow, torch ]
steps:
- name: Checkout 🛎️Ivy
uses: actions/checkout@v3
with:
path: ivy
persist-credentials: false

- name: Install ivy
run: |
cd ivy
sudo pip3 install -e .

- name: Run Tests
id: tests
run: |
cd ivy
pip3 install pymongo
pip3 install pytest-json-report
docker run --rm -v "$(pwd)":/ivy -v "$(pwd)"/.hypothesis:/.hypothesis unifyai/ivy:latest scripts/update_test_dashboard/update_ivy_core.sh ${{ matrix.submodule }} ${{ matrix.backend }} https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}/job/${{ github.job }}?check_suite_focus=true ${{ secrets.IVY_DASHBOARD_DB_KEY }}

update-ivy-experimental-core:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
submodule : [ creation, elementwise, general, gradients, linalg, manipulation,
random, searching, sorting, sparse_array, statistical, utility ]
backend : [ jax, numpy, tensorflow, torch ]
steps:
- name: Checkout 🛎️Ivy
uses: actions/checkout@v3
with:
path: ivy
persist-credentials: false

- name: Install ivy
run: |
cd ivy
sudo pip3 install -e .

- name: Run Tests
id: tests
run: |
cd ivy
pip3 install pymongo
pip3 install pytest-json-report
docker run --rm -v "$(pwd)":/ivy -v "$(pwd)"/.hypothesis:/.hypothesis unifyai/ivy:latest scripts/update_test_dashboard/update_ivy_experimental_core.sh ${{ matrix.submodule }} ${{ matrix.backend }} https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}/job/${{ github.job }}?check_suite_focus=true ${{ secrets.IVY_DASHBOARD_DB_KEY }}

update-ivy-experimental-nn:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
submodule : [ activations, layers, losses, norms ]
backend : [ jax, numpy, tensorflow, torch ]
steps:
- name: Checkout 🛎️Ivy
uses: actions/checkout@v3
with:
path: ivy
persist-credentials: false

- name: Install ivy
run: |
cd ivy
sudo pip3 install -e .

- name: Run Tests
id: tests
run: |
cd ivy
pip3 install pymongo
pip3 install pytest-json-report
docker run --rm -v "$(pwd)":/ivy -v "$(pwd)"/.hypothesis:/.hypothesis unifyai/ivy:latest scripts/update_test_dashboard/update_ivy_experimental_nn.sh ${{ matrix.submodule }} ${{ matrix.backend }} https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}/job/${{ github.job }}?check_suite_focus=true ${{ secrets.IVY_DASHBOARD_DB_KEY }}

update-ivy-nn:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
submodule : [ activations, layers, losses, norms ]
backend : [ jax, numpy, tensorflow, torch ]
steps:
- name: Checkout 🛎️Ivy
uses: actions/checkout@v3
with:
path: ivy
persist-credentials: false

- name: Install ivy
run: |
cd ivy
sudo pip3 install -e .

- name: Run Tests
id: tests
run: |
cd ivy
pip3 install pymongo
pip3 install pytest-json-report
docker run --rm -v "$(pwd)":/ivy -v "$(pwd)"/.hypothesis:/.hypothesis unifyai/ivy:latest scripts/update_test_dashboard/update_ivy_nn.sh ${{ matrix.submodule }} ${{ matrix.backend }} https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}/job/${{ github.job }}?check_suite_focus=true ${{ secrets.IVY_DASHBOARD_DB_KEY }}
2 changes: 1 addition & 1 deletion ivy_tests/conftest.py
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ def pytest_addoption(parser):
"-N",
"--num-examples",
action="store",
default=5,
default=15,
type=int,
help="set max examples generated by Hypothesis",
)
Expand Down
Loading
Loading