From 66cc1850a8e29858776fe31e4dc00e5dab49f2be Mon Sep 17 00:00:00 2001 From: tangwei12 Date: Fri, 24 Aug 2018 12:50:10 +0800 Subject: [PATCH] add gpu place --- python/paddle/fluid/tests/unittests/test_fill_constant_op.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/python/paddle/fluid/tests/unittests/test_fill_constant_op.py b/python/paddle/fluid/tests/unittests/test_fill_constant_op.py index 537cabd5d0..fd59c5bb7c 100644 --- a/python/paddle/fluid/tests/unittests/test_fill_constant_op.py +++ b/python/paddle/fluid/tests/unittests/test_fill_constant_op.py @@ -69,7 +69,9 @@ class TestFillConstantOpWithSelectedRows(OpTest): def test_fill_constant_with_selected_rows(self): places = [core.CPUPlace()] - # currently only support CPU + if core.is_compiled_with_cuda(): + places.append(core.CUDAPlace(0)) + for place in places: self.check_with_place(place) -- GitLab