Skip to content

Commit

Permalink
remove square
Browse files Browse the repository at this point in the history
  • Loading branch information
renatomello committed Sep 23, 2024
1 parent c92f49c commit 8712e3f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/qibo/quantum_info/metrics.py
Original file line number Diff line number Diff line change
Expand Up @@ -272,7 +272,7 @@ def fidelity(state, target, check_hermitian: bool = False, backend=None):
fid = fid + matrix
del matrix

fid = backend.np.real(backend.np.trace(fid)) ** 2
fid = backend.np.real(backend.np.trace(fid))

return fid

Expand Down

0 comments on commit 8712e3f

Please sign in to comment.