MCPcopy Create free account
hub / github.com/pybind/pybind11 / test_eigen_ref_to_python

Function test_eigen_ref_to_python

tests/test_eigen_matrix.py:244–250  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

242
243
244def test_eigen_ref_to_python():
245 chols = [m.cholesky1, m.cholesky2, m.cholesky3, m.cholesky4]
246 for i, chol in enumerate(chols, start=1):
247 mymat = chol(np.array([[1.0, 2, 4], [2, 13, 23], [4, 23, 77]]))
248 assert np.all(mymat == np.array([[1, 0, 0], [2, 3, 0], [4, 5, 6]])), (
249 f"cholesky{i}"
250 )
251
252
253def assign_both(a1, a2, r, c, v):

Callers

nothing calls this directly

Calls 1

arrayMethod · 0.80

Tested by

no test coverage detected