facebookresearch / ReAgent

A platform for Reasoning systems (Reinforcement Learning, Contextual Bandits, etc.)
https://reagent.ai
BSD 3-Clause "New" or "Revised" License
3.58k stars 521 forks source link

add torchrec metrics to ap_container LinUCB #713

Closed alexnikulkov closed 1 year ago

alexnikulkov commented 1 year ago

Summary: I'm using recmetrics from torchrec to log supervised learning metrics. Metrics logged:

New metrics can easily be added by updating the model_utils.py file

The metrics are logged every 100 steps by default (controlled by config.trainer.log_every_n_steps). If this parameter is set too small, training will be slowed down by frequent matrix inversions.

The default window size is equal to batch_size*world_size, so the window is just 1 step.

An unfortunate side effect of per-ts discounting is that each epoch (ts partition) has a separate curve in TB.

Differential Revision: D42971642

facebook-github-bot commented 1 year ago

This pull request was exported from Phabricator. Differential Revision: D42971642

facebook-github-bot commented 1 year ago

This pull request has been merged in facebookresearch/ReAgent@825bd70f353f4298568cb653f151084d14e38fdd.