public sealed class RaySpec : IMessage<RaySpec>, IEquatable<RaySpec>, IDeepCloneable<RaySpec>, IBufferMessage, IMessage
Reference documentation and code samples for the Vertex AI v1beta1 API class RaySpec.
Configuration information for the Ray cluster.
For experimental launch, Ray cluster creation and Persistent
cluster creation are 1:1 mapping: We will provision all the nodes within the
Persistent cluster as Ray nodes.
public string HeadNodeResourcePoolId { get; set; }
Optional. This will be used to indicate which resource pool will serve as
the Ray head node(the first node within that pool). Will use the machine
from the first workerpool as the head node by default if this field isn't
set.
Optional. Default image for user to choose a preferred ML framework
(for example, TensorFlow or Pytorch) by choosing from Vertex prebuilt
images.
Either this or the resource_pool_images is required. Use this field if
you need all the resource pools to have the same Ray image. Otherwise, use
the {@code resource_pool_images} field.
public MapField<string, string> ResourcePoolImages { get; }
Optional. Required if image_uri isn't set. A map of resource_pool_id to
prebuild Ray image if user need to use different images for different
head/worker pools. This map needs to cover all the resource pool ids.
Example:
{
"ray_head_node_pool": "head image"
"ray_worker_node_pool1": "worker image"
"ray_worker_node_pool2": "another worker image"
}
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-08-28 UTC."],[[["\u003cp\u003eRaySpec is a class within the Vertex AI v1beta1 API, used to configure Ray clusters and their nodes.\u003c/p\u003e\n"],["\u003cp\u003eIt is used for the experimental launch of Ray cluster creation and persistent cluster creation, with a 1:1 mapping of nodes.\u003c/p\u003e\n"],["\u003cp\u003eThe \u003ccode\u003eImageUri\u003c/code\u003e property allows users to specify a pre-built ML framework image for all resource pools, or alternatively \u003ccode\u003eResourcePoolImages\u003c/code\u003e can be used to assign different images to different worker/head pools.\u003c/p\u003e\n"],["\u003cp\u003eRaySpec can be configured with optional properties like \u003ccode\u003eNfsMounts\u003c/code\u003e for mounting NFS storages, \u003ccode\u003eRayLogsSpec\u003c/code\u003e for logging configurations, and \u003ccode\u003eRayMetricSpec\u003c/code\u003e for metric configurations.\u003c/p\u003e\n"],["\u003cp\u003eThe \u003ccode\u003eHeadNodeResourcePoolId\u003c/code\u003e property allows users to specify which resource pool will act as the head node of the Ray cluster, defaulting to the first worker pool if not specified.\u003c/p\u003e\n"]]],[],null,["# Vertex AI v1beta1 API - Class RaySpec (1.0.0-beta47)\n\nVersion latestkeyboard_arrow_down\n\n- [1.0.0-beta47 (latest)](/dotnet/docs/reference/Google.Cloud.AIPlatform.V1Beta1/latest/Google.Cloud.AIPlatform.V1Beta1.RaySpec)\n- [1.0.0-beta46](/dotnet/docs/reference/Google.Cloud.AIPlatform.V1Beta1/1.0.0-beta46/Google.Cloud.AIPlatform.V1Beta1.RaySpec) \n\n public sealed class RaySpec : IMessage\u003cRaySpec\u003e, IEquatable\u003cRaySpec\u003e, IDeepCloneable\u003cRaySpec\u003e, IBufferMessage, IMessage\n\nReference documentation and code samples for the Vertex AI v1beta1 API class RaySpec.\n\nConfiguration information for the Ray cluster.\nFor experimental launch, Ray cluster creation and Persistent\ncluster creation are 1:1 mapping: We will provision all the nodes within the\nPersistent cluster as Ray nodes. \n\nInheritance\n-----------\n\n[object](https://learn.microsoft.com/dotnet/api/system.object) \\\u003e RaySpec \n\nImplements\n----------\n\n[IMessage](https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IMessage-1.html)[RaySpec](/dotnet/docs/reference/Google.Cloud.AIPlatform.V1Beta1/latest/Google.Cloud.AIPlatform.V1Beta1.RaySpec), [IEquatable](https://learn.microsoft.com/dotnet/api/system.iequatable-1)[RaySpec](/dotnet/docs/reference/Google.Cloud.AIPlatform.V1Beta1/latest/Google.Cloud.AIPlatform.V1Beta1.RaySpec), [IDeepCloneable](https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IDeepCloneable-1.html)[RaySpec](/dotnet/docs/reference/Google.Cloud.AIPlatform.V1Beta1/latest/Google.Cloud.AIPlatform.V1Beta1.RaySpec), [IBufferMessage](https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IBufferMessage.html), [IMessage](https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IMessage.html) \n\nInherited Members\n-----------------\n\n[object.GetHashCode()](https://learn.microsoft.com/dotnet/api/system.object.gethashcode) \n[object.GetType()](https://learn.microsoft.com/dotnet/api/system.object.gettype) \n[object.ToString()](https://learn.microsoft.com/dotnet/api/system.object.tostring)\n\nNamespace\n---------\n\n[Google.Cloud.AIPlatform.V1Beta1](/dotnet/docs/reference/Google.Cloud.AIPlatform.V1Beta1/latest/Google.Cloud.AIPlatform.V1Beta1)\n\nAssembly\n--------\n\nGoogle.Cloud.AIPlatform.V1Beta1.dll\n\nConstructors\n------------\n\n### RaySpec()\n\n public RaySpec()\n\n### RaySpec(RaySpec)\n\n public RaySpec(RaySpec other)\n\nProperties\n----------\n\n### HeadNodeResourcePoolId\n\n public string HeadNodeResourcePoolId { get; set; }\n\nOptional. This will be used to indicate which resource pool will serve as\nthe Ray head node(the first node within that pool). Will use the machine\nfrom the first workerpool as the head node by default if this field isn't\nset.\n\n### ImageUri\n\n public string ImageUri { get; set; }\n\nOptional. Default image for user to choose a preferred ML framework\n(for example, TensorFlow or Pytorch) by choosing from [Vertex prebuilt\nimages](https://cloud.google.com/vertex-ai/docs/training/pre-built-containers).\nEither this or the resource_pool_images is required. Use this field if\nyou need all the resource pools to have the same Ray image. Otherwise, use\nthe {@code resource_pool_images} field.\n\n### NfsMounts\n\n public RepeatedField\u003cNfsMount\u003e NfsMounts { get; }\n\nOptional. Use if you want to mount to any NFS storages.\n\n### RayLogsSpec\n\n public RayLogsSpec RayLogsSpec { get; set; }\n\nOptional. OSS Ray logging configurations.\n\n### RayMetricSpec\n\n public RayMetricSpec RayMetricSpec { get; set; }\n\nOptional. Ray metrics configurations.\n\n### ResourcePoolImages\n\n public MapField\u003cstring, string\u003e ResourcePoolImages { get; }\n\nOptional. Required if image_uri isn't set. A map of resource_pool_id to\nprebuild Ray image if user need to use different images for different\nhead/worker pools. This map needs to cover all the resource pool ids.\nExample:\n{\n\"ray_head_node_pool\": \"head image\"\n\"ray_worker_node_pool1\": \"worker image\"\n\"ray_worker_node_pool2\": \"another worker image\"\n}"]]