Skip to content
Snippets Groups Projects
Commit 67d2c707 authored by Dipam Chakraborty's avatar Dipam Chakraborty
Browse files

fix batching bug

parent 0411a16b
No related branches found
No related tags found
No related merge requests found
......@@ -37,9 +37,8 @@ def get_responses(agent, test_data, BATCH_SIZE):
for turn_id in range(7):
batch_inputs = [test_data[i][f"turn_{turn_id}"] for i in batch_idx]
responses = agent.generate_responses(batch_inputs)
for resp in responses:
for bi in batch_idx:
all_responses[bi][f"turn_{turn_id}"] = resp
for bi, resp in zip(batch_idx, responses):
all_responses[bi][f"turn_{turn_id}"] = resp
return all_responses
def evaluate(responses, test_data):
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment