From 9646f2d3af637a96478788cd9d2592af4fdbc715 Mon Sep 17 00:00:00 2001 From: Yu Yang Date: Thu, 16 Feb 2017 12:24:04 +0800 Subject: [PATCH] Rename model_config => topology --- demo/mnist/api_train_v2.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/demo/mnist/api_train_v2.py b/demo/mnist/api_train_v2.py index f925d70765..2c0394aa0b 100644 --- a/demo/mnist/api_train_v2.py +++ b/demo/mnist/api_train_v2.py @@ -25,8 +25,8 @@ def network_config(): def main(): paddle.init(use_gpu=False, trainer_count=1) - model_config = parse_network_config(network_config) - parameters = paddle.parameters.create(model_config) + topology = parse_network_config(network_config) + parameters = paddle.parameters.create(topology) for param_name in parameters.keys(): array = parameters[param_name] array[:] = numpy.random.uniform(low=-1.0, high=1.0, size=array.shape) @@ -47,7 +47,7 @@ def main(): trainer = paddle.trainer.SGD(update_equation=adam_optimizer) trainer.train(train_data_reader=train_reader, - topology=model_config, + topology=topology, parameters=parameters, event_handler=event_handler, batch_size=32, # batch size should be refactor in Data reader -- GitLab