Skip to content

IFU 2022-05-16 #3

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 28 commits into from
May 16, 2022
Merged

IFU 2022-05-16 #3

merged 28 commits into from
May 16, 2022

Conversation

jeffdaily
Copy link

No description provided.

malfet and others added 28 commits March 21, 2022 17:52
As this library is present in NVIDIA's cudatoolkit package, but is
missing from the anaconda one

Partially addresses pytorch/pytorch#74473
Co-authored-by: pbialecki <[email protected]>
Co-authored-by: Andrey Talman <[email protected]>
Update CUDA update documentation
* Package cudnn binaries into cuda-11.3 build
* Package cupti binary into cuda-11.5 build

Fixes pytorch/pytorch#74779
* Build libtorch and manywheel for 11.6

* Make sure correct version of magma is installed

Magma version was updated in conda. Hence this update.

* Fix typo

Fix typo

Co-authored-by: pbialecki <[email protected]>
Co-authored-by: Andrey Talman <[email protected]>
Signed-off-by: Eli Uriegas <[email protected]>
…ytorch#990)

The target of this commit is to add the support for a new linux
cpu pip wheel file built with _GLIBCXX_USE_CXX11_ABI=1.

Currently, linux wheels are built in a system based on CentOS7
and devtoolset7, and CXX11_ABI is ignored by the compiler. The
same issue with devtoolset8 and devtoolset9, and so we add a Docker
file (Dockerfile_cxx11-abi) with Ubuntu 18.04 as base image to
support CXX11_ABI=1, by referring the Dockerfile for libtorch.

To build the new docker image with CXX11_ABI support, run:
GPU_ARCH_TYPE=cpu-cxx11-abi manywheel/build_docker.sh
or
manywheel/build_all_docker.sh

To build a linux cpu pip wheel with CXX11_ABI within this image, run:
// the below settings are special for this image
export DESIRED_CUDA=cpu-cxx11-abi   # change from cpu for wheel name
export GPU_ARCH_TYPE=cpu-cxx11-abi  # change from cpu for build.sh
export DOCKER_IMAGE=pytorch/manylinuxcxx11-abi-builder:cpu-cxx11-abi
export DESIRED_DEVTOOLSET=cxx11-abi

// the below settings are as usual
export BINARY_ENV_FILE=/tmp/env
export BUILDER_ROOT=/builder
export DESIRED_PYTHON=3.7   # or 3.8, 3.9, etc.
export IS_GHA=1
export PACKAGE_TYPE=manywheel
export PYTORCH_FINAL_PACKAGE_DIR=/artifacts
export PYTORCH_ROOT=/pytorch
export GITHUB_WORKSPACE=/your_path_to_workspace

// the '-e DESIRED_DEVTOOLSET' below is newly added for this container,
// others are as usual
set -x
  mkdir -p artifacts/
  container_name=$(docker run \
    -e BINARY_ENV_FILE \
    -e BUILDER_ROOT \
    -e DESIRED_CUDA \
    -e DESIRED_PYTHON \
    -e GPU_ARCH_TYPE \
    -e IS_GHA \
    -e PACKAGE_TYPE \
    -e PYTORCH_FINAL_PACKAGE_DIR \
    -e PYTORCH_ROOT \
    -e DOCKER_IMAGE \
    -e DESIRED_DEVTOOLSET \
    --tty \
    --detach \
    -v "${GITHUB_WORKSPACE}/pytorch:/pytorch" \
    -v "${GITHUB_WORKSPACE}/builder:/builder" \
    -v "${RUNNER_TEMP}/artifacts:/artifacts" \
    -w / \
    "${DOCKER_IMAGE}"
  )

// build pip wheel as usual,
// and the built wheel file name looks like: torch-1.12.0.dev20220312+cpu.cxx11.abi-cp37-cp37m-linux_x86_64.whl
docker exec -t -w "${PYTORCH_ROOT}" "${container_name}" bash -c "bash .circleci/scripts/binary_populate_env.sh"
docker exec -t "${container_name}" bash -c "source ${BINARY_ENV_FILE} && bash /builder/manywheel/build.sh"

// to verify the built wheel file, we'll see 'True'
$ pip install torch-1.12.0.dev20220312+cpu.cxx11.abi-cp37-cp37m-linux_x86_64.whl
$ python -c 'import torch; print(torch._C._GLIBCXX_USE_CXX11_ABI)'
True

Co-authored-by: Guo Yejun <[email protected]>
Co-authored-by: Zhu Hong <[email protected]>

Co-authored-by: Guo Yejun <[email protected]>
* pin cmake

* updated some more places

* Apply suggestions from code review

Co-authored-by: Nikita Shulga <[email protected]>

* remove more pins

* removed whitespace

Co-authored-by: Nikita Shulga <[email protected]>
Also, updated `is_reverted` function to detect GHF reverts
* Manywheel and conda builds for CUDA 11.6

* Fix typo

* Correct comment
Make sure TORCH_CUDA_ARCH_LIST and EXTRA_CAFFE2_CMAKE_FLAGS are set for CUDA 11.6
Fix Typo in CUDA PATH
* Update devtoolset to 9

* Add devtoolset param

* Add exception to CUDA 10

* Devtoolset version
@jeffdaily jeffdaily merged commit 96c3fbd into main May 16, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

9 participants