You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Nov 3, 2023. It is now read-only.
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.
We have quite a few instances where we have some per-token losses/metrics along with a corresponding mask
And we want a per-batch-example average:
I'd like us to have a helper classmethod in
Metric
calledfrom_mask
:Once this is done, add unit tests for this (test AverageMetric and PPLMetric directly). Checkpoint there.
After you've implemented this, upgrade TorchGeneratorAgent to use your new helper, upgrading the code for loss, ppl, and token_acc.
Example:
ParlAI/parlai/core/torch_generator_agent.py
Lines 711 to 727 in 67433e3
See if you can find at least one other place who can benefit from upgrading this pattern.
The text was updated successfully, but these errors were encountered: