Skip to content

Commit

Permalink
Add custom ray image ROCm tests
Browse files Browse the repository at this point in the history
  • Loading branch information
ChughShilpa authored and openshift-merge-bot[bot] committed Dec 6, 2024
1 parent 9a422b5 commit dce4007
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 4 deletions.
12 changes: 10 additions & 2 deletions tests/odh/mnist_ray_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -44,14 +44,22 @@ func TestMnistRayROCmGpu(t *testing.T) {
mnistRay(t, 1, "amd.com/gpu", GetRayROCmImage(), "resources/requirements-rocm.txt")
}

func TestMnistCustomRayImageCpu(t *testing.T) {
func TestMnistCustomRayCudaCpu(t *testing.T) {
mnistRay(t, 0, "nvidia.com/gpu", GetRayTorchCudaImage(), "resources/requirements.txt")
}

func TestMnistCustomRayImageGpu(t *testing.T) {
func TestMnistCustomRayCudaGpu(t *testing.T) {
mnistRay(t, 1, "nvidia.com/gpu", GetRayTorchCudaImage(), "resources/requirements.txt")
}

func TestMnistCustomRayRocmCpu(t *testing.T) {
mnistRay(t, 0, "amd.com/gpu", GetRayTorchROCmImage(), "resources/requirements-rocm.txt")
}

func TestMnistCustomRayRocmGpu(t *testing.T) {
mnistRay(t, 1, "amd.com/gpu", GetRayTorchROCmImage(), "resources/requirements-rocm.txt")
}

func mnistRay(t *testing.T, numGpus int, gpuResourceName string, rayImage string, requirementsFileName string) {
test := With(t)

Expand Down
4 changes: 2 additions & 2 deletions tests/odh/resources/mnist_ray_mini.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -76,8 +76,8 @@
" ClusterConfiguration(\n",
" namespace=namespace,\n",
" name='mnisttest',\n",
" head_cpu_requests=1,\n",
" head_cpu_limits=1,\n",
" head_cpu_requests=2,\n",
" head_cpu_limits=2,\n",
" head_memory_requests=4,\n",
" head_memory_limits=4,\n",
" head_extended_resource_requests={'nvidia.com/gpu':0},\n",
Expand Down

0 comments on commit dce4007

Please sign in to comment.