Hello
I am trying to make a nested hierarchical linear regression model with two categories, an intercept for each category and 92 features. I have made this model in a few PPLs and the pyro and numpyro results look very different from the other models (pyMC3, Edward, Tensorflow Prob).
My numpyro and pyro models have coeffs all clustered around 0 and the other models have much more variability. I am thinking my numpyro and pyro models are wrong because for random data I still have this clustering.
levels is a vector of 0s and 1s indicating the category. hyperparamters are all single numbers not vectors
I also get a warning saying
Missing a plate statement for batch dimension -2 at site ‘obs’. You can use numpyro.util.format_shapes
utility to check shapes at all sites of your model.
any ideas on what could be wrong are appreciated.
with numpyro.plate("levels",M):
a = numpyro.sample("intercept",dist.Normal(mu_a,sig_a))
with numpyro.plate("features",D):
bm = numpyro.sample("coeff",dist.Normal(mu_b,sig_b))
with numpyro.plate("data", x.shape[0]):
return numpyro.sample("obs", dist.Normal( a[levels] + jnp.matmul(x,bm[:,levels]), sigma), obs=y_obs)