Skip to content

Commit 0c193bf

Browse files
committed
Merge remote-tracking branch 'upstream/main'
2 parents b82549e + 7c218d2 commit 0c193bf

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

tuning/data/data_handlers.py

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -47,11 +47,10 @@ def __init__(
4747
self.allows_batching = allows_batching
4848

4949
def __str__(self):
50-
return f"DataHandler(op={\
51-
self.op.__name__ if hasattr(self.op, '__name__') else str(self.op)\
52-
},\
53-
handler_type={self.handler_type.name},\
54-
allows_batching={self.allows_batching})"
50+
o = self.op.__name__ if hasattr(self.op, "__name__") else str(self.op)
51+
n = self.handler_type.name
52+
b = self.allows_batching
53+
return f"DataHandler(op={o}, handler_type={n}, allows_batching={b})"
5554

5655

5756
### Utils for custom masking / manipulating input / output strs, etc

tuning/utils/evaluator.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -117,6 +117,7 @@ def __init__(self, metrics: dict):
117117
"abs": abs,
118118
"len": len,
119119
"round": round,
120+
"sum": sum,
120121
"math_trunc": math.trunc,
121122
"math_floor": math.floor,
122123
"math_ceil": math.ceil,

0 commit comments

Comments
 (0)