mirror of
https://github.com/fjosw/pyerrors.git
synced 2025-03-15 14:50:25 +01:00
fix: check for CObs in linalg._mat_mat_op generalized.
This commit is contained in:
parent
07a6bb8a9d
commit
acb47a6782
1 changed files with 1 additions and 1 deletions
|
@ -233,7 +233,7 @@ def _scalar_mat_op(op, obs, **kwargs):
|
|||
def _mat_mat_op(op, obs, **kwargs):
|
||||
"""Computes the matrix to matrix operation op to a given matrix of Obs."""
|
||||
# Use real representation to calculate matrix operations for complex matrices
|
||||
if isinstance(obs.ravel()[0], CObs):
|
||||
if any(isinstance(o, CObs) for o in obs.ravel()):
|
||||
A = np.empty_like(obs)
|
||||
B = np.empty_like(obs)
|
||||
for (n, m), entry in np.ndenumerate(obs):
|
||||
|
|
Loading…
Add table
Reference in a new issue