-
Notifications
You must be signed in to change notification settings - Fork 74
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Browse the repository at this point in the history
#8764: Add single-card demo tests and move nightly scripts into new single_card folder
- Loading branch information
Showing
8 changed files
with
101 additions
and
5 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
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,59 @@ | ||
name: "[Single-card] Demo tests" | ||
|
||
on: | ||
workflow_dispatch: | ||
schedule: | ||
- cron: "0 0 * * 1,2,3,4,5" | ||
- cron: "0 */4 * * 0,6" | ||
|
||
jobs: | ||
build-artifact: | ||
uses: ./.github/workflows/build-artifact.yaml | ||
with: | ||
arch: '["wormhole_b0"]' | ||
secrets: inherit | ||
t3000-demo-tests: | ||
needs: build-artifact | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
test-group: [ | ||
{ | ||
name: "N150", | ||
arch: wormhole_b0, | ||
runs-on: ["wormhole_b0", "multi-chip-num-pcie-1", "multi-chip-num-chips-1"], | ||
cmd: './tests/scripts/run_tests.sh --tt-arch wormhole_b0 --pipeline-type demos_single_card --dispatch-mode ""' | ||
}, | ||
{ | ||
name: "N300", | ||
arch: wormhole_b0, | ||
runs-on: ["wormhole_b0", "multi-chip-num-pcie-1", "multi-chip-num-chips-2"], | ||
cmd: './tests/scripts/run_tests.sh --tt-arch wormhole_b0 --pipeline-type demos_single_card --dispatch-mode ""' | ||
} | ||
] | ||
name: ${{ matrix.test-group.name }} | ||
env: | ||
TT_METAL_ENV: ${{ vars.TT_METAL_ENV }} | ||
ARCH_NAME: ${{ matrix.test-group.arch }} | ||
LOGURU_LEVEL: INFO | ||
LD_LIBRARY_PATH: ${{ github.workspace }}/build/lib | ||
environment: dev | ||
runs-on: ${{ matrix.test-group.runs-on }} | ||
steps: | ||
- uses: tenstorrent-metal/metal-workflows/.github/actions/[email protected] | ||
- name: Set up dynamic env vars for build | ||
run: | | ||
echo "TT_METAL_HOME=$(pwd)" >> $GITHUB_ENV | ||
- uses: actions/download-artifact@v4 | ||
with: | ||
name: TTMetal_build_${{ matrix.test-group.arch }} | ||
- name: Extract files | ||
run: tar -xvf ttm_${{ matrix.test-group.arch }}.tar | ||
- uses: ./.github/actions/install-python-deps | ||
- name: Run demo regression tests | ||
timeout-minutes: 150 | ||
run: | | ||
source ${{ github.workspace }}/python_env/bin/activate | ||
cd $TT_METAL_HOME | ||
export PYTHONPATH=$TT_METAL_HOME | ||
${{ matrix.test-group.cmd }} |
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
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
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,27 @@ | ||
#/bin/bash | ||
|
||
set -eo pipefail | ||
|
||
if [[ -z "$TT_METAL_HOME" ]]; then | ||
echo "Must provide TT_METAL_HOME in environment" 1>&2 | ||
exit 1 | ||
fi | ||
|
||
export WH_ARCH_YAML=wormhole_b0_80_arch_eth_dispatch.yaml | ||
|
||
# working on both | ||
pytest --disable-warnings -q -s --input-method=cli --cli-input="YOUR PROMPT GOES HERE!" models/demos/wormhole/falcon7b/demo_wormhole.py::test_demo[user_input0-default_mode_stochastic] | ||
|
||
# working on both | ||
pytest --disable-warnings -q -s --input-method=cli --cli-input="YOUR PROMPT GOES HERE!" models/demos/wormhole/mistral7b/demo/demo.py | ||
|
||
# working on both | ||
pytest --disable-warnings -q -s --input-method=cli --cli-input="YOUR PROMPT GOES HERE!" models/demos/mamba/demo/demo.py | ||
|
||
# working on both | ||
pytest --disable-warnings --input-path="models/demos/wormhole/stable_diffusion/demo/input_data.json" models/demos/wormhole/stable_diffusion/demo/demo.py::test_demo | ||
|
||
# Not working on N150, working on N300 | ||
unset WH_ARCH_YAML | ||
rm -rf built | ||
pytest --disable-warnings models/demos/metal_BERT_large_11/demo/demo.py::test_demo[models/demos/metal_BERT_large_11/demo/input_data.json-1-batch_7] |