Adding code for 3 standard losses: reconstruction, discriminative, ntxent (contrastive).
Description
Adding 3 standard losses as class objects.
Motivation and Context
Common losses in emergent communication games are contrastive and discriminative loss.
Most of the games in EGG used either of the two. Adding them in core so that it will be easier to implement a new game from scratch. No more need to implement a discriminative loss (a potential source of wasted time handling tensor dimensions between sender messages and processed receiver input) as it can be imported from core in one line.
Adding code for 3 standard losses: reconstruction, discriminative, ntxent (contrastive).
Description
Adding 3 standard losses as class objects.
Motivation and Context
Common losses in emergent communication games are contrastive and discriminative loss. Most of the games in EGG used either of the two. Adding them in core so that it will be easier to implement a new game from scratch. No more need to implement a discriminative loss (a potential source of wasted time handling tensor dimensions between sender messages and processed receiver input) as it can be imported from core in one line.
TODOs (potential)
rewrite some games with such standard losses