I have a quick question.
I ran my model using three classes:
- TraceEnum_ELBO
- JitTrace_ELBO
- Trace_ELBO
when I ran the model using 1 and 2, the loss increased but when I used 3, it decreased(which should be the case) I am I
finding this behavior happen?
the left column is epoch number and right column is the loss after each epoch in the TraceEnum_ELBO and Trace_ELBO cases
![](https://forum.pyro.ai/uploads/db5941/original/1X/51b7588cc0309a5812f109475b0f906571088f9d.JPG)
![](https://forum.pyro.ai/uploads/db5941/original/1X/e69ff0603f23d33ba39749921d42a941136448a7.JPG)
Please post your code (ideally a minimum reproducible example), otherwise there’s not much we can say about what’s going wrong.
The model and guide are initialized via the constructor of the class.
@eb8680_2 Do you why this is happening ? When I use TraceEnum_ELBO() and JitTraceEnum_ELBO(), the loss is decreasing. But If I use Trace_ELBO() andJitTrace_ELBO(), the loss is actually increasing. However, the accuracies on the test set in both cases above is not affected (surprisingly!) Is no training actually happening? Actually my starting priors are sophisticated
It’s probably related to sample
sites enumerated in your model that are also present in the guide. If you enumerate a variable in your model, you don’t need a corresponding distribution in the guide - it’s already been integrated out.
1 Like