dbn = DBN(numpy_rng=numpy_rng, n_ins=2, hidden_layers_sizes=[50, 50, 50],
    n_outs=1)
train_set = [([1, 2], [2]), ([4, 5], [5])]
train_set_x = [train_set[i][0] for i in range(len(train_set))]
nparray = numpy.asarray(train_set_x, dtype=theano.config.floatX)
train_set_x = theano.shared(nparray, borrow=True)
pretraining_fns = dbn.pretraining_functions(train_set_x=train_set_x,
    batch_size=10, k=1)
Как форматировать обучающие/тестовые наборы для нейронной сети Deep Belief