Skip to content

Commit

Permalink
first test
Browse files Browse the repository at this point in the history
  • Loading branch information
IlyasMoutawwakil committed Mar 12, 2024
1 parent fd32ad5 commit d2580dd
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 9 deletions.
12 changes: 4 additions & 8 deletions .github/workflows/test_api_cuda.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -19,10 +19,11 @@ jobs:
image:
[
{ torch_cuda: cu118, torch_pre_release: 0, cuda_version: 11.8.0 },
{ torch_cuda: cu121, torch_pre_release: 1, cuda_version: 12.1.1 },
{ torch_cuda: cu121, torch_pre_release: 1, cuda_version: 12.1.0 },
]

runs-on: nvidia-gpu
runs-on: [multi-gpu, nvidia-gpu, 4-a10, ci]

steps:
- name: Checkout
uses: actions/checkout@v3
Expand All @@ -37,18 +38,13 @@ jobs:
--tag opt-bench-cuda:${{ matrix.image.cuda_version }}
.

- name: Get GPUs with most free memory
id: get_devices
run: |
echo "::set-output name=devices::$(nvidia-smi --query-gpu=memory.free,index --format=csv,noheader,nounits | sort -n -k1 | tail -n 2 | awk -F', ' '{print $2}' | xargs echo -n | sed 's/ /,/g' | awk '{print $0}')"
- name: Run tests
run: docker run
--rm
--gpus all
--pid host
--shm-size 64G
--env USE_CUDA="1"
--gpus '"device=${{ steps.get_devices.outputs.devices }}"'
--volume $(pwd):/workspace/optimum-benchmark
--workdir /workspace/optimum-benchmark
--entrypoint /bin/bash
Expand Down
4 changes: 3 additions & 1 deletion docker/cpu.dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
FROM ubuntu:latest
ARG UBUNTU_VERSION=20.04

FROM ubuntu:${UBUNTU_VERSION}

# Ignore interactive questions during `docker build`
ENV DEBIAN_FRONTEND noninteractive
Expand Down

0 comments on commit d2580dd

Please sign in to comment.