From ce78d622b2c82148d60175e643c71e1ae941dd61 Mon Sep 17 00:00:00 2001 From: Jerry G <124635598+jgongd@users.noreply.github.com> Date: Tue, 3 Dec 2024 22:10:07 -0500 Subject: [PATCH] ci: fix apex installation [DT-5] (#10233) CI failed because the build was attempted on the master branch of the Apex repo. For reliability, it needs to be built on the latest release instead. --- .circleci/real_config.yml | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/.circleci/real_config.yml b/.circleci/real_config.yml index 9d0eceb9a9e..47504666d0f 100644 --- a/.circleci/real_config.yml +++ b/.circleci/real_config.yml @@ -517,13 +517,18 @@ commands: steps: - run: name: Install Nvidia Apex - description: "Apex installation needs Cuda 12.1 because Pytorch binaries were compiled by Cuda 12.1." command: | if ! pip show apex; then + # Ninja speeds up Apex compilation. + if ! pip show ninja; then + pip install ninja + fi + # Apex installation needs Cuda 12.1 because Pytorch binaries were compiled by Cuda 12.1. wget https://developer.download.nvidia.com/compute/cuda/12.1.0/local_installers/cuda_12.1.0_530.30.02_linux.run sudo sh cuda_12.1.0_530.30.02_linux.run --toolkit --silent nvcc --version git clone https://github.com/NVIDIA/apex ~/apex + git -C ~/apex checkout tags/24.04.01 pip install -v --disable-pip-version-check --no-cache-dir --no-build-isolation --config-settings "--build-option=--cpp_ext" --config-settings "--build-option=--cuda_ext" ~/apex fi