MCPcopy Create free account
hub / github.com/NVIDIA/TensorRT / test_raw

Method test_raw

tools/Polygraphy/tests/cuda/test_cuda.py:175–181  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

173 assert copy_to_time <= (memcpy_time * 1.05)
174
175 def test_raw(self):
176 with DeviceArray.raw((25,)) as buf:
177 assert buf.shape == (25,)
178 assert buf.nbytes == 25
179 buf.resize((30,))
180 assert buf.shape == (30,)
181 assert buf.nbytes == 30

Callers

nothing calls this directly

Calls 2

rawMethod · 0.45
resizeMethod · 0.45

Tested by

no test coverage detected