From 608c55bcf1e53c511434a3e9c2f1e2fe0461aea4 Mon Sep 17 00:00:00 2001 From: Max Rossmannek Date: Fri, 1 Dec 2023 17:43:34 +0100 Subject: [PATCH] Linting and formatting --- qiskit_nature/second_q/properties/angular_momentum.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/qiskit_nature/second_q/properties/angular_momentum.py b/qiskit_nature/second_q/properties/angular_momentum.py index f86574a57..686361e08 100644 --- a/qiskit_nature/second_q/properties/angular_momentum.py +++ b/qiskit_nature/second_q/properties/angular_momentum.py @@ -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( @@ -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.