From 446828f221709a6f7995e09087a31b675da73c16 Mon Sep 17 00:00:00 2001 From: changzherui Date: Tue, 5 May 2020 21:56:13 +0800 Subject: [PATCH] modify momentum test --- tests/ut/python/ops/test_momentum.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/ut/python/ops/test_momentum.py b/tests/ut/python/ops/test_momentum.py index 28b963701..f25e4faf2 100644 --- a/tests/ut/python/ops/test_momentum.py +++ b/tests/ut/python/ops/test_momentum.py @@ -38,7 +38,7 @@ def tensor_run_opt(opt, iters, learning_rate, momentum, gradient, variable, moment): """ tensor_run_opt """ success = True - new_weight = opt(variable, moment, learning_rate, gradient, momentum) + new_weight = opt(variable, moment, learning_rate, gradient, momentum)[0] success = F.depend(success, F.assign(variable, new_weight)) return success -- GitLab