Skip to content

Commit

Permalink
Fix lint warning
Browse files Browse the repository at this point in the history
  • Loading branch information
vatai committed Jan 21, 2024
1 parent d86c670 commit c6b2085
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions radicalpy/simulation.py
Original file line number Diff line number Diff line change
Expand Up @@ -708,8 +708,8 @@ def product_probability(self, obs: State, rhos: np.ndarray) -> np.ndarray:
"""Calculate the probability of the observable from the densities."""
if obs == State.EQUILIBRIUM:
raise ValueError("Observable state should not be EQUILIBRIUM")
obs = self.observable_projection_operator(obs)
return np.real(np.trace(obs @ rhos, axis1=-2, axis2=-1))
Q = self.observable_projection_operator(obs)
return np.real(np.trace(Q @ rhos, axis1=-2, axis2=-1))

@staticmethod
def product_yield(product_probability, time, k):
Expand Down

0 comments on commit c6b2085

Please sign in to comment.