def __init__(
        self,
        gate: type[raw_types.Gate] | raw_types.Gate,
        *,
        name: str | None = None,
        description: str | None = None,
        ignore_global_phase: bool = True,
        tags_to_accept: Sequence[Hashable] = (),
        tags_to_ignore: Sequence[Hashable] = (),
    ) -> None:
        """Init GateFamily.

        Args:
            gate: A python `type` inheriting from `cirq.Gate` for type based membership checks, or
                a non-parameterized instance of a `cirq.Gate` for equality based membership checks.
            name: The name of the gate family.
            description: Human readable description of the gate family.
            ignore_global_phase: If True, value equality is checked via
                `cirq.equal_up_to_global_phase`.
            tags_to_accept: If non-empty, only `cirq.Operations` containing at least one tag in this
                sequence can be accepted.
            tags_to_ignore: Any `cirq.Operation` containing at least one tag in this sequence is
                rejected. Note that this takes precedence over `tags_to_accept`, so an operation
                which contains tags from both `tags_to_accept` and `tags_to_ignore` is rejected.

        Raises:
            ValueError: if `gate` is not a `cirq.Gate` instance or subclass.
            ValueError: if `gate` is a parameterized instance of `cirq.Gate`.
            ValueError: if `tags_to_accept` and `tags_to_ignore` contain common tags.
        """
        if not (
            isinstance(gate, raw_types.Gate)
            or (isinstance(gate, type) and issubclass(gate, raw_types.Gate))
        ):
            raise ValueError(f'Gate {gate} must be an instance or subclass of `cirq.Gate`.')
        if isinstance(gate, raw_types.Gate) and protocols.is_parameterized(gate):
            raise ValueError(f'Gate {gate} must be a non-parameterized instance of `cirq.Gate`.')

        self._gate = gate
        self._tags_to_accept = frozenset(tags_to_accept)
        self._tags_to_ignore = frozenset(tags_to_ignore)
        self._name = name if name else self._default_name()
        self._description = description if description else self._default_description()
        self._ignore_global_phase = ignore_global_phase

        common_tags = self._tags_to_accept & self._tags_to_ignore
        if common_tags:
            raise ValueError(
                f"Tag(s) '{list(common_tags)}' cannot be in both tags_to_accept and tags_to_ignore."
            )
Init GateFamily.

        Args:
            gate: A python `type` inheriting from `cirq.Gate` for type based membership checks, or
                a non-parameterized instance of a `cirq.Gate` for equality based membership checks.
            name: The name of the gate family.
            description: Human readable description of the gate family.
            ignore_global_phase: If True, value equality is checked via
                `cirq.equal_up_to_global_phase`.
            tags_to_accept: If non-empty, only `cirq.Operations` containing at least one tag in this
                sequence can be accepted.
            tags_to_ignore: Any `cirq.Operation` containing at least one tag in this sequence is
                rejected. Note that this takes precedence over `tags_to_accept`, so an operation
                which contains tags from both `tags_to_accept` and `tags_to_ignore` is rejected.

        Raises:
            ValueError: if `gate` is not a `cirq.Gate` instance or subclass.
            ValueError: if `gate` is a parameterized instance of `cirq.Gate`.
            ValueError: if `tags_to_accept` and `tags_to_ignore` contain common tags.
        
cirq-core/cirq/ops/gateset.py