svenwey commited on
Commit
907d4a9
·
verified ·
1 Parent(s): aa85c6a

remove assertion which was for testing purposes

Browse files
Files changed (1) hide show
  1. logmetric.py +0 -2
logmetric.py CHANGED
@@ -151,8 +151,6 @@ class LogMetric(evaluate.Metric):
151
  # Case there are no timestamps in reference and none in prediction
152
  # we can compute bleu directly from original prediction (ref will be empty, but we offload this to the bleu metric)
153
  if (len(pred_logentries) == 0 and len(ref_logentries) == 0):
154
- # TODO: remove this later, for testing purposes only
155
- assert(pred == "")
156
  # any sensible log reference is empty if there is no timestamp, hence it suffices to check exact match
157
  logmsg_score = 100.0 if pred == ref else 0.0
158
  return 0.3 * 100.0 + 0.7 * logmsg_score
 
151
  # Case there are no timestamps in reference and none in prediction
152
  # we can compute bleu directly from original prediction (ref will be empty, but we offload this to the bleu metric)
153
  if (len(pred_logentries) == 0 and len(ref_logentries) == 0):
 
 
154
  # any sensible log reference is empty if there is no timestamp, hence it suffices to check exact match
155
  logmsg_score = 100.0 if pred == ref else 0.0
156
  return 0.3 * 100.0 + 0.7 * logmsg_score