MCPcopy Create free account
hub / github.com/XiaoBaiiiiii/colmap-pcd / main

Function main

scripts/python/test_read_write_dense.py:36–57  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

34
35
36def main():
37 import sys
38 if len(sys.argv) != 3:
39 print("Usage: python test_read_write_dense.py "
40 "path/to/dense/input.bin path/to/dense/output.bin")
41 return
42
43 print("Checking consistency of reading and writing dense arrays "
44 + "(depth maps / normal maps) ...")
45
46 path_to_dense_input = sys.argv[1]
47 path_to_dense_output = sys.argv[2]
48
49 dense_input = read_array(path_to_dense_input)
50 print("Input shape: " + str(dense_input.shape))
51
52 write_array(dense_input, path_to_dense_output)
53 dense_output = read_array(path_to_dense_output)
54
55 np.testing.assert_array_equal(dense_input, dense_output)
56
57 print("... dense arrays are equal.")
58
59
60if __name__ == "__main__":

Callers 1

Calls 2

read_arrayFunction · 0.90
write_arrayFunction · 0.90

Tested by

no test coverage detected