trial

package
v2.1.7 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 29, 2022 License: Apache-2.0 Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AddInitializer

func AddInitializer(t *optimizev1beta2.Trial, initializer string) bool

AddInitializer adds an initializer to the trial; returns true only if the trial is changed

func ApplyCondition

func ApplyCondition(status *optimizev1beta2.TrialStatus, conditionType optimizev1beta2.TrialConditionType, conditionStatus corev1.ConditionStatus, reason, message string, time *metav1.Time)

ApplyCondition updates a the status of an existing condition or adds it if it does not exist

func CheckCondition

func CheckCondition(status *optimizev1beta2.TrialStatus, conditionType optimizev1beta2.TrialConditionType, conditionStatus corev1.ConditionStatus) bool

CheckCondition checks to see if a condition has a specific status

func GetInitializers

func GetInitializers(t *optimizev1beta2.Trial) []string

GetInitializers returns the initializers for the specified trial

func IsAbandoned

func IsAbandoned(t *optimizev1beta2.Trial) bool

IsAbandoned checks to see if the specified trial is abandoned

func IsActive

func IsActive(t *optimizev1beta2.Trial) bool

IsActive checks to see if the specified trial and any setup delete tasks are NOT finished

func IsBaseline

IsBaseline checks to see if the supplied trial is a baseline for an experiment.

func IsFinished

func IsFinished(t *optimizev1beta2.Trial) bool

IsFinished checks to see if the specified trial is finished

func IsTrialJobReference

func IsTrialJobReference(t *optimizev1beta2.Trial, ref *corev1.ObjectReference) bool

IsTrialJobReference checks to see if the supplied reference likely points to the job of a trial. This is used primarily to give special handling to patch operations so they can refer to trial job before it exists.

func NeedsCleanup

func NeedsCleanup(t *optimizev1beta2.Trial) bool

NeedsCleanup checks to see if a trial's TTL has expired

func NewJob

func NewJob(t *optimizev1beta2.Trial) *batchv1.Job

NewJob returns a new trial run job from the template on the trial

func RemoveInitializer

func RemoveInitializer(t *optimizev1beta2.Trial, initializer string) bool

RemoveInitializer removes the first occurrence of an initializer from the trial; returns true only if the trial is changed

func SetInitializers

func SetInitializers(t *optimizev1beta2.Trial, initializers []string)

SetInitializers sets the supplied initializers on the trial

func UpdateStatus

func UpdateStatus(t *optimizev1beta2.Trial) bool

UpdateStatus will make sure the trial status matches the current state of the trial; returns true only if changes were necessary

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL