MCPcopy Create free account
hub / github.com/VectorDB-NTU/RaBitQ-Library / read_ibin

Function read_ibin

python/utils/io.py:34–38  ·  view source on GitHub ↗
(filename)

Source from the content-addressed store, hash-verified

32 write_ivecs(filename, m.view("int32"))
33
34
35def read_ibin(filename):
36 n, d = np.fromfile(filename, count=2, dtype="int32")
37 a = np.fromfile(filename, dtype="int32")
38 print(f"\t{filename} readed")
39 return a[2:].reshape(n, d)
40
41

Callers 1

read_fbinFunction · 0.85

Calls 1

printFunction · 0.50

Tested by

no test coverage detected