MCPcopy Index your code
hub / github.com/numpy/numpy / test_2d

Method test_2d

numpy/lib/tests/test_twodim_base.py:78–88  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

76 [0, 0, 1, 0]]))
77
78 def test_2d(self):
79 assert_equal(eye(4, 3),
80 array([[1, 0, 0],
81 [0, 1, 0],
82 [0, 0, 1],
83 [0, 0, 0]]))
84
85 assert_equal(eye(3, 4),
86 array([[1, 0, 0, 0],
87 [0, 1, 0, 0],
88 [0, 0, 1, 0]]))
89
90 def test_diag2d(self):
91 assert_equal(eye(3, 4, k=2),

Callers

nothing calls this directly

Calls 3

assert_equalFunction · 0.90
eyeFunction · 0.90
arrayFunction · 0.90

Tested by

no test coverage detected