* Make it work in bookworm, redid some of the changes from last commit

* Changed default number types to int16 for ADC_Result and float32 for
  Accumulations
This commit is contained in:
Markus Rosenstihl
2026-03-09 10:55:55 +01:00
parent 29f003c99e
commit 28e6c9d1a0
10 changed files with 79 additions and 87 deletions
+5 -5
View File
@@ -168,7 +168,7 @@ class MeasurementResult(Drawable.Drawable, collections.UserDict):
sorted array of all dictionary entries without Accumulated Value objects with n==0
"""
keys=numpy.array([k for k in list(self.data.keys()) if not (isinstance(self.data[k], AccumulatedValue) and self.data[k].n==0)],
dtype="float64")
dtype="Float64")
keys.sort()
return keys
@@ -177,18 +177,18 @@ class MeasurementResult(Drawable.Drawable, collections.UserDict):
def get_xydata(self):
k=self.get_xdata()
v=numpy.array([self.data[key].mean() for key in k], dtype="float64")
v=numpy.array([self.data[key].mean() for key in k], dtype="Float64")
return [k,v]
def get_errorplotdata(self):
k=self.get_xdata()
v=numpy.array([self.data[key].mean() for key in k], dtype="float64")
e=numpy.array([self.data[key].mean_error() for key in k], dtype="float64")
v=numpy.array([self.data[key].mean() for key in k], dtype="Float64")
e=numpy.array([self.data[key].mean_error() for key in k], dtype="Float64")
return [k,v,e]
def get_lineplotdata(self):
k=self.get_xdata()
v=numpy.array(self.y, dtype="float64")
v=numpy.array(self.y, dtype="Float64")
return [k, v]
def uses_statistics(self):