thangbui / geepee

A collection of Gaussian process models
MIT License
29 stars 11 forks source link

predict_y with Gaussian likelihood #16

Closed hughsalimbeni closed 7 years ago

hughsalimbeni commented 7 years ago

When calling predict_y with a Gaussian likelihood I get the following

  File "./geepee/geepee/aep_models.py", line 2249, in predict_y
    my, vy = self.lik_layer.forward_prop_thru_post(mf, vf)

AttributeError: 'Gauss_Layer' object has no attribute 'forward_prop_thru_post'

predict_f works fine though

Adding the following is probably all that's needed, but please confirm:

class Gauss_Layer(Lik_Layer):
    ....
    def forward_prop_thru_post(self, mf, vf):
        return mf, vf + np.exp(2.0 * self.sn)
thangbui commented 7 years ago

Thanks Hugh. I've fixed it.