Skip to content

Commit bcaa1d5

Browse files
authored
Merge pull request #12853 from panyx0718/profiler
fix profiler test
2 parents 0b3d8fc + f8c6b46 commit bcaa1d5

File tree

1 file changed

+0
-5
lines changed

1 file changed

+0
-5
lines changed

python/paddle/fluid/tests/unittests/test_profiler.py

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -25,9 +25,6 @@
2525

2626
class TestProfiler(unittest.TestCase):
2727
def net_profiler(self, state, profile_path='/tmp/profile'):
28-
enable_if_gpu = state == 'GPU' or state == "All"
29-
if enable_if_gpu and not core.is_compiled_with_cuda():
30-
return
3128
startup_program = fluid.Program()
3229
main_program = fluid.Program()
3330

@@ -81,8 +78,6 @@ def net_profiler(self, state, profile_path='/tmp/profile'):
8178
pass_acc_calculator.add(value=acc, weight=b_size)
8279
pass_acc = pass_acc_calculator.eval()
8380

84-
@unittest.skipIf(not core.is_compiled_with_cuda(),
85-
"profiler is enabled only with GPU")
8681
def test_cpu_profiler(self):
8782
self.net_profiler('CPU')
8883

0 commit comments

Comments
 (0)