MCPcopy Create free account
hub / github.com/DevTechJr/turboquant_cutile / test_edge_case_large_values

Function test_edge_case_large_values

tests/test_compress.py:129–133  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

127
128
129def test_edge_case_large_values():
130 engine = TurboQuantEngine(head_dim=128, total_bits=3, device="cpu")
131 K = torch.randn(4, 128).half() * 100
132 compressed = engine.compress_keys_pytorch(K)
133 assert not torch.isnan(compressed["k_mse"]).any()

Callers

nothing calls this directly

Calls 2

compress_keys_pytorchMethod · 0.95
TurboQuantEngineClass · 0.90

Tested by

no test coverage detected