Problem with fitting Multivariate Mixture of Gaussians

I am using the code as discussed in this post. The bug is still present. Is this correct?

I can also only sample with Metropolis. When the Nuts sampler is used, I still get the same shape mismatch.

Traceback (most recent call last):
  File "/opt/miniconda3/lib/python3.6/site-packages/theano/compile/function_module.py", line 903, in __call__
    self.fn() if output_subset is None else\
ValueError: Input dimension mis-match. (input[0].shape[0] = 2, input[1].shape[0] = 1)