def _check_condition(self, name, condition):
<EOL>if condition is not None and condition[<NUM_LIT:0>].name not in self.cregs:<EOL><INDENT>raise DAGCircuitError("<STR_LIT>" % name)<EOL><DEDENT>
Verify that the condition is valid.

        Args:
            name (string): used for error reporting
            condition (tuple or None): a condition tuple (ClassicalRegister,int)

        Raises:
            DAGCircuitError: if conditioning on an invalid register