Documentation ¶
Index ¶
- type ComponentFeatures
- type PlaformFeatures
- type RatioPowerModel
- func (r *RatioPowerModel) AddDesiredOutValue(y float64)
- func (r *RatioPowerModel) AddNodeFeatureValues(x []float64)
- func (r *RatioPowerModel) AddProcessFeatureValues(x []float64)
- func (r *RatioPowerModel) GetComponentsPower(isIdlePower bool) ([]source.NodeComponentsEnergy, error)
- func (r *RatioPowerModel) GetGPUPower(isIdlePower bool) ([]uint64, error)
- func (r *RatioPowerModel) GetModelType() types.ModelType
- func (r *RatioPowerModel) GetNodeFeatureNamesList() []string
- func (r *RatioPowerModel) GetPlatformPower(isIdlePower bool) ([]uint64, error)
- func (r *RatioPowerModel) GetProcessFeatureNamesList() []string
- func (r *RatioPowerModel) IsEnabled() bool
- func (r *RatioPowerModel) ResetSampleIdx()
- func (r *RatioPowerModel) Train() error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ComponentFeatures ¶ added in v0.5.4
type ComponentFeatures int
The ratio features list follows this order
const ( PkgUsageMetric ComponentFeatures = iota CoreUsageMetric DramUsageMetric UncoreUsageMetric OtherUsageMetric GpuUsageMetric PkgDynPower CoreDynPower DramDynPower UncoreDynPower OtherDynPower GpuDynPower PkgIdlePower CoreIdlePower DramIdlePower UncoreIdlePower OtherIdlePower GpuIdlePower )
The ratio power model can be used for both node Component and Platform power estimation. The models for Component and Platform power estimation have different number of features.
type PlaformFeatures ¶ added in v0.5.4
type PlaformFeatures int
const ( // Node features are at the end of the feature list PlatformUsageMetric PlaformFeatures = iota PlatformDynPower PlatformIdlePower )
type RatioPowerModel ¶ added in v0.5.4
type RatioPowerModel struct { NodeFeatureNames []string ProcessFeatureNames []string // contains filtered or unexported fields }
RatioPowerModel stores the feature samples of each process for prediction The feature will added ordered from cycles, instructions and cache-misses
func (*RatioPowerModel) AddDesiredOutValue ¶ added in v0.5.4
func (r *RatioPowerModel) AddDesiredOutValue(y float64)
AddDesiredOutValue adds the the y, which is the response variable (or the dependent variable) of regression. RatioPowerModel is not trained, then we cannot Add training samples.
func (*RatioPowerModel) AddNodeFeatureValues ¶ added in v0.5.4
func (r *RatioPowerModel) AddNodeFeatureValues(x []float64)
AddNodeFeatureValues adds the the x for prediction, which is the variable used to calculate the ratio. RatioPowerModel is not trained, then we cannot Add training samples, only samples for prediction.
func (*RatioPowerModel) AddProcessFeatureValues ¶ added in v0.7.3
func (r *RatioPowerModel) AddProcessFeatureValues(x []float64)
AddProcessFeatureValues adds the the x for prediction, which is the variable used to calculate the ratio. RatioPowerModel is not trained, then we cannot Add training samples, only samples for prediction.
func (*RatioPowerModel) GetComponentsPower ¶ added in v0.5.4
func (r *RatioPowerModel) GetComponentsPower(isIdlePower bool) ([]source.NodeComponentsEnergy, error)
GetComponentsPower applies each component's ModelWeight prediction and return a map of component powers
func (*RatioPowerModel) GetGPUPower ¶ added in v0.5.4
func (r *RatioPowerModel) GetGPUPower(isIdlePower bool) ([]uint64, error)
GetComponentsPower returns GPU Power in Watts associated to each each process/process/pod
func (*RatioPowerModel) GetModelType ¶ added in v0.5.4
func (r *RatioPowerModel) GetModelType() types.ModelType
GetModelType returns the model type
func (*RatioPowerModel) GetNodeFeatureNamesList ¶ added in v0.5.4
func (r *RatioPowerModel) GetNodeFeatureNamesList() []string
GetNodeFeatureNamesList returns the list of process features that the model was configured to use
func (*RatioPowerModel) GetPlatformPower ¶ added in v0.5.4
func (r *RatioPowerModel) GetPlatformPower(isIdlePower bool) ([]uint64, error)
GetPlatformPower applies ModelWeight prediction and return a list of total powers
func (*RatioPowerModel) GetProcessFeatureNamesList ¶ added in v0.7.3
func (r *RatioPowerModel) GetProcessFeatureNamesList() []string
GetProcessFeatureNamesList returns the list of process features that the model was configured to use
func (*RatioPowerModel) IsEnabled ¶ added in v0.5.4
func (r *RatioPowerModel) IsEnabled() bool
IsEnabled returns true as Ratio Power model is always active
func (*RatioPowerModel) ResetSampleIdx ¶ added in v0.5.4
func (r *RatioPowerModel) ResetSampleIdx()
ResetSampleIdx set the sample vector index to 0 to overwrite the old samples with new ones for trainning or prediction.
func (*RatioPowerModel) Train ¶ added in v0.5.4
func (r *RatioPowerModel) Train() error
RatioPowerModel is not trained, then this function does nothing.