Documentation ¶
Index ¶
- Constants
- func ExtractCurrentCondition(jobConditions []commonOp.JobCondition) (commonOp.JobCondition, error)
- func GetLogs(pluginContext k8s.PluginContext, taskType string, ...) ([]*core.TaskLog, error)
- func GetMPIPhaseInfo(currentCondition commonOp.JobCondition, occurredAt time.Time, ...) (pluginsCore.PhaseInfo, error)
- func GetPhaseInfo(currentCondition commonOp.JobCondition, occurredAt time.Time, ...) (pluginsCore.PhaseInfo, error)
- func GetReplicaCount(specs map[commonOp.ReplicaType]*commonOp.ReplicaSpec, ...) *int32
- func OverrideContainerSpec(podSpec *v1.PodSpec, containerName string, image string, args []string) error
- func OverridePrimaryContainerName(podSpec *v1.PodSpec, primaryContainerName string, defaultContainerName string)
- func ParseCleanPodPolicy(flyteCleanPodPolicy kfplugins.CleanPodPolicy) commonOp.CleanPodPolicy
- func ParseRestartPolicy(flyteRestartPolicy kfplugins.RestartPolicy) commonOp.RestartPolicy
- func ParseRunPolicy(flyteRunPolicy kfplugins.RunPolicy) commonOp.RunPolicy
- func SetConfig(cfg *Config) error
- func ToReplicaSpec(ctx context.Context, taskCtx pluginsCore.TaskExecutionContext, ...) (*commonOp.ReplicaSpec, error)
- func ToReplicaSpecWithOverrides(ctx context.Context, taskCtx pluginsCore.TaskExecutionContext, ...) (*commonOp.ReplicaSpec, error)
- type Config
Constants ¶
View Source
const ( TensorflowTaskType = "tensorflow" MPITaskType = "mpi" PytorchTaskType = "pytorch" )
Variables ¶
This section is empty.
Functions ¶
func ExtractCurrentCondition ¶
func ExtractCurrentCondition(jobConditions []commonOp.JobCondition) (commonOp.JobCondition, error)
ExtractCurrentCondition will return the first job condition for tensorflow/pytorch
func GetLogs ¶
func GetLogs(pluginContext k8s.PluginContext, taskType string, objectMeta meta_v1.ObjectMeta, hasMaster bool, workersCount int32, psReplicasCount int32, chiefReplicasCount int32, evaluatorReplicasCount int32) ([]*core.TaskLog, error)
GetLogs will return the logs for kubeflow job
func GetMPIPhaseInfo ¶
func GetMPIPhaseInfo(currentCondition commonOp.JobCondition, occurredAt time.Time, taskPhaseInfo pluginsCore.TaskInfo) (pluginsCore.PhaseInfo, error)
GetMPIPhaseInfo will return the phase of MPI job
func GetPhaseInfo ¶
func GetPhaseInfo(currentCondition commonOp.JobCondition, occurredAt time.Time, taskPhaseInfo pluginsCore.TaskInfo) (pluginsCore.PhaseInfo, error)
GetPhaseInfo will return the phase of kubeflow job
func GetReplicaCount ¶ added in v1.10.6
func GetReplicaCount(specs map[commonOp.ReplicaType]*commonOp.ReplicaSpec, replicaType commonOp.ReplicaType) *int32
func OverrideContainerSpec ¶
func OverrideContainerSpec(podSpec *v1.PodSpec, containerName string, image string, args []string) error
OverrideContainerSpec overrides the specified container's properties in the given podSpec. The function updates the image and command arguments of the container that matches the given containerName.
func ParseCleanPodPolicy ¶
func ParseCleanPodPolicy(flyteCleanPodPolicy kfplugins.CleanPodPolicy) commonOp.CleanPodPolicy
Get k8s clean pod policy from flyte kubeflow plugins clean pod policy.
func ParseRestartPolicy ¶
func ParseRestartPolicy(flyteRestartPolicy kfplugins.RestartPolicy) commonOp.RestartPolicy
Get k8s restart policy from flyte kubeflow plugins restart policy.
func ParseRunPolicy ¶
ParseRunPolicy converts a kubeflow plugin RunPolicy object to a k8s RunPolicy object.
func ToReplicaSpec ¶ added in v1.10.6
func ToReplicaSpec(ctx context.Context, taskCtx pluginsCore.TaskExecutionContext, primaryContainerName string) (*commonOp.ReplicaSpec, error)
func ToReplicaSpecWithOverrides ¶ added in v1.10.6
func ToReplicaSpecWithOverrides(ctx context.Context, taskCtx pluginsCore.TaskExecutionContext, rs kfDistributedReplicaSpec, primaryContainerName string, isMaster bool) (*commonOp.ReplicaSpec, error)
Types ¶
Click to show internal directories.
Click to hide internal directories.