MCPcopy Create free account
hub / github.com/apache/tvm-ffi / _roundtrip

Function _roundtrip

tests/python/test_serialization.py:33–35  ·  view source on GitHub ↗

Serialize then deserialize and return the result.

(obj: Any)

Source from the content-addressed store, hash-verified

31# Helpers
32# ---------------------------------------------------------------------------
33def _roundtrip(obj: Any) -> Any:
34 """Serialize then deserialize and return the result."""
35 return from_json_graph_str(to_json_graph_str(obj))
36
37
38def _assert_roundtrip_eq(obj: Any, cmp: Callable[..., Any] | None = None) -> None:

Callers 15

_assert_roundtrip_eqFunction · 0.85
test_noneMethod · 0.85
test_trueMethod · 0.85
test_falseMethod · 0.85
test_zeroMethod · 0.85
test_positiveMethod · 0.85
test_negativeMethod · 0.85
test_large_positiveMethod · 0.85
test_large_negativeMethod · 0.85
test_zeroMethod · 0.85
test_positiveMethod · 0.85
test_negativeMethod · 0.85

Calls 2

from_json_graph_strFunction · 0.90
to_json_graph_strFunction · 0.90

Tested by

no test coverage detected