Documentation
¶
Overview ¶
Package v1alpha1 contains API Schema definitions for the training v1alpha1 API group +kubebuilder:object:generate=true +groupName=training.pai.ai
Index ¶
Constants ¶
const ( // Kind is the kind name. Kind = "TFJob" // Plural is the Plural for TFJob. Plural = "tfjobs" // Singular is the singular for TFJob. Singular = "tfjob" )
const ( // TFJobDefaultPortName is name of the port used to communicate between PS and // workers. TFJobDefaultPortName = "tfjob-port" // TFJobDefaultContainerName is the name of the TFJob container. TFJobDefaultContainerName = "tensorflow" // TFJobDefaultPort is default value of the port. TFJobDefaultPort = 2222 // TFJobDefaultRestartPolicy is default RestartPolicy for TFReplicaSpec. TFJobDefaultRestartPolicy = commonv1.RestartPolicyNever // TFJobKind is the kind name. TFJobKind = "TFJob" // TFJobPlural is the TensorflowPlural for TFJob. TFJObPlural = "tfjobs" // TFJobSingular is the singular for TFJob. TFJobSingular = "tfjob" // TFJobFrameworkName is the name of the ML Framework TFJobFrameworkName = "tensorflow" )
const ( // TFJobReplicaTypePS is the type for parameter servers of distributed TensorFlow. TFJobReplicaTypePS commonv1.ReplicaType = "PS" // TFJobReplicaTypeWorker is the type for workers of distributed TensorFlow. // This is also used for non-distributed TensorFlow. TFJobReplicaTypeWorker commonv1.ReplicaType = "Worker" // TFJobReplicaTypeChief is the type for chief worker of distributed TensorFlow. // If there is "chief" replica type, it's the "chief worker". // Else, worker:0 is the chief worker. TFJobReplicaTypeChief commonv1.ReplicaType = "Chief" // TFJobReplicaTypeMaster is the type for master worker of distributed TensorFlow. // This is similar to chief, and kept just for backwards compatibility. TFJobReplicaTypeMaster commonv1.ReplicaType = "Master" // TFJobReplicaTypeEval is the type for evaluation replica in TensorFlow. TFJobReplicaTypeEval commonv1.ReplicaType = "Evaluator" )
Variables ¶
var ( // GroupVersion is group version used to register these objects GroupVersion = schema.GroupVersion{Group: "training.pai.ai", Version: "v1alpha1"} // SchemeBuilder is used to add go types to the GroupVersionKind scheme SchemeBuilder = &scheme.Builder{GroupVersion: GroupVersion} // AddToScheme adds the types in this group-version to the given scheme. AddToScheme = SchemeBuilder.AddToScheme )
Functions ¶
This section is empty.
Types ¶
type SuccessPolicy ¶
type SuccessPolicy string
SuccessPolicy is the success policy.
const ( SuccessPolicyDefault SuccessPolicy = "" SuccessPolicyAllWorkers SuccessPolicy = "AllWorkers" )
type TFJob ¶
type TFJob struct {
metav1.TypeMeta `json:",inline"`
metav1.ObjectMeta `json:"metadata,omitempty"`
Spec TFJobSpec `json:"spec,omitempty"`
Status common.JobStatus `json:"status,omitempty"`
}
PyTorchJob is the Schema for the pytorchjobs API
func (*TFJob) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TFJob.
func (*TFJob) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*TFJob) DeepCopyObject ¶
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type TFJobList ¶
type TFJobList struct {
// Standard type metadata.
metav1.TypeMeta `json:",inline"`
// Standard list metadata.
// +optional
metav1.ListMeta `json:"metadata,omitempty"`
// List of TFJobs.
Items []TFJob `json:"items"`
}
TFJobList is a list of TFJobs.
func (*TFJobList) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TFJobList.
func (*TFJobList) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*TFJobList) DeepCopyObject ¶
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type TFJobSpec ¶
type TFJobSpec struct {
tensorflowv1.TFJobSpec `json:",inline"` // Embed tensorflowv1.TFJobSpec inline
// AIMasterSpec specifies AIMaster configurations.
//+kubebuilder:validation:Optional
AIMasterSpec common.AIMasterSpec `json:"aimasterSpec,omitempty"`
}
TFJobSpec is a desired state description of the TFJob.
func (*TFJobSpec) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TFJobSpec.
func (*TFJobSpec) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.