Skip to content

Binary Validation Workflow - Adding check binary script #1127

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

Merged
merged 43 commits into from
Sep 30, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
43 commits
Select commit Hold shift + click to select a range
f24bf9e
Update action.yml
andysamfb Sep 23, 2022
cf5690e
Update validate-macos-binaries.yml
andysamfb Sep 23, 2022
536d9da
Update validate-linux-binaries.yml
andysamfb Sep 23, 2022
cc98566
Update validate-linux-binaries.yml
andysamfb Sep 23, 2022
64e87fc
Update validate-linux-binaries.yml
andysamfb Sep 27, 2022
94448ae
Update validate-linux-binaries.yml
andysamfb Sep 27, 2022
c9f84cc
Update validate-linux-binaries.yml
andysamfb Sep 27, 2022
05ae7bc
Update validate-linux-binaries.yml
andysamfb Sep 27, 2022
29bebfd
Update validate-linux-binaries.yml
andysamfb Sep 27, 2022
9956bbb
Update validate-linux-binaries.yml
andysamfb Sep 27, 2022
a6f4520
Update validate-linux-binaries.yml
andysamfb Sep 28, 2022
4b49218
Update validate-linux-binaries.yml
andysamfb Sep 28, 2022
a91f16d
Update validate-linux-binaries.yml
andysamfb Sep 28, 2022
c9fbfa4
Update validate-linux-binaries.yml
andysamfb Sep 28, 2022
0377e64
Update validate-linux-binaries.yml
andysamfb Sep 28, 2022
ca90b44
Update validate-linux-binaries.yml
andysamfb Sep 28, 2022
4745640
Update validate-linux-binaries.yml
andysamfb Sep 28, 2022
85d993a
Update validate-linux-binaries.yml
andysamfb Sep 28, 2022
8cd5f55
Update validate-linux-binaries.yml
andysamfb Sep 28, 2022
6aed847
Update validate-linux-binaries.yml
andysamfb Sep 28, 2022
e1a5b8e
Update validate-linux-binaries.yml
andysamfb Sep 28, 2022
ea5b058
Update validate-linux-binaries.yml
andysamfb Sep 28, 2022
e39578b
Update validate-linux-binaries.yml
andysamfb Sep 28, 2022
863e94b
Update validate-linux-binaries.yml
andysamfb Sep 28, 2022
0c5e9d9
Update validate-linux-binaries.yml
andysamfb Sep 28, 2022
ade31de
Update validate-linux-binaries.yml
andysamfb Sep 28, 2022
72e923d
Update validate-linux-binaries.yml
andysamfb Sep 28, 2022
f7c7496
Update validate-linux-binaries.yml
andysamfb Sep 28, 2022
f565a9a
Update validate-linux-binaries.yml
andysamfb Sep 28, 2022
bece7c3
Update validate-linux-binaries.yml
andysamfb Sep 28, 2022
015b24b
Update validate-linux-binaries.yml
andysamfb Sep 28, 2022
9adc686
Update validate-linux-binaries.yml
andysamfb Sep 28, 2022
dd29553
Update validate-linux-binaries.yml
andysamfb Sep 28, 2022
c34b3b4
Update validate-linux-binaries.yml
andysamfb Sep 28, 2022
c605ea1
Update validate-linux-binaries.yml
andysamfb Sep 28, 2022
56d2a43
Update validate-linux-binaries.yml
andysamfb Sep 28, 2022
dd7d5c1
Update validate-linux-binaries.yml
andysamfb Sep 28, 2022
0993315
Update validate-linux-binaries.yml
andysamfb Sep 28, 2022
ec92aba
Update validate-linux-binaries.yml
andysamfb Sep 28, 2022
9e2bff9
Update validate-linux-binaries.yml
andysamfb Sep 29, 2022
f1c7deb
Update validate-linux-binaries.yml
andysamfb Sep 29, 2022
a5f42af
Update validate-linux-binaries.yml
andysamfb Sep 29, 2022
eb33e95
Merge branch 'pytorch:main' into main
andysamfb Sep 29, 2022
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
19 changes: 19 additions & 0 deletions .github/actions/validate-binary/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,18 @@ inputs:
description: 'Python version'
required: true
default: '3.9'
desired_cuda:
description: 'Desired CUDA'
required: true
default: 'cpu'
dev_toolset:
description: 'Dev Toolset'
required: false
default: ''
package_type:
description: 'Package Type'
required: true
default: 'conda'
target_os:
description: 'Target OS linux or macos'
required: false
Expand Down Expand Up @@ -49,9 +61,16 @@ runs:
GPU_ARCH_TYPE: ${{ inputs.gpu_arch_type }}
INSTALLATION: ${{ inputs.installation }}
ENV_NAME: conda-env-${{ github.run_id }}
DESIRED_PYTHON: ${{ inputs.python_version }}
DESIRED_CUDA: ${{ inputs.desired_cuda }}
DESIRED_DEVTOOLSET: ${{ inputs.dev_toolset }}
PACKAGE_TYPE: ${{ inputs.package_type }}
run: |
set -ex
conda create -yp ${ENV_NAME} python=${{ inputs.python_version }} numpy
conda run -p ${ENV_NAME} $INSTALLATION
conda run -p ${ENV_NAME} python3 ./test/smoke_test/smoke_test.py
export LD_LIBRARY_PATH="$(dirname $(which python))/lib"
export LD_LIBRARY_PATH=${LD_LIBRARY_PATH}:/usr/local/cuda/lib
conda run -p ${ENV_NAME} env LD_LIBRARY_PATH=$LD_LIBRARY_PATH bash ${PWD}/check_binary.sh
conda env remove -p ${ENV_NAME}
32 changes: 31 additions & 1 deletion .github/workflows/validate-linux-binaries.yml
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,10 @@ jobs:
gpu_arch_ver: ${{ matrix.gpu_arch_version }}
installation: ${{ matrix.installation }}
python_version: ${{ matrix.python_version }}
desired_cuda: ${{ matrix.desired_cuda }}
dev_toolset: ''
package_type: conda
target_os: linux
validate-linux-binaries-wheels:
needs: generate-linux-wheel-matrix
strategy:
Expand All @@ -69,22 +73,48 @@ jobs:
gpu_arch_ver: ${{ matrix.gpu_arch_version }}
installation: ${{ matrix.installation }}
python_version: ${{ matrix.python_version }}
desired_cuda: ${{ matrix.desired_cuda }}
dev_toolset: ''
package_type: wheel
target_os: linux

