summaryrefslogtreecommitdiffstats
path: root/ml/ml.cc
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2022-08-12 07:26:17 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2022-08-12 07:26:17 +0000
commit7877a98bd9c00db5e81dd2f8c734cba2bab20be7 (patch)
treed18b767250f7c7ced9b8abe2ece784ac1fe24d3e /ml/ml.cc
parentReleasing debian version 1.35.1-2. (diff)
downloadnetdata-7877a98bd9c00db5e81dd2f8c734cba2bab20be7.tar.xz
netdata-7877a98bd9c00db5e81dd2f8c734cba2bab20be7.zip
Merging upstream version 1.36.0.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'ml/ml.cc')
-rw-r--r--ml/ml.cc14
1 files changed, 7 insertions, 7 deletions
diff --git a/ml/ml.cc b/ml/ml.cc
index b56401b07..7275d88b8 100644
--- a/ml/ml.cc
+++ b/ml/ml.cc
@@ -80,12 +80,12 @@ void ml_new_dimension(RRDDIM *RD) {
return;
Dimension *D = new Dimension(RD);
- RD->state->ml_dimension = static_cast<ml_dimension_t>(D);
+ RD->ml_dimension = static_cast<ml_dimension_t>(D);
H->addDimension(D);
}
void ml_delete_dimension(RRDDIM *RD) {
- Dimension *D = static_cast<Dimension *>(RD->state->ml_dimension);
+ Dimension *D = static_cast<Dimension *>(RD->ml_dimension);
if (!D)
return;
@@ -95,7 +95,7 @@ void ml_delete_dimension(RRDDIM *RD) {
else
H->removeDimension(D);
- RD->state->ml_dimension = nullptr;
+ RD->ml_dimension = nullptr;
}
char *ml_get_host_info(RRDHOST *RH) {
@@ -125,7 +125,7 @@ char *ml_get_host_runtime_info(RRDHOST *RH) {
}
bool ml_is_anomalous(RRDDIM *RD, double Value, bool Exists) {
- Dimension *D = static_cast<Dimension *>(RD->state->ml_dimension);
+ Dimension *D = static_cast<Dimension *>(RD->ml_dimension);
if (!D)
return false;
@@ -186,10 +186,10 @@ void ml_process_rrdr(RRDR *R, int MaxAnomalyRates) {
if (MaxAnomalyRates < 1 || MaxAnomalyRates >= R->d)
return;
- calculated_number *CNs = R->v;
+ NETDATA_DOUBLE *CNs = R->v;
RRDR_DIMENSION_FLAGS *DimFlags = R->od;
- std::vector<std::pair<calculated_number, int>> V;
+ std::vector<std::pair<NETDATA_DOUBLE, int>> V;
V.reserve(R->d);
for (int Idx = 0; Idx != R->d; Idx++)
@@ -210,7 +210,7 @@ void ml_process_rrdr(RRDR *R, int MaxAnomalyRates) {
void ml_dimension_update_name(RRDSET *RS, RRDDIM *RD, const char *Name) {
(void) RS;
- Dimension *D = static_cast<Dimension *>(RD->state->ml_dimension);
+ Dimension *D = static_cast<Dimension *>(RD->ml_dimension);
if (!D)
return;