Skip to content

Commit 4cdb19b

Browse files
committed
Add GPU to ClusterConfiguration
1 parent a9b314e commit 4cdb19b

File tree

8 files changed

+9
-1
lines changed

8 files changed

+9
-1
lines changed

demo-notebooks/additional-demos/hf_interactive.ipynb

+1
Original file line numberDiff line numberDiff line change
@@ -92,6 +92,7 @@
9292
"# Create our cluster and submit\n",
9393
"# The SDK will try to find the name of your default local queue based on the annotation \"kueue.x-k8s.io/default-queue\": \"true\" unless you specify the local queue manually below\n",
9494
"cluster = Cluster(ClusterConfiguration(name='hfgputest', \n",
95+
" head_gpus=1, # For GPU enabled workloads set the head_gpus and num_gpus\n",
9596
" namespace=\"default\", # Update to your namespace\n",
9697
" num_workers=1,\n",
9798
" min_cpus=8, \n",

demo-notebooks/additional-demos/local_interactive.ipynb

+1
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,7 @@
5555
"\n",
5656
"cluster = Cluster(ClusterConfiguration(namespace=namespace,\n",
5757
" name=cluster_name,\n",
58+
" head_gpus=1, # For GPU enabled workloads set the head_gpus and num_gpus\n",
5859
" num_workers=1,\n",
5960
" min_cpus=1,\n",
6061
" max_cpus=1,\n",

demo-notebooks/guided-demos/0_basic_ray.ipynb

+2-1
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,8 @@
6161
"# Create and configure our cluster object\n",
6262
"# The SDK will try to find the name of your default local queue based on the annotation \"kueue.x-k8s.io/default-queue\": \"true\" unless you specify the local queue manually below\n",
6363
"cluster = Cluster(ClusterConfiguration(\n",
64-
" name='raytest',\n",
64+
" name='raytest', \n",
65+
" head_gpus=1, # For GPU enabled workloads set the head_gpus and num_gpus\n",
6566
" namespace='default', # Update to your namespace\n",
6667
" num_workers=2,\n",
6768
" min_cpus=1,\n",

demo-notebooks/guided-demos/2_basic_interactive.ipynb

+1
Original file line numberDiff line numberDiff line change
@@ -61,6 +61,7 @@
6161
"cluster_name = \"interactivetest\"\n",
6262
"cluster = Cluster(ClusterConfiguration(\n",
6363
" name=cluster_name,\n",
64+
" head_gpus=1, # For GPU enabled workloads set the head_gpus and num_gpus\n",
6465
" namespace=namespace,\n",
6566
" num_workers=2,\n",
6667
" min_cpus=2,\n",

demo-notebooks/guided-demos/notebook-ex-outputs/0_basic_ray.ipynb

+1
Original file line numberDiff line numberDiff line change
@@ -70,6 +70,7 @@
7070
"# The SDK will try to find the name of your default local queue based on the annotation \"kueue.x-k8s.io/default-queue\": \"true\" unless you specify the local queue manually below\n",
7171
"cluster = Cluster(ClusterConfiguration(\n",
7272
" name='raytest',\n",
73+
" head_gpus=1, # For GPU enabled workloads set the head_gpus and num_gpus\n",
7374
" namespace='default', # Update to your namespace\n",
7475
" num_workers=2,\n",
7576
" min_cpus=1,\n",

demo-notebooks/guided-demos/notebook-ex-outputs/2_basic_interactive.ipynb

+1
Original file line numberDiff line numberDiff line change
@@ -69,6 +69,7 @@
6969
"cluster_name = \"interactivetest\"\n",
7070
"cluster = Cluster(ClusterConfiguration(\n",
7171
" name=cluster_name,\n",
72+
" head_gpus=1, # For GPU enabled workloads set the head_gpus and num_gpus\n",
7273
" namespace=namespace,\n",
7374
" num_workers=2,\n",
7475
" min_cpus=2,\n",

demo-notebooks/guided-demos/preview_nbs/0_basic_ray.ipynb

+1
Original file line numberDiff line numberDiff line change
@@ -62,6 +62,7 @@
6262
"# The SDK will try to find the name of your default local queue based on the annotation \"kueue.x-k8s.io/default-queue\": \"true\" unless you specify the local queue manually below\n",
6363
"cluster = Cluster(ClusterConfiguration(\n",
6464
" name='raytest',\n",
65+
" head_gpus=1, # For GPU enabled workloads set the head_gpus and num_gpus\n",
6566
" namespace='default', # Update to your namespace\n",
6667
" num_workers=2,\n",
6768
" min_cpus=1,\n",

demo-notebooks/guided-demos/preview_nbs/2_basic_interactive.ipynb

+1
Original file line numberDiff line numberDiff line change
@@ -61,6 +61,7 @@
6161
"cluster_name = \"interactivetest\"\n",
6262
"cluster = Cluster(ClusterConfiguration(\n",
6363
" name=cluster_name,\n",
64+
" head_gpus=1, # For GPU enabled workloads set the head_gpus and num_gpus\n",
6465
" namespace=namespace,\n",
6566
" num_workers=2,\n",
6667
" min_cpus=2,\n",

0 commit comments

Comments
 (0)