SSE: Mode to drop NaN/Inf/Null in Reduction operations (#43583)
Co-authored-by: Yuriy Tseretyan <yuriy.tseretyan@grafana.com> Co-authored-by: gillesdemey <gilles.de.mey@gmail.com>
This commit is contained in:
co-authored by
Yuriy Tseretyan
gillesdemey
parent
0cb3037b55
commit
040ce40113
@@ -402,10 +402,7 @@ func TestPercentDiffAbsReducer(t *testing.T) {
|
||||
func valBasedSeries(vals ...*float64) mathexp.Series {
|
||||
newSeries := mathexp.NewSeries("", nil, len(vals))
|
||||
for idx, f := range vals {
|
||||
err := newSeries.SetPoint(idx, time.Unix(int64(idx), 0), f)
|
||||
if err != nil {
|
||||
panic(err)
|
||||
}
|
||||
newSeries.SetPoint(idx, time.Unix(int64(idx), 0), f)
|
||||
}
|
||||
return newSeries
|
||||
}
|
||||
@@ -413,10 +410,7 @@ func valBasedSeries(vals ...*float64) mathexp.Series {
|
||||
func valBasedSeriesWithLabels(l data.Labels, vals ...*float64) mathexp.Series {
|
||||
newSeries := mathexp.NewSeries("", l, len(vals))
|
||||
for idx, f := range vals {
|
||||
err := newSeries.SetPoint(idx, time.Unix(int64(idx), 0), f)
|
||||
if err != nil {
|
||||
panic(err)
|
||||
}
|
||||
newSeries.SetPoint(idx, time.Unix(int64(idx), 0), f)
|
||||
}
|
||||
return newSeries
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user