Skip to content

Commit 274056f

Browse files
committed
fix scoring
1 parent 810a303 commit 274056f

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

src/maxtext/trainers/post_train/rl/math_verify_pool.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -223,7 +223,8 @@ def math_verify_pool(tmvp_config, items, scores, timeout=15, num_procs=None, log
223223
try:
224224
# .get(0) returns immediately since ready() was true
225225
_, score = job.get(0)
226-
scores[idx] = max(scores[idx], tmvp_config.reward_exact_answer)
226+
if score > 0.0:
227+
scores[idx] = max(scores[idx], tmvp_config.reward_exact_answer)
227228
cnt += 1
228229
except Exception as e:
229230
if log_fn is not None:

0 commit comments

Comments
 (0)