Documentation
¶
Overview ¶
Package catalog maps certification categories (domain/variant) to pre-configured WorkflowSpec builders. Each category is a YAML file under entries/{domain}/{variant}.yaml, embedded at compile time via //go:embed and loaded by loader.go. Adding a new certification category requires only adding a YAML file.
Index ¶
- Constants
- func BuildVersion() string
- func CompareTCPXOPluginVersion(version string) (order int, ok bool)
- func ConfigArch(arch string) string
- func DefaultGKETCPXONetworks() []string
- func EntriesFS() embed.FS
- func GPUArchFromNodeSelector(nodeSelector map[string]string) string
- func HarnessImageTag(buildVersion string) string
- func KnownGPUArch(gpuArch string) bool
- func KnownGPUArchs() []string
- func LoadGPUDefaults() error
- func ParseGPUArchFlag(value string) (string, error)
- func Register(domain, variant string, entry Entry)
- func SetBuildVersion(v string)
- func SpecReferencesNetwork(spec *nvcrev1alpha1.WorkflowSpec, name string) (bool, error)
- func TCPXOPluginRelease(version string) (string, bool)
- func TemplateFuncs() template.FuncMap
- func TemplateFuncsWithLib() template.FuncMap
- type BuildConfig
- type CategoryInfo
- type Entry
- type NodeDefaults
- type TCPXOPluginProfile
- type TemplateData
Constants ¶
const ( DefaultMaxSteps = 50 DefaultExitDurationMins = 30 // DefaultStartupStallTimeoutSeconds is the entry-level default for the // generated Job's startup-stall window. Templates use: // {{ .StartupStallTimeoutSeconds }} DefaultStartupStallTimeoutSeconds = 1200 DefaultSaveInterval = 250 DefaultSaveRetainInterval = 1000 DefaultSaveTopK = 1 DefaultStorageSize = "10Ti" DefaultTestScale = nvcrev1alpha1.TestScaleFullScale DefaultMaxBytes = "16G" DefaultNumIterations = 100 DefaultNumCycles = 10 DefaultMinGroupSize = 2 // Training container resource defaults (DGX-class sizing). Overridable // per value via CategoryOptions.resources (issue #83). DefaultTrainingCPULimit = "128" DefaultTrainingMemoryLimit = "800Gi" DefaultTrainingCPURequest = "64" DefaultTrainingMemoryRequest = "500Gi" // Diagnose mode uses fewer iterations for faster fault detection. DiagnoseNumIterations = 5 DiagnoseNumCycles = 1 DiagnoseTimeoutPerJob = "15m" // DefaultWorkloadRunTimeoutPerJob bounds a WorkloadRun Job when the user // sets no timeoutPerJob. Without it Execution.TimeoutPerJob stays nil, // isJobTimedOut always returns false, and a Job whose pods can never // schedule runs until someone notices: one such run sat InProgress for // 4h10m against a node with no allocatable GPUs. // // This is a backstop against never finishing, not a performance bound. It // is deliberately far longer than the catalog's 1h, because a WorkloadRun // is arbitrary user work and cutting a legitimate long training run short // would be worse than the hang. Set spec.orchestration.timeoutPerJob for // anything tighter. DefaultWorkloadRunTimeoutPerJob = "24h" // DefaultTimeoutPerJob is the default timeout for communication jobs. // Prevents pods from running indefinitely on launcher restarts. DefaultTimeoutPerJob = "1h" // GKETCPXONICsPerNode is the GPU NIC count TCPXO uses on an // a3-megagpu-8g node, one per GPU. It matches --num_nics and // NCCL_FASTRAK_IFNAME in the GCP H100 TCPXO templates. GKETCPXONICsPerNode = 8 // DefaultOCISecondaryNetwork is the NetworkAttachmentDefinition offline // render attaches on OCI, the name the catalog hardcoded before // detection existed (ADR-103). The controller never renders it. DefaultOCISecondaryNetwork = "network-operator/sriov-net" // OCISecondaryNetworkUnresolved is the sentinel the controller and // nvcrectl render build with first. It is not a valid <namespace>/<name>, // so a Workflow that still carries it after overlay application attaches // the OCI network and needs detection, and one that does not, does not // attach it (ADR-103). OCISecondaryNetworkUnresolved = "nvcre.unresolved/oci-secondary-network" // OCIMlnxResourceName is the extended resource the OCI RDMA fragment // requests, and the k8s.v1.cni.cncf.io/resourceName a NAD must carry to // be detected as its network. OCIMlnxResourceName = "nvidia.com/mlnxnics" // NADResourceNameAnnotation is the NetworkAttachmentDefinition annotation // Multus reads to pair an attachment with a device allocated for that // extended resource. OCI RDMA network detection keys on it. NADResourceNameAnnotation = "k8s.v1.cni.cncf.io/resourceName" )
Default values for template variables when not specified by the user.
const DevHarnessImageTag = "dev"
DevHarnessImageTag is what an unversioned build renders.
It names no published image on purpose. A local build has no release to point at, and inventing one would mean a developer's run silently pulled some other release's harness. The lanes that run this entry without a release already select their image explicitly: Mokka and UAT set spec.image, and so does anyone testing a harness change.
const ( // MinimumTCPXOPluginVersion is the oldest plugin release the catalog // maps, and the one rendered when no version is known: the release // AICR-provisioned clusters pin, validated on hardware. The NCCL // environment already requires plugin v1.0.9 or later, so nothing older // is worth a profile. MinimumTCPXOPluginVersion = "v1.0.15" )
Variables ¶
This section is empty.
Functions ¶
func BuildVersion ¶ added in v0.12.0
func BuildVersion() string
BuildVersion returns what SetBuildVersion recorded.
func CompareTCPXOPluginVersion ¶ added in v0.7.0
CompareTCPXOPluginVersion places version against the mapped releases: -1 when older than MinimumTCPXOPluginVersion, +1 when newer than latestTCPXOPluginVersion, 0 otherwise. ok is false when version is not a vMAJOR.MINOR.PATCH tag.
func ConfigArch ¶
ConfigArch returns the GPU architecture used for config file lookups. GB300 and GB200 use identical configs, so gb300 maps to gb200.
func DefaultGKETCPXONetworks ¶ added in v0.7.0
func DefaultGKETCPXONetworks() []string
DefaultGKETCPXONetworks returns the GKE Network names the GCP H100 TCPXO patch renders when none were detected: gpu-nic0 through gpu-nic7, the names the catalog hardcoded before detection existed (issue #432).
func EntriesFS ¶
EntriesFS returns the embedded catalog entries filesystem. Used by internal/platform to load shared _lib/ templates.
func GPUArchFromNodeSelector ¶
GPUArchFromNodeSelector extracts the GPU architecture string from a nodeSelector. It parses the nvidia.com/gpu.product label (e.g., "NVIDIA-H100-80GB-HBM3" → "h100"). Returns an empty string if the label is absent.
func HarnessImageTag ¶ added in v0.12.0
HarnessImageTag turns a build version into the tag of a harness image this repository publishes for itself.
This exists so that no catalog entry carries a literal version. release.yml builds both the binary and the harness image from the same tag, so the binary's own version IS the tag of the image that shipped with it, and deriving it removes the step where someone bumps a pin to the release they are about to cut. That step had no check behind it: forgetting it shipped a catalog naming an image that was never built, and the first symptom was ImagePullBackOff on a cluster that had already installed the release.
Three cases, because `git describe --tags --always --dirty` produces three shapes:
Only an exact release tag yields an image tag:
- "v1.2.3", or "v1.2.3-rc.1", a release build. Used as given, including the prerelease suffix, because that is how the image was tagged.
- "v1.2.3-15-gabc1234", or either form with "-dirty", a build somewhere after a tag. DevHarnessImageTag.
- "dev", "abc1234" or empty. DevHarnessImageTag.
A build past a tag renders "dev" rather than the tag it is past, and that is the whole point of the distinction. Resolving v0.11.0-7-gabc1234 to v0.11.0 would hand a build of THIS tree the harness image from a release that was built from a different one, which is exactly the silent cross-release pull DevHarnessImageTag exists to avoid; the moment a release shipped, every main build would start pulling its harness against main's entry and the mismatch would not show up as an error anywhere. publish.yml offers no alternative to point at either: it tags the harness "main-<sha>" and the build is gated on the harness sources having changed, so that tag exists only for some commits and nothing can resolve it in general.
func KnownGPUArch ¶ added in v0.7.0
KnownGPUArch reports whether gpu-defaults.yaml lists the architecture, i.e. whether GPUDefaults resolves it from the table rather than falling back to fallbackGpusPerNode. Callers use it to tell the user when a workflow was sized on the fallback (ADR-094).
func KnownGPUArchs ¶ added in v0.8.0
func KnownGPUArchs() []string
KnownGPUArchs returns every architecture gpu-defaults.yaml lists, sorted.
func LoadGPUDefaults ¶
func LoadGPUDefaults() error
LoadGPUDefaults forces the embedded gpu-defaults.yaml to be parsed and returns any error from that parse. Safe to call multiple times — the file is loaded exactly once and the result is cached.
Call this at process startup (e.g. from cmd/main.go) to fail fast if the embedded catalog data is malformed. Callers that don't invoke this will still trigger a lazy load on the first GPUDefaults call; in that path, parse errors are swallowed and architectures fall back to the safe default.
func ParseGPUArchFlag ¶ added in v0.6.0
ParseGPUArchFlag normalizes a --gpu-arch flag value with gpu.ParseProduct, so "gb300", "NVIDIA-GB300" and "NVIDIA GB300" are equivalent, and rejects an architecture gpu-defaults.yaml does not list: GPUDefaults would silently fall back for it and no gpuArchitecture override would match. An empty flag is allowed (architecture not specified); a non-empty one that normalizes to empty, e.g. "NVIDIA-", is rejected.
func SetBuildVersion ¶ added in v0.12.0
func SetBuildVersion(v string)
SetBuildVersion records the running binary's version for entries that derive an image tag from it. Called once from main, ahead of any render.
func SpecReferencesNetwork ¶ added in v0.10.0
func SpecReferencesNetwork(spec *nvcrev1alpha1.WorkflowSpec, name string) (bool, error)
SpecReferencesNetwork reports whether name appears anywhere in spec, overrides included. Callers pass OCISecondaryNetworkUnresolved after overlay application to learn whether the resolved Workflow attaches the OCI RDMA network (ADR-103), so the render, not its inputs, decides whether detection runs.
func TCPXOPluginRelease ¶ added in v0.7.0
TCPXOPluginRelease returns the vMAJOR.MINOR.PATCH release of a plugin tag, dropping any build suffix ("v1.0.17-1" gives "v1.0.17"), and false when version is not a release tag.
func TemplateFuncs ¶
TemplateFuncs returns the function map available to catalog entry templates and to the shared fragments under entries/_lib/.
Anything that renders those fragments must use this map. pkg/platform renders _lib fragments too (for WorkloadRun overrides) and previously defined its own reduced map containing only lib and indent. Because a template that calls an unregistered function fails to parse, and both render paths panic on parse failure, a fragment using repeat or trimSuffix rendered fine through the catalog and would have crashed the process through pkg/platform. One map removes that class of divergence.
Implement only the helpers used by the embedded templates, avoiding a full sprig dependency.
func TemplateFuncsWithLib ¶
TemplateFuncsWithLib returns TemplateFuncs with the "lib" function wired in, for renderers outside this package that pull in entries/_lib/ fragments but have no catalog entry directory of their own (see pkg/platform).
lib is registered into the same map it renders with, so a fragment may call lib recursively.
Types ¶
type BuildConfig ¶
type BuildConfig struct {
// ImagePullSecrets are references to secrets for pulling container images.
// If empty, the cluster's default image pull configuration is used.
ImagePullSecrets []corev1.LocalObjectReference
// StorageClassName is the StorageClass for PVC dependencies.
// If nil, catalogs that create PVCs omit the field (cluster default).
StorageClassName *string
// NodesPerJob is the number of nodes per job for multi-node workloads.
// Training and communication entries templatize this; single-node entries ignore it.
NodesPerJob int32
// GpusPerNode is the resolved number of GPUs per node (always non-zero).
// The certification controller derives this from the GPU architecture label
// or the user's explicit override.
GpusPerNode int32
// MlnxPerNode is the Mellanox NIC count per node, used by IB/RoCE templates
// (Azure, Forge, OCI, TogetherAI). 0 means the templates omit the NIC
// request (nvidia.com/mlnxnics, or NicResourceName where it applies) and, on
// OCI, the matching k8s.v1.cni.cncf.io/networks annotation: each
// such fragment wraps the request in {{ if gt (int .MlnxPerNode) 0 }}.
// Resolved from gpu-defaults.yaml + platform overrides + user override.
// When it is above 0, OCISecondaryNetwork must be set.
MlnxPerNode int32
// NicResourceName is the extended resource name of the RDMA NIC devices
// requested by the on-prem GB200/GB300 and HGX B200/B300 templates (e.g., "rdma/ib"). Empty
// means the templates omit the NIC resource block. The Azure, Forge and
// TogetherAI templates request a NIC resource when MlnxPerNode is above 0,
// using this name when it is set, else nvidia.com/mlnxnics. The
// per-container count comes from MlnxPerNode.
NicResourceName string
// Fabric is the resolved network fabric (efa, ib, roce, tcpxo, or "" where
// NVCRE renders no RDMA fabric of its own), which when.fabric overrides
// match against (ADR-110). The controller and the CLI resolve it; Build
// itself only passes it to the templates.
Fabric string
// EFAPerNode is the vpc.amazonaws.com/efa device count each worker
// requests on an EFA fabric whose count varies by layout (AWS GB300), read
// from node allocatable. 0 renders the default of 1.
EFAPerNode int32
// RDMADeviceAccess selects how workload containers reach the host's RDMA
// devices: "hostPath" mounts /dev/infiniband and runs the workload
// container privileged, "devicePlugin" and empty both leave the templates
// requesting NIC devices as an extended resource (see MlnxPerNode and
// NicResourceName). Fragments wrap the hostPath patch in
// {{- if eq .RDMADeviceAccess "hostPath" }}.
RDMADeviceAccess string
// NetworkAttachments is the resolved networkAttachments list (issue
// #400). Build only uses it to suppress the catalog's own NIC wiring
// that an explicit list replaces (the OCI RDMA attachments); the
// attachments themselves are written after overrides resolve, by
// platform.ApplyNetworkAttachmentsToDependencies.
NetworkAttachments []nvcrev1alpha1.NetworkAttachment
// GKETCPXONetworks are the GKE Network names the GCP H100 TCPXO patch
// attaches to the pod as eth1..eth8, in that order. The controller
// detects them from node allocatable; empty means the templates render
// DefaultGKETCPXONetworks.
GKETCPXONetworks []string
// OCISecondaryNetwork is the <namespace>/<name> of the
// NetworkAttachmentDefinition the OCI RDMA fragment attaches, once per
// NIC (ADR-103). It has no default: Build fails when MlnxPerNode is above
// 0 and it is empty, so every caller names it. The controller builds
// with OCISecondaryNetworkUnresolved first and detects the real name only
// when that sentinel survives overlay application; offline render uses
// DefaultOCISecondaryNetwork.
OCISecondaryNetwork string
// TCPXOPluginVersion is the GKE TCPXO NCCL plugin release installed on
// the GCP H100 target nodes, e.g. "v1.0.17" or its rebuild "v1.0.17-1".
// The controller detects it from the nccl-tcpxo-installer pods; it
// selects the GCP H100 workload images and the tcpxo-daemon image
// (TCPXOPluginProfileFor), by release, so a build suffix is ignored. An
// unmapped release renders the newest mapped profile not newer than it;
// empty, older or unparseable renders the MinimumTCPXOPluginVersion
// profile.
TCPXOPluginVersion string
// Resources overrides the CPU and memory of training containers.
// Nil (or nil sub-fields) means the training entries keep their
// DGX-class defaults (limits: cpu 128 / memory 800Gi; requests:
// cpu 64 / memory 500Gi). Non-training entries ignore it.
Resources *nvcrev1alpha1.CategoryResources
// EnableMNNVL controls the NCCL_MNNVL_ENABLE env var in training entries.
// When true, entries set NCCL_MNNVL_ENABLE=1.
EnableMNNVL bool
// EnableCheckpoint enables checkpointing for training workloads.
EnableCheckpoint bool
// MaxSteps is the maximum training steps for NeMo 4 workloads.
// 0 means use template default (50).
MaxSteps int32
// GemmFloorTFLOPS is the per-GPU sustained TFLOPS floor for
// compute/cutlass-gemm. Zero means the per-architecture default applies.
GemmFloorTFLOPS int32
// ExitDurationMins is the training duration in minutes for NeMo 6 workloads.
// 0 means use template default (30).
ExitDurationMins int32
// StartupStallTimeoutSeconds is the startup-stall window in seconds for the
// generated Job. 0 means the catalog entry's default (1200 for the training
// entries).
StartupStallTimeoutSeconds int32
// GPUArchitecture is the GPU architecture string (e.g., "h100", "gb200").
// Derived from the target nodeSelector's nvidia.com/gpu.product label.
// Required — Build returns an error if empty.
GPUArchitecture string
// SaveInterval is the checkpoint save frequency in training steps.
// 0 means use default (250).
SaveInterval int32
// SaveRetainInterval retains checkpoints at multiples of this value (NeMo 6).
// 0 means use default (1000).
SaveRetainInterval int32
// SaveTopK keeps only the top K checkpoints by metric (NeMo 4).
// 0 means use default (1).
SaveTopK int32
// StorageSize is the PVC size for checkpoint storage.
// Empty means use default ("10Ti").
StorageSize string
// TestScale controls orchestration strategy for NCCL tests.
// Empty means "full-scale" (default).
TestScale string
// MaxBytes is the max message size for NCCL tests (e.g., "16G", "32G").
// Empty means use default ("16G").
MaxBytes string
// NumIterations is the NCCL -n flag (timed iterations per message size).
// 0 means use default (100).
NumIterations int32
// NumCycles is the NCCL -N flag (run cycles, each printed separately).
// 0 means use default (10).
NumCycles int32
// MaxConcurrent limits simultaneous jobs. 0 means unlimited.
MaxConcurrent int32
// MinGroupSize is the smallest group at which diagnose's bisection
// stops splitting. 0 means use default (2).
MinGroupSize int32
// TimeoutPerJob is the max duration per job (e.g., "1h", "30m").
// Empty means use default ("1h", or "15m" for diagnose).
TimeoutPerJob string
// MeasurementTimeout is the max duration to wait after Job success for
// measurement data (e.g., "5m", "10m"). Empty means use controller default ("5m").
MeasurementTimeout string
// Thresholds maps metric names to CEL expressions for performance validation.
Thresholds map[string]string
// RepeatCount overrides the orchestration iteration count.
// 0 means use catalog default.
RepeatCount int32
// MaxRestarts overrides the checkpoint maxRestarts for training workloads.
// 0 means use catalog default. Only used when EnableCheckpoint is true.
MaxRestarts int32
// SourceRepo is the Git repository URL for the source checkout cloned by
// entries that fetch source at pod start. Empty means each entry uses its
// own default upstream; entries that clone no source ignore it.
SourceRepo string
// DCGMHost is the DCGM hostengine address (host[:port]) dcgm-level4
// passes to `dcgmi diag --host`. Empty means the entry's default
// address; other entries ignore it.
DCGMHost string
}
BuildConfig holds deployment-specific configuration passed from the Certification spec to catalog builders. Fields are optional — catalogs use them when applicable.
type CategoryInfo ¶
CategoryInfo describes a registered catalog category.
func List ¶
func List() []CategoryInfo
List returns all registered catalog categories, sorted by domain then variant.
type Entry ¶
type Entry struct {
// Build returns a WorkflowSpec configured for the given target nodes
// and deployment-specific configuration. Returns an error if the
// configuration is invalid (e.g., nodesPerJob not a power of 2,
// or fewer GPUs than required).
Build func(target nvcrev1alpha1.TargetSpec, config BuildConfig) (nvcrev1alpha1.WorkflowSpec, error)
// MinGPUs is the minimum number of GPUs (nodesPerJob × gpusPerNode)
// required by this entry. 0 means no minimum. Build returns an error
// if the requested GPU count is below this threshold.
MinGPUs int32
// TimeoutPerJob is the entry's default job timeout from its meta.yaml
// (e.g., "2h" for dcgm-level4). Empty means the global default applies
// (DefaultTimeoutPerJob, or DiagnoseTimeoutPerJob for diagnose scale).
// Exposed so callers (e.g., the nvcrectl --wait timeout derivation) can
// compute a category's job budget without a full Build.
TimeoutPerJob string
// Iterations is the entry's default orchestration iteration count,
// parsed from the entry template. Always >= 1.
Iterations int
// MaxValidNodes returns the largest node count <= availableNodes that
// satisfies the entry's constraints (minGPUs, TP×PP divisibility).
// Returns 0 if no valid count exists. When nil, any node count is valid.
MaxValidNodes func(availableNodes, gpusPerNode int32, gpuArch string) int32
}
Entry holds a builder that produces a WorkflowSpec for a given target.
func Lookup ¶
Lookup returns the catalog entry for the given domain and variant. Returns nil if the category is not registered.
func (*Entry) EffectiveTimeoutPerJob ¶
EffectiveTimeoutPerJob returns the timeoutPerJob string that Build would render for this entry: an explicit user override wins, then the entry's meta.yaml default, then the test-scale-dependent global default. Shares resolveTimeoutPerJob with buildTemplateData so the two cannot diverge.
type NodeDefaults ¶
type NodeDefaults struct {
GpusPerNode int32 `json:"gpusPerNode" yaml:"gpusPerNode"`
MlnxPerNode int32 `json:"mlnxPerNode" yaml:"mlnxPerNode"`
}
NodeDefaults holds per-node hardware counts for a GPU architecture. Populated from entries/_lib/gpu-defaults.yaml on first use and consumed by the controller and CLI to derive GpusPerNode/MlnxPerNode without hardcoding.
func GPUDefaults ¶
func GPUDefaults(gpuArch, platform string) NodeDefaults
GPUDefaults returns node hardware defaults for the given GPU architecture and platform. Platform overrides (e.g. OCI L40s) are applied on top of architecture defaults — only fields explicitly set in the platform override take effect; unset fields fall through to the architecture defaults. An explicit 0 is a value like any other, so a platform may override an architecture's non-zero mlnxPerNode down to none (e.g. OCI GB200).
Unknown architectures get {GpusPerNode: fallbackGpusPerNode, MlnxPerNode: 0}. An empty platform skips override resolution and returns architecture defaults only — this preserves callers that don't yet have platform context.
type TCPXOPluginProfile ¶ added in v0.7.0
type TCPXOPluginProfile struct {
// NCCLImage is the workload image of the GCP H100 NCCL test entries.
NCCLImage string
// TrainingImage is the workload image of the GCP H100 training entries.
TrainingImage string
// DaemonImage is the tcpxo-daemon sidecar image Google pairs with the
// plugin release.
DaemonImage string
// DaemonArgs are the flags passed to the daemon's
// entrypoint_rxdm_container.sh. They follow the daemon release: v1.0.21
// and later retire --num_nics, --uid and --alsologtostderr (a logged
// error, not fatal) and reject --enforce_kernel_ipv6_support outright,
// exiting before the receive path starts.
DaemonArgs string
}
TCPXOPluginProfile is the set of images the GCP H100 overrides render for one TCPXO NCCL plugin version.
func TCPXOPluginProfileFor ¶ added in v0.7.0
func TCPXOPluginProfileFor(version string) (profile TCPXOPluginProfile, release string, exact bool)
TCPXOPluginProfileFor returns the images to render for a detected plugin release tag, and the mapped release they belong to. The tag is placed by its vMAJOR.MINOR.PATCH release, so a build suffix does not change it: Google republishes some releases as a rebuild ("v1.0.13-1" a week after "v1.0.13"), built against the same CUDA major and paired with the same daemon. exact is true when that release is mapped; otherwise the nearest safe release is used:
- newer than every mapped release: the latest mapped one, since a newer plugin keeps at least the newest CUDA major and daemon generation;
- between mapped releases but not mapped itself: the newest mapped release older than it, for the same reason;
- older than MinimumTCPXOPluginVersion, empty, or not a vMAJOR.MINOR.PATCH tag: MinimumTCPXOPluginVersion, the CUDA 12 release validated on hardware.
type TemplateData ¶
type TemplateData struct {
// ImagePullSecrets are references to secrets for pulling container images.
// Templates use: {{- if .ImagePullSecrets }} ... {{- range .ImagePullSecrets }}
ImagePullSecrets []corev1.LocalObjectReference
// StorageClassName is the StorageClass for PVC dependencies.
// Empty string means omit (use cluster default).
// Templates use: {{- if .StorageClassName }}
StorageClassName string
// NodesPerJob is the number of nodes per job for multi-node workloads.
// Templates use: {{ .NodesPerJob }}
NodesPerJob int32
// GpusPerNode is the resolved number of GPUs per node (always non-zero at Build time).
// Templates use: {{ .GpusPerNode }}
GpusPerNode int32
// MlnxPerNode is the Mellanox NIC count per node for IB/RoCE platforms.
// 0 means omit nvidia.com/mlnxnics: templates use
// {{- if gt (int .MlnxPerNode) 0 }} around the request (and, on OCI, the
// network attachment annotation). Templates use: {{ .MlnxPerNode }}
MlnxPerNode int32
// NicResourceName is the extended resource name of the RDMA NIC devices
// for the on-prem GB200/GB300 and HGX B200/B300 templates. Empty means omit the NIC resource
// block. Templates use: {{- if .NicResourceName }} ... {{ .NicResourceName }}
// The Azure, Forge and TogetherAI templates use it in place of their
// nvidia.com/mlnxnics default:
// {{ or .NicResourceName "nvidia.com/mlnxnics" }}
NicResourceName string
// Fabric is the resolved network fabric (ADR-110). Templates use: {{ .Fabric }}
Fabric string
// EFAPerNode is the vpc.amazonaws.com/efa device count per worker on AWS
// GB300 EFA, read from node allocatable; at least 1.
// Templates use: {{ .EFAPerNode }}
EFAPerNode int32
// RDMADeviceAccess selects how workload containers reach the host's RDMA
// devices. "hostPath" mounts /dev/infiniband and runs the workload
// container privileged; "devicePlugin" and empty render nothing extra.
// Templates use: {{- if eq .RDMADeviceAccess "hostPath" }}
RDMADeviceAccess string
// HasNetworkAttachments is true when the options list networkAttachments
// explicitly. Fragments that render a default NIC wiring the list
// replaces wrap it in {{- if not .HasNetworkAttachments }}.
HasNetworkAttachments bool
// OCISecondaryNetwork is the <namespace>/<name> the OCI RDMA fragment
// attaches once per NIC (ADR-103), copied from BuildConfig as is.
// Templates use: {{ repeat (int .MlnxPerNode) (printf "%s," .OCISecondaryNetwork) }}
OCISecondaryNetwork string
// GKETCPXONetworks are the GKE Network names the GCP H100 TCPXO patch
// attaches to the pod as eth1..eth8, in that order (always
// GKETCPXONICsPerNode entries at Build time: detected, or
// DefaultGKETCPXONetworks). Templates use:
// {{ range $i, $n := .GKETCPXONetworks }} ... eth{{ add $i 1 }} ... {{ $n }}
GKETCPXONetworks []string
// GCPH100NCCLImage, GCPH100TrainingImage and TCPXODaemonImage are the
// images the GCP H100 TCPXO overrides render, selected by the detected
// TCPXO plugin version (always non-empty at Build time: from
// TCPXOPluginProfileFor, which falls back for unmapped versions). Templates use:
// {{ .GCPH100NCCLImage }}, {{ .GCPH100TrainingImage }}, {{ .TCPXODaemonImage }}.
// TCPXODaemonArgs are the daemon entrypoint flags for that daemon
// release: {{ .TCPXODaemonArgs }}
GCPH100NCCLImage string
GCPH100TrainingImage string
TCPXODaemonImage string
TCPXODaemonArgs string
// TrainingCPULimit is the CPU limit for training containers
// (always non-empty after defaults). Templates use: {{ .TrainingCPULimit }}
TrainingCPULimit string
// TrainingMemoryLimit is the memory limit for training containers
// (always non-empty after defaults). Templates use: {{ .TrainingMemoryLimit }}
TrainingMemoryLimit string
// TrainingCPURequest is the CPU request for training containers
// (always non-empty after defaults). Templates use: {{ .TrainingCPURequest }}
TrainingCPURequest string
// TrainingMemoryRequest is the memory request for training containers
// (always non-empty after defaults). Templates use: {{ .TrainingMemoryRequest }}
TrainingMemoryRequest string
// EnableMNNVL controls the NCCL_MNNVL_ENABLE env var.
// Templates use: {{ if .EnableMNNVL }}1{{ else }}0{{ end }}
EnableMNNVL bool
// EnableCheckpoint enables checkpointing for training workloads.
// Templates use: {{ .EnableCheckpoint }}
EnableCheckpoint bool
// MaxSteps is the maximum training steps (always non-zero after defaults).
// Templates use: {{ .MaxSteps }}
MaxSteps int32
// GemmFloorTFLOPS is an operator-set absolute per-GPU floor in whole
// TFLOPS, which overrides the target-times-ratio product when set. Zero
// means the product applies.
// Templates use: {{ .GemmFloorTFLOPS }}
GemmFloorTFLOPS int32
// HarnessImageTag is the tag of a harness image this repository publishes
// for itself, derived from the rendering binary's own version so that no
// entry carries a literal version to bump.
// Templates use: {{ .HarnessImageTag }}
HarnessImageTag string
// GemmTargetGFLOPS is the per-architecture reference target, DCGM's
// target_stress. Zero means the entry declares none for this
// architecture, which leaves the harness reporting without a verdict.
// Templates use: {{ .GemmTargetGFLOPS }}
GemmTargetGFLOPS int32
// GemmMinRatioPercent is the minimum fraction of the target a GPU must
// sustain, DCGM's target_perf_min_ratio expressed as whole percent.
//
// Percent rather than a float: a float64 here renders through Go's %v,
// which switches to scientific notation at some magnitudes, and this value
// lands in a shell environment variable. An integer cannot do that.
// Templates use: {{ .GemmMinRatioPercent }}
GemmMinRatioPercent int32
// ExitDurationMins is the training duration in minutes (always non-zero after defaults).
// Templates use: {{ .ExitDurationMins }}
ExitDurationMins int32
// StartupStallTimeoutSeconds is the startup-stall window in seconds for the
// generated Job (always non-zero after defaults).
// Templates use: {{ .StartupStallTimeoutSeconds }}
StartupStallTimeoutSeconds int32
// GPUArchitecture is the GPU architecture string (e.g., "h100", "gb200").
// Templates use: {{ .GPUArchitecture }}
GPUArchitecture string
// ConfigArch is the GPU architecture used for config file lookups.
// GB300 and GB200 use identical configs, so this maps gb300 → gb200.
// Templates use: {{ .ConfigArch }} in includeTemplate/includeFile paths.
ConfigArch string
// EntryName is the variant name of the catalog entry (e.g., "nccl-all-gather").
// Auto-populated by the loader from the entry's filesystem path.
// Shared library templates use this to construct entry-specific resource names
// like {{ .EntryName }}-runtime or {{ .EntryName }}-compute-domain.
EntryName string
// SaveInterval is the checkpoint save frequency in training steps.
// Templates use: {{ .SaveInterval }}
SaveInterval int32
// SaveRetainInterval retains checkpoints at multiples of this value (NeMo 6).
// Templates use: {{ .SaveRetainInterval }}
SaveRetainInterval int32
// SaveTopK keeps only the top K checkpoints by metric (NeMo 4).
// Templates use: {{ .SaveTopK }}
SaveTopK int32
// StorageSize is the PVC size for checkpoint storage.
// Templates use: {{ .StorageSize }}
StorageSize string
// TestScale controls orchestration strategy for NCCL tests.
// Templates use: {{ .TestScale }}
TestScale string
// MaxBytes is the max message size for NCCL tests.
// Templates use: {{ .MaxBytes }}
MaxBytes string
// NumIterations is the NCCL -n flag.
// Templates use: {{ .NumIterations }}
NumIterations int32
// NumCycles is the NCCL -N flag.
// Templates use: {{ .NumCycles }}
NumCycles int32
// MaxConcurrent limits simultaneous jobs.
// Templates use: {{ .MaxConcurrent }}
MaxConcurrent int32
// MinGroupSize is the smallest group at which bisection stops.
// Templates use: {{ .MinGroupSize }}
MinGroupSize int32
// TimeoutPerJob is the max duration per job for diagnose mode.
// Templates use: {{ .TimeoutPerJob }}
TimeoutPerJob string
// MeasurementTimeout is the max duration to wait for measurement data after Job success.
// Templates use: {{ .MeasurementTimeout }}
MeasurementTimeout string
// Thresholds maps metric names to CEL expressions.
// Templates use: {{- range $k, $v := .Thresholds }}
Thresholds map[string]string
// SourceRepo is the Git repository URL overriding the default upstream of
// the source checkout an entry clones at pod start. Stays empty when the
// user sets nothing; each entry supplies its own canonical fallback.
// Templates use: {{ if .SourceRepo }}{{ .SourceRepo }}{{ else }}<entry default>{{ end }}
SourceRepo string
// DCGMHost is the DCGM hostengine address overriding the default
// `dcgmi diag --host` value. Stays empty when the user sets nothing; the
// entry supplies its own default, and platform overrides that repoint the
// default skip their patch when it is set.
// Templates use: {{ if .DCGMHost }}{{ .DCGMHost }}{{ else }}<entry default>{{ end }}
DCGMHost string
// TP is tensor-model-parallel size from meta.yaml for the resolved architecture.
// Templates use: {{ .TP }}
TP int32
// PP is pipeline-model-parallel size from meta.yaml for the resolved architecture.
// Templates use: {{ .PP }}
PP int32
// EP is expert-model-parallel size from meta.yaml for the resolved architecture.
// Templates use: {{ .EP }}
EP int32
}
TemplateData holds the data passed to catalog YAML templates at Build time. Fields are populated from BuildConfig. Add new fields here for future template variables — no loader changes required.