# B-VAE, how to fit the prior with passed latent encoding?

I'm reading a RL article that is using a B-VAE to encode states. Here is the original article presenting reinforcement learning with imagined goals (RIG) Ashvin Nair et al., "Visual Reinforcement Learning with Imagined Goals" 2018.

In the presented algorithm, the authors put a step (page 6, Algorithm 1, line 3) that is : "Fit prior $$p(z)$$ to latent encodings $$\{\mu_{\phi}(s^{(i)})\}$$

I understand what $$p(z)$$ and $$\{\mu_{\phi}(s^{(i)})\}$$ are (or at least I think I do ...) but I have no idea about how to fit one to another. Any idea or helpful references?

• What is a B-VAE? The article you link to does not mention the term. – Sycorax Mar 28 at 17:27
• Presumably it’s the $\beta$-VAE in eq. (2). – Arya McCarthy Mar 28 at 17:41
• yeah exactly, i don't know how to type beta – Hedwin Bonnavaud Mar 28 at 19:11
• @Sycorax In VAE you have two losses. The first is the reconstruction loss. The second is the regularization term that responsible for generalization. The second term is the part that enables you to generelize and to be able to generate objects from the random latent space. $\beta$ helps you to control the tradeoff between the two losses. for example: In some cases you don't need to generate completely from random, so you can have less focus on the second regularization term i.e. set $\beta$ < 1 – ofer-a Mar 29 at 8:59