I am trying to execute the following program and it is showing the following error: (‘Variable type field must be a TensorType.’, <Sparse(float64, csr)>, Sparse(float64, csr)).

I dont know why it is wrong.in the bold line( acts_1= pm.math.sigmoid(pm.math.dot(ann_input, weights_in_1)) )..can anyone help to solve this issue..thanks in advance…

program :

import theano.tensor as tt

import pymc3 as pm

X = x_vector.astype(floatX)

Y = y.astype(floatX)

X_train, X_test, Y_train, Y_test = train_test_split(X, Y, test_size=.3)

ann_input = theano.shared(X_train.astype(‘float64’))

ann_output = theano.shared(Y_train.astype(‘float64’))

init_1 = np.random.randn(20, 6).astype(floatX)

with pm.Model() as nn_model:

```
mu_a = pm.Normal('mu_a', mu=0., sigma=100)
sigma_a = pm.HalfNormal('sigma_a', 100.)
weights_in_1 = pm.Normal('w_1', mu=mu_a, sd=sigma_a,
shape=(20, 6), testval=init_1)
***acts_1= pm.math.sigmoid(pm.math.dot(ann_input, weights_in_1))***
# Define likelihood
out = pm.Multinomial('likelihood', n=1, p=acts_1,
observed= ann_output)
step = pm.Metropolis()
trace = pm.sample(50000, step=step)
```