NM512 / dreamerv3-torch

Implementation of Dreamer v3 in pytorch.
MIT License
422 stars 96 forks source link

Loss calculation #60

Closed gunnarbeutner closed 4 months ago

gunnarbeutner commented 4 months ago

https://github.com/NM512/dreamerv3-torch/blob/4e50f302cdfaca1c8104f203376844f82c635a4e/models.py#L147

Just wondering, but shouldn't kl_loss be included in the sum() call?

From the paper:

$$L(\phi) = E{q\phi} \left[\sum{t=1}^T (\beta\text{pred}L\text{pred}(\phi) + \beta\text{dyn}L\text{dyn}(\phi) + \beta\text{rep}L\text{rep}(\phi))\right]$$

gunnarbeutner commented 4 months ago

Nevermind. I just checked this again and apparently I was wrong.