I am trying to create minibatches in PyMC3. Here is my code with toy data:
import pandas as pd
import pymc3 as pm
data=[10, 20, 30, 40, 50, 60, 70, 80, 90, 100]
df=pd.DataFrame(data, columns=['age'])
minibatch_size = 2
age_minibatch = pm.Minibatch(df.age, batch_size=minibatch_size)
I keep getting this error:
IndexError: only integers, slices (`:`), ellipsis (`...`), numpy.newaxis (`None`) and integer or boolean arrays are valid indices
Could anybody help me why this is happening?
EDIT: Could someone please try to run the code to check if it is my environment or the code that is problematic? Thank you.