mirror of https://github.com/inclusionAI/AReaL
PullRequest: 55 Fix a recover bug caused by dataset filtering
Merge branch fw/fix-recover20250322 of git@code.alipay.com:inclusionAI/AReaL.git into main https://code.alipay.com/inclusionAI/AReaL/pull_requests/55 Signed-off-by: 乘鹭 <hechuyi.hcy@antgroup.com> * fix recover
This commit is contained in:
parent
f90fe19e00
commit
df90bb512a
|
@ -11,7 +11,11 @@ def process_results(answer, solution):
|
|||
|
||||
if extracted_answer is None or extracted_answer.strip() in ["None", "none", ""]:
|
||||
retval = 0
|
||||
elif extracted_solution is None or extracted_solution.strip() in ["None", "none", ""]:
|
||||
elif extracted_solution is None or extracted_solution.strip() in [
|
||||
"None",
|
||||
"none",
|
||||
"",
|
||||
]:
|
||||
retval = 0
|
||||
elif math_equal(extracted_answer, extracted_solution, timeout=True):
|
||||
retval = 1
|
||||
|
|
|
@ -18,7 +18,11 @@ def process_results(answer, solution):
|
|||
# raise
|
||||
if extracted_answer is None or extracted_answer.strip() in ["None", "none", ""]:
|
||||
retval = 0
|
||||
elif extracted_solution is None or extracted_solution.strip() in ["None", "none", ""]:
|
||||
elif extracted_solution is None or extracted_solution.strip() in [
|
||||
"None",
|
||||
"none",
|
||||
"",
|
||||
]:
|
||||
retval = 0
|
||||
elif math_equal(extracted_answer, extracted_solution, timeout=False):
|
||||
# elif call_with_timeout(math_equal, extracted_answer, extracted_solution):
|
||||
|
|
|
@ -105,6 +105,8 @@ def discover_ckpt(
|
|||
)
|
||||
model_ckpt_dirs = []
|
||||
for role in os.listdir(model_save_dir):
|
||||
if "dataset_indices" in role:
|
||||
continue
|
||||
if not os.path.isdir(model_save_dir / role):
|
||||
continue
|
||||
ckpt_dir = (
|
||||
|
|
Loading…
Reference in New Issue