Documentation ¶
Index ¶
- Constants
- Variables
- func IsJobFinished(j *sednav1.IncrementalLearningJob) bool
- func New(cc *runtime.ControllerContext) (runtime.FeatureControllerI, error)
- func NewIncrementalJobCondition(conditionType sednav1.ILJobStageConditionType, jobStage sednav1.ILJobStage) sednav1.ILJobCondition
- type Controller
- type IncrementalCondData
- type Model
Constants ¶
View Source
const ( // Name is this controller name Name = "IncrementalLearning" // KindName is the kind name of CR this controller controls KindName = "IncrementalLearningJob" )
Variables ¶
View Source
var Kind = sednav1.SchemeGroupVersion.WithKind(KindName)
Kind contains the schema.GroupVersionKind for this controller type.
Functions ¶
func IsJobFinished ¶
func IsJobFinished(j *sednav1.IncrementalLearningJob) bool
func New ¶
func New(cc *runtime.ControllerContext) (runtime.FeatureControllerI, error)
New creates a new incremental learning job controller that keeps the relevant pods in sync with the corresponding IncrementalLearningJob objects.
func NewIncrementalJobCondition ¶
func NewIncrementalJobCondition(conditionType sednav1.ILJobStageConditionType, jobStage sednav1.ILJobStage) sednav1.ILJobCondition
Types ¶
type Controller ¶
type Controller struct {
// contains filtered or unexported fields
}
Controller ensures that all IncrementalLearningJob objects have corresponding pods to run their configured workload.
func (*Controller) Run ¶
func (c *Controller) Run(stopCh <-chan struct{})
Run starts the main goroutine responsible for watching and syncing jobs.
func (*Controller) SetDownstreamSendFunc ¶
func (c *Controller) SetDownstreamSendFunc(f runtime.DownstreamSendFunc) error
func (*Controller) SetUpstreamHandler ¶
func (c *Controller) SetUpstreamHandler(addFunc runtime.UpstreamHandlerAddFunc) error
type IncrementalCondData ¶
type IncrementalCondData struct { Input *struct { // Only one model cases Model *Model `json:"model,omitempty"` Models []Model `json:"models,omitempty"` DataURL string `json:"dataURL,omitempty"` // the data samples reference will be stored into this URL. // The content of this url would be: // # the first uncomment line means the directory // s3://dataset/ // mnist/0.jpg // mnist/1.jpg DataIndexURL string `json:"dataIndexURL,omitempty"` OutputDir string `json:"outputDir,omitempty"` } `json:"input,omitempty"` Output *struct { Model *Model `json:"model,omitempty"` Models []Model `json:"models,omitempty"` } `json:"output,omitempty"` }
IncrementalCondData the data of this condition including the input/output to do the next step
func (*IncrementalCondData) GetInputModelURLs ¶
func (cd *IncrementalCondData) GetInputModelURLs() []string
func (*IncrementalCondData) GetOutputModelURLs ¶
func (cd *IncrementalCondData) GetOutputModelURLs() []string
func (IncrementalCondData) Marshal ¶
func (cd IncrementalCondData) Marshal() ([]byte, error)
func (*IncrementalCondData) Unmarshal ¶
func (cd *IncrementalCondData) Unmarshal(data []byte) error
Click to show internal directories.
Click to hide internal directories.