def _depolarizing_error(self) -> dict[noise_utils.OpIdentifier, float]:
        """Returns the portion of Pauli error from depolarization."""
        depol_errors = {}
        for op_id, p_error in self.gate_pauli_errors.items():
            gate_type = op_id.gate_type
            if issubclass(gate_type, ops.MeasurementGate):
                # Non-measurement error can be ignored on measurement gates.
                continue
            expected_qubits = 1 if gate_type in self.single_qubit_gates() else 2
            if len(op_id.qubits) != expected_qubits:
                raise ValueError(
                    f'Gate {gate_type} takes {expected_qubits} qubit(s), '
                    f'but {op_id.qubits} were given.'
                )
            depol_errors[op_id] = self._get_pauli_error(p_error, op_id)
        return depol_errors
Returns the portion of Pauli error from depolarization.
cirq-core/cirq/devices/superconducting_qubits_noise_properties.py