validate-linux-libtorch-binaries:
needs: generate-linux-libtorch-matrix
strategy:
matrix:
${{ fromJson(needs.generate-linux-libtorch-matrix.outputs.matrix) }}
fail-fast: false
runs-on: "ubuntu-20.04"
runs-on: ${{ matrix.validation_runner }}
env:
PYTHON_VERSION: ${{ matrix.python_version }}
steps:
- name: Checkout PyTorch builder
uses: actions/checkout@v2
- name: Install Conda
uses: conda-incubator/setup-miniconda@v2
with:
python-version: ${{ matrix.python_version }}
auto-update-conda: true
miniconda-version: "latest"
activate-environment: testenv
- name: Install pytorch and smoke test
shell: bash
env:
INSTALLATION: ${{ matrix.installation }}
ENV_NAME: conda-env-${{ github.run_id }}
DESIRED_PYTHON: ${{ matrix.python_version }}
DESIRED_CUDA: ${{ matrix.desired_cuda }}
DESIRED_DEVTOOLSET: ${{ matrix.devtoolset }}
PACKAGE_TYPE: libtorch
run: |
sudo apt-get install unzip -y
set -ex
curl ${INSTALLATION} -o libtorch.zip
unzip libtorch.zip
conda create -yp ${ENV_NAME} python=${{ matrix.python_version }} numpy
export LD_LIBRARY_PATH="$(dirname $(which python))/lib"
export LD_LIBRARY_PATH=${LD_LIBRARY_PATH}:/usr/local/cuda/lib
if [[ ${{ matrix.libtorch_variant }} == "static-with-deps" ]]; then
conda run -p ${ENV_NAME} --cwd libtorch env LD_LIBRARY_PATH=${LD_LIBRARY_PATH} bash ./../check_binary.sh
fi
conda env remove -p ${ENV_NAME}
8 changes: 8 additions & 0 deletions .github/workflows/validate-macos-binaries.yml
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,8 @@ jobs:
gpu_arch_ver: ${{ matrix.gpu_arch_version }}
installation: ${{ matrix.installation }}
python_version: ${{ matrix.python_version }}
desired_cuda: ${{ matrix.desired_cuda }}
package_type: conda
target_os: macos
validate-macos-arm64-binaries-wheel:
needs: generate-macos-arm64-wheel-matrix
Expand All @@ -76,6 +78,8 @@ jobs:
gpu_arch_ver: ${{ matrix.gpu_arch_version }}
installation: ${{ matrix.installation }}
python_version: ${{ matrix.python_version }}
desired_cuda: ${{ matrix.desired_cuda }}
package_type: wheel
target_os: macos
validate-macos-x86_64-binaries-conda:
needs: generate-macos-x86_64-conda-matrix
Expand All @@ -92,6 +96,8 @@ jobs:
gpu_arch_ver: ${{ matrix.gpu_arch_version }}
installation: ${{ matrix.installation }}
python_version: ${{ matrix.python_version }}
desired_cuda: ${{ matrix.desired_cuda }}
package_type: conda
target_os: macos
validate-macos-x86_64-binaries-wheel:
needs: generate-macos-x86_64-wheel-matrix
Expand All @@ -108,4 +114,6 @@ jobs:
gpu_arch_ver: ${{ matrix.gpu_arch_version }}
installation: ${{ matrix.installation }}
python_version: ${{ matrix.python_version }}
desired_cuda: ${{ matrix.desired_cuda }}
package_type: wheel
target_os: macos