Skip to content

Commit

Permalink
Fix Linux smoke tests (#1906)
Browse files Browse the repository at this point in the history
  • Loading branch information
Caroline Chen committed Oct 19, 2021
1 parent c910212 commit d2634d8
Show file tree
Hide file tree
Showing 3 changed files with 62 additions and 23 deletions.
52 changes: 35 additions & 17 deletions .circleci/config.yml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

28 changes: 23 additions & 5 deletions .circleci/config.yml.in
Original file line number Diff line number Diff line change
Expand Up @@ -93,10 +93,8 @@ binary_common: &binary_common
smoke_test_common: &smoke_test_common
<<: *binary_common
docker:
- image: 308535385114.dkr.ecr.us-east-1.amazonaws.com/torchaudio/smoke_test:56c846a5-acaa-41a7-92f5-46ec66186c61
aws_auth:
aws_access_key_id: ${ECR_AWS_ACCESS_KEY}
aws_secret_access_key: ${ECR_AWS_SECRET_ACCESS_KEY}
- image: pytorch/torchaudio_unittest_base:smoke_test-20211019
resource_class: large

jobs:
circleci_consistency:
Expand Down Expand Up @@ -336,6 +334,26 @@ jobs:
source /usr/local/etc/profile.d/conda.sh && conda activate python${PYTHON_VERSION}
python -c "import torchaudio"

smoke_test_linux_conda_gpu:
<<: *smoke_test_common
steps:
- attach_workspace:
at: ~/workspace
- designate_upload_channel
- load_conda_channel_flags
- run:
name: install binaries
command: |
set -x
source /usr/local/etc/profile.d/conda.sh && conda activate python${PYTHON_VERSION}
conda install -v -y -c pytorch-${UPLOAD_CHANNEL} pytorch cudatoolkit=${CU_VERSION:2:2}.${CU_VERSION:4} -c conda-forge
conda install -v -y -c file://$HOME/workspace/conda-bld torchaudio
- run:
name: smoke test
command: |
source /usr/local/etc/profile.d/conda.sh && conda activate python${PYTHON_VERSION}
python -c "import torchaudio"

smoke_test_linux_pip:
<<: *smoke_test_common
steps:
Expand All @@ -348,7 +366,7 @@ jobs:
command: |
set -x
source /usr/local/etc/profile.d/conda.sh && conda activate python${PYTHON_VERSION}
pip install $(ls ~/workspace/torchaudio*.whl) -f "https://download.pytorch.org/whl/${UPLOAD_CHANNEL}/torch_${UPLOAD_CHANNEL}.html"
pip install $(ls ~/workspace/torchaudio*.whl) -f "https://download.pytorch.org/whl/${UPLOAD_CHANNEL}/${CU_VERSION}/torch_${UPLOAD_CHANNEL}.html"
- run:
name: smoke test
command: |
Expand Down
5 changes: 4 additions & 1 deletion .circleci/regenerate.py
Original file line number Diff line number Diff line change
Expand Up @@ -190,7 +190,10 @@ def generate_smoketest_workflow(pydistro, base_workflow_name, filter_branch, pyt
if filter_branch:
d["filters"] = gen_filter_branch_tree(filter_branch)

return {f"smoke_test_{os_type}_{pydistro}": d}
smoke_name = f"smoke_test_{os_type}_{pydistro}"
if pydistro == "conda" and os_type == "linux" and cu_version != "cpu":
smoke_name += "_gpu"
return {smoke_name: d}


def indent(indentation, data_list):
Expand Down

0 comments on commit d2634d8

Please sign in to comment.