From b2478dff7ff09a7648c7ba6da0e289f40d4e6874 Mon Sep 17 00:00:00 2001 From: Xu Zhao Date: Thu, 19 Dec 2024 19:05:54 -0500 Subject: [PATCH] Save cpu cores to docker build --- .github/workflows/docker.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/docker.yaml b/.github/workflows/docker.yaml index 23816c7..689a037 100644 --- a/.github/workflows/docker.yaml +++ b/.github/workflows/docker.yaml @@ -46,8 +46,8 @@ jobs: df -h # show cpu lscpu - docker build . --memory 80g --shm-size 4g --build-arg TRITONBENCH_BRANCH="${branch_name}" --build-arg FORCE_DATE="${NIGHTLY_DATE}" \ - -f tritonbench-nightly.dockerfile -t ghcr.io/pytorch-labs/tritonbench:latest + taskset -c 4-31 docker build . --memory 80g --shm-size 4g --build-arg TRITONBENCH_BRANCH="${branch_name}" --build-arg FORCE_DATE="${NIGHTLY_DATE}" \ + -f tritonbench-nightly.dockerfile -t ghcr.io/pytorch-labs/tritonbench:latest # Extract pytorch version from the docker PYTORCH_VERSION=$(docker run -e SETUP_SCRIPT="${SETUP_SCRIPT}" ghcr.io/pytorch-labs/tritonbench:latest bash -c '. "${SETUP_SCRIPT}"; python -c "import torch; print(torch.__version__)"') export DOCKER_TAG=$(awk '{match($0, /dev[0-9]+/, arr); print arr[0]}' <<< "${PYTORCH_VERSION}")