forked from jax-ml/jax
-
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
Showing
3 changed files
with
1,727 additions
and
0 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,42 @@ | ||
# JAX-Metal plugin CI | ||
|
||
name: Jax-Metal CI | ||
on: | ||
workflow_dispatch: # allows triggering the workflow run manually | ||
|
||
jobs: | ||
jax-metal-plugin-test: | ||
|
||
strategy: | ||
fail-fast: false # don't cancel all jobs on failure | ||
matrix: | ||
jaxlib-version: ["plugin_latest"] | ||
name: "Jax-Metal plugin test (jaxlib=${{ matrix.jaxlib-version }})" | ||
runs-on: [self-hosted, macOS, ARM64] | ||
|
||
steps: | ||
- name: Get repo | ||
uses: actions/checkout@v4 | ||
with: | ||
path: jax | ||
- name: Setup build and test enviroment | ||
run: | | ||
rm -rf ${GITHUB_WORKSPACE}/jax-metal-venv | ||
python3 -m venv ${GITHUB_WORKSPACE}/jax-metal-venv | ||
source ${GITHUB_WORKSPACE}/jax-metal-venv/bin/activate | ||
pip install -U pip numpy wheel | ||
pip install jax-metal absl-py pytest | ||
if [[ "${{ matrix.jaxlib-version }}" == "nightly" ]]; then | ||
pip install --pre jaxlib \ | ||
-f https://storage.googleapis.com/jax-releases/jaxlib_nightly_releases.html | ||
fi; | ||
cd jax | ||
pip install . | ||
- name: Run test | ||
run: | | ||
source ${GITHUB_WORKSPACE}/jax-metal-venv/bin/activate | ||
export ENABLE_PJRT_COMPATIBILITY=1 | ||
cd jax | ||
pytest tests/lax_metal_test.py | ||
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
Oops, something went wrong.