MCPcopy Index your code
hub / github.com/apache/tvm / test_from_int8

Method test_from_int8

jvm/core/src/test/java/org/apache/tvm/TensorTest.java:41–47  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

39 }
40
41 @Test
42 public void test_from_int8() {
43 Tensor tensor = Tensor.empty(new long[] {2, 2}, new TVMType("int8"));
44 tensor.copyFrom(new byte[] {1, 2, 3, 4});
45 assertArrayEquals(new byte[] {1, 2, 3, 4}, tensor.asByteArray());
46 tensor.release();
47 }
48
49 @Test
50 public void test_from_int16() {

Callers

nothing calls this directly

Calls 4

emptyMethod · 0.95
copyFromMethod · 0.95
asByteArrayMethod · 0.95
releaseMethod · 0.45

Tested by

no test coverage detected