MCPcopy Index your code
hub / github.com/DevTechJr/turboquant_cutile / test_sorted

Function test_sorted

tests/test_codebook.py:41–46  ·  view source on GitHub ↗
(bits)

Source from the content-addressed store, hash-verified

39
40@pytest.mark.parametrize("bits", [1, 2, 3, 4])
41def test_sorted(bits):
42 cb = LloydMaxCodebook(128, bits)
43 for i in range(len(cb.centroids) - 1):
44 assert cb.centroids[i] < cb.centroids[i + 1]
45 for i in range(len(cb.boundaries) - 1):
46 assert cb.boundaries[i] < cb.boundaries[i + 1]
47
48
49@pytest.mark.parametrize("bits", [1, 2, 3, 4])

Callers

nothing calls this directly

Calls 1

LloydMaxCodebookClass · 0.90

Tested by

no test coverage detected