Skip to content

Commit

Permalink
Linting and formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
mrossinek committed Dec 1, 2023
1 parent c217b5a commit 608c55b
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions qiskit_nature/second_q/properties/angular_momentum.py
Original file line number Diff line number Diff line change
Expand Up @@ -80,8 +80,8 @@ def overlap(self, overlap: np.ndarray | None) -> None:
if overlap is not None:
norb = self.num_spatial_orbitals
delta = np.eye(2 * norb)
delta[:norb,:norb] -= overlap.T @ overlap
delta[norb:,norb:] -= overlap @ overlap.T
delta[:norb, :norb] -= overlap.T @ overlap
delta[norb:, norb:] -= overlap @ overlap.T
summed = np.einsum("ij->", np.abs(delta))
if not np.isclose(summed, 0.0, atol=1e-6):
LOGGER.warning(
Expand All @@ -95,10 +95,10 @@ def overlap(self, overlap: np.ndarray | None) -> None:
"spin contamination in both subspaces. You should verify whether this is "
"intentional/acceptable or whether your choice of active space can be improved."
" As a reference, here is the summed-absolute deviation of `S^T @ S` from the "
f"identity: {summed}"
"identity: %s",
str(summed),
)


def second_q_ops(self) -> Mapping[str, FermionicOp]:
"""Returns the second quantized angular momentum operator.
Expand Down

0 comments on commit 608c55b

Please sign in to comment.