MCPcopy Create free account
hub / github.com/davisking/dlib / test_vector_init_with_number

Function test_vector_init_with_number

tools/python/test/test_vector.py:17–22  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

15
16
17def test_vector_init_with_number():
18 v = vector(3)
19 assert len(v) == 3
20 assert v.shape == (3, 1)
21 assert str(v) == "0\n0\n0"
22 assert repr(v) == "dlib.vector([0, 0, 0])"
23
24
25def test_vector_set_size():

Callers

nothing calls this directly

Calls 4

vectorClass · 0.90
lenFunction · 0.85
strClass · 0.85
reprFunction · 0.85

Tested by

no test coverage detected