# Minibatch variables not behaving as expected

**URL:** <https://discourse.pymc.io/t/minibatch-variables-not-behaving-as-expected/927>\
**Category:** Questions\
**Created:** [March 12, 2018, 2:33pm UTC](https://discourse.pymc.io/t/minibatch-variables-not-behaving-as-expected/927 "2018-03-12T14:33:32Z")\
**Posts on this page:** 1\
**Showing post:** 6

<div class="post-metadata">

**Author:** ![researcher](https://avatars.discourse-cdn.com/v4/letter/r/edb3f5/32.png) [@researcher](https://discourse.pymc.io/u/researcher)\
**Post date:** [March 13, 2018, 8:40pm UTC](https://discourse.pymc.io/t/minibatch-variables-not-behaving-as-expected/927/6 "2018-03-13T20:40:15Z")

</div>

Hi @junpenglao. This solved my initial problem. However, I’m still having trouble training the model using ADVI and minibatch and then drawing from ppc with the test values.

I’m trying to follow along with the suggestions here: [PPC with Minibatch ADVI](https://discourse.pymc.io/t/ppc-with-minibatch-advi/131), but I get a dimension input mismatch error:

```
ValueError: Input dimension mis-match. (input[0].shape[0] = 85054, input[3].shape[0] = 2000)

```

How can I resolve this error?

---

_[View the full topic](https://discourse.pymc.io/t/minibatch-variables-not-behaving-as-expected/927)._
