facebookresearch / ParlAI

A framework for training and evaluating AI models on a variety of openly available dialogue datasets.
https://parl.ai
MIT License
10.49k stars 2.1k forks source link

display_examples doesn't work with dynamic_batching #3218

Open wyshi opened 4 years ago

wyshi commented 4 years ago

when having both --display_examples True and --dynamic-batching full,

line 547, in display_messages
    agent_id = msg.get("id", "[no id field]")
AttributeError: 'list' object has no attribute 'get'

I pdbed, it's because msg is a list of dictionaries instead of a dictionary in here https://github.com/facebookresearch/ParlAI/blob/master/parlai/utils/misc.py#L554

Describe the solution you'd like I think it should be an easy fix? just check if it's dynamic batching, and add another full loop? so that we could have both both --display_examples True and --dynamic-batching full

github-actions[bot] commented 3 years ago

This issue has not had activity in 30 days. Please feel free to reopen if you have more issues. You may apply the "never-stale" tag to prevent this from happening.

stephenroller commented 3 years ago

This is on the roadmap for H1 2021