def _get_qop_hermitian(of_operator) -> QubitHamiltonian:
    ' Returns Hermitian part of Fermion operator as QubitHamiltonian '
    qop = self.transformation(of_operator)
    (real, imag) = qop.split(hermitian=True)
    if real:
        return real
    elif (not real):
        raise TequilaException('Qubit Hamiltonian does not have a Hermitian part. Operator ={}'.format(of_operator))
Returns Hermitian part of Fermion operator as QubitHamiltonian
def _get_qop_hermitian(of_operator) -> QubitHamiltonian:
    '  '
    qop = self.transformation(of_operator)
    (real, imag) = qop.split(hermitian=True)
    if real:
        return real
    elif (not real):
        raise TequilaException('Qubit Hamiltonian does not have a Hermitian part. Operator ={}'.format(of_operator))