MCPcopy Index your code
hub / github.com/pytorch/pytorch / setUp

Method setUp

caffe2/python/workspace_test.py:378–382  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

376@unittest.skipIf(not workspace.has_gpu_support, "No gpu support.")
377class TestWorkspaceGPU(test_util.TestCase):
378 def setUp(self):
379 workspace.ResetWorkspace()
380 self.net = core.Net("test-net")
381 self.net.ConstantFill([], "testblob", shape=[1, 2, 3, 4], value=1.0)
382 self.net.RunAllOnGPU()
383
384 def testFetchBlobGPU(self):
385 self.assertEqual(

Callers

nothing calls this directly

Calls 2

NetMethod · 0.80
RunAllOnGPUMethod · 0.45

Tested by

no test coverage detected