openfermion.utils.is_identity

Check whether QubitOperator of FermionOperator is identity.

operator QubitOperator, FermionOperator, BosonOperator, or QuadOperator.

TypeError Operator of invalid type.