projects
/
python_utils.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Update docs.
[python_utils.git]
/
histogram.py
diff --git
a/histogram.py
b/histogram.py
index 9c07df9b588aef626ecf8217a70ac4fd9676eb9d..dd47319cba845687deefe0c7f72de0e24f8e1500 100644
(file)
--- a/
histogram.py
+++ b/
histogram.py
@@
-32,7
+32,7
@@
class SimpleHistogram(Generic[T]):
NEGATIVE_INFINITY = -math.inf
def __init__(self, buckets: List[Tuple[Bound, Bound]]):
NEGATIVE_INFINITY = -math.inf
def __init__(self, buckets: List[Tuple[Bound, Bound]]):
- from math_utils import
RunningMedia
n
+ from math_utils import
NumericPopulatio
n
self.buckets: Dict[Tuple[Bound, Bound], Count] = {}
for start_end in buckets:
self.buckets: Dict[Tuple[Bound, Bound], Count] = {}
for start_end in buckets:
@@
-40,7
+40,7
@@
class SimpleHistogram(Generic[T]):
raise Exception("Buckets overlap?!")
self.buckets[start_end] = 0
self.sigma: float = 0.0
raise Exception("Buckets overlap?!")
self.buckets[start_end] = 0
self.sigma: float = 0.0
- self.stats:
RunningMedian = RunningMedia
n()
+ self.stats:
NumericPopulation = NumericPopulatio
n()
self.maximum: Optional[T] = None
self.minimum: Optional[T] = None
self.count: Count = 0
self.maximum: Optional[T] = None
self.minimum: Optional[T] = None
self.count: Count = 0