From 3b69629d3299543bd4f1f0e08794cd4a335609b9 Mon Sep 17 00:00:00 2001 From: qiaolongfei Date: Mon, 20 Feb 2017 16:18:29 +0800 Subject: [PATCH] modify api_train_v2 --- demo/mnist/api_train_v2.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/demo/mnist/api_train_v2.py b/demo/mnist/api_train_v2.py index b5cc74ce67..979cc3f1b9 100644 --- a/demo/mnist/api_train_v2.py +++ b/demo/mnist/api_train_v2.py @@ -16,8 +16,8 @@ def main(): paddle.init(use_gpu=False, trainer_count=1) # define network topology - images = paddle.layer.data(name='pixel', size=784) - label = paddle.layer.data(name='label', size=10) + images = paddle.layer.data(name='pixel', type=dense_vector(784)) + label = paddle.layer.data(name='label', type=integer_value(10)) hidden1 = paddle.layer.fc(input=images, size=200) hidden2 = paddle.layer.fc(input=hidden1, size=200) inference = paddle.layer.fc(input=hidden2, -- GitLab