MCPcopy Create free account
hub / github.com/numpy/numpy / test_vector_as_last_argument

Method test_vector_as_last_argument

numpy/linalg/tests/test_linalg.py:2000–2008  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

1998 assert_equal(multi_dot([A1d, B, C, D]).shape, (2,))
1999
2000 def test_vector_as_last_argument(self):
2001 # The last argument can be 1-D
2002 A = np.random.random((6, 2))
2003 B = np.random.random((2, 6))
2004 C = np.random.random((6, 2))
2005 D1d = np.random.random(2) # 1-D
2006
2007 # the result should be 1-D
2008 assert_equal(multi_dot([A, B, C, D1d]).shape, (6,))
2009
2010 def test_vector_as_first_and_last_argument(self):
2011 # The first and last arguments can be 1-D

Callers

nothing calls this directly

Calls 3

assert_equalFunction · 0.90
multi_dotFunction · 0.90
randomMethod · 0.80

Tested by

no test coverage detected