Explain / fix Python TypeError from pylearn2 [url removed, login to view]()

I'm having a difficult time figuring out what is wrong with this python script. There are many dependencies, so hopefully you can help me figure out what is going wrong without having to install them all yourself!

I get the TypeError: Cannot safely cast batch dtype float64 to space's dtype int64

import os

import numpy as np

from [url removed, login to view] import Train

from [url removed, login to view] import softmax_regression, mlp

from pylearn2.training_algorithms import bgd, sgd

from pylearn2.termination_criteria import MonitorBased

from pylearn2.termination_criteria import EpochCounter

from pylearn2.train_extensions import best_params

from [url removed, login to view] import serial

from [url removed, login to view] import Dropout

from pylearn2.datasets.dense_design_matrix import DenseDesignMatrix

from [url removed, login to view] import csv_dataset

from theano import function

from theano import tensor as T

import theano

# load datasets

train = [url removed, login to view]("[url removed, login to view]",expect_labels=True,expect_headers=False,delimiter=',',end_fraction=0.7)

valid = [url removed, login to view]("[url removed, login to view]",expect_labels=True,expect_headers=False,delimiter=',')

test = [url removed, login to view]("[url removed, login to view]",expect_labels=True,expect_headers=False,delimiter=',')

# Simple ANN

h0 = [url removed, login to view](layer_name="h0",dim=400, sparse_init=20)

y0 = [url removed, login to view](n_classes=62,layer_name="y0",sparse_init=20)

layers = [h0, y0]

nn = [url removed, login to view](layers,nvis=1024)

algo = [url removed, login to view](learning_rate=0.05,batch_size=100,monitoring_dataset=valid,termination_criterion=EpochCounter(100))

[url removed, login to view](nn,train)

save_best = [url removed, login to view](channel_name="y0_misclass",save_path='[url removed, login to view]')

while True:

[url removed, login to view](dataset=train)


[url removed, login to view]()


if not algo.continue_learning(nn):


Habilidades: Python, UNIX

Veja mais: python numpy, numpy all, what is sgd, train, SGD, mlp, c algo, ann, algo, typeerror, fix python, help python, python batch, python function, python setup script, python front end, fix editor joomla end, simple python script, fix python script, python front end css, fix python code send xhtml jabber xmpppy, open source fix protocol front end, python test script, python import script, python front end postgresql

Acerca do Empregador:
( 16 comentários ) United States

ID do Projeto: #6824014

Concedido a:


Hello!! Can I get the code and an image from you where it shows the line where you are getting the error? This seems a simple poblem, but maybe a little bit more of information would be helpful. Thank you very Mais

$55 USD em 3 dias
(4 Comentários)

3 freelancers are bidding on average $48 for this job


Hi, We fully gone through the [url removed, login to view] has type casting error, related to floating point CONVERSION. We can finish it in 1 Day. Thank You.

$40 USD em 1 dia
(1 Comentário)

I don't think there's anything very wrong with the script. I believe the real problem lies in the libraries used, namely pylearn2, and I think I can solve it.

$50 USD em 1 dia
(0 Comentários)