Skip to content

Commit

Permalink
Removing sympy
Browse files Browse the repository at this point in the history
  • Loading branch information
PabloAndresCQ committed Jun 4, 2024
1 parent 1988ee0 commit aea8198
Showing 1 changed file with 1 addition and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@
except ImportError:
warnings.warn("local settings failed to import cupy", ImportWarning)
import numpy as np
from sympy import Expr # type: ignore
from numpy.typing import NDArray
from pytket.circuit import Circuit
from pytket.extensions.cutensornet.general import CuTensorNetHandle, set_logger
Expand Down Expand Up @@ -249,10 +248,7 @@ def __init__(
)
self._logger.debug("Adding operator terms:")
for pauli_string, coeff in operator._dict.items():
if isinstance(coeff, Expr):
numeric_coeff = complex(coeff.evalf()) # type: ignore
else:
numeric_coeff = complex(coeff) # type: ignore
numeric_coeff = complex(coeff) # type: ignore
self._logger.debug(f" {numeric_coeff}, {pauli_string}")
num_pauli = len(pauli_string.map)
num_modes = (1,) * num_pauli
Expand Down

0 comments on commit aea8198

Please sign in to comment.