def __init__(self, before_op: "mil.Operation"):
        """
        A context manager which makes the operations created within it contructed before the target ``before_op``.

        Parameters
        ----------
        before_op: Operation
            * The anchor op where the new op is going to be created at (right before `before_op`).
            * If the users explicity specify ``before_op`` when creating ``Operation`` object under this context manager, the builder
              will respect the one provided by the users.
        """
        if not isinstance(before_op, mil.Operation) and before_op is not None:
            raise ValueError(
                f"mb.set_before_op only accepts input of type Operation. Got {type(before_op)}."
            )
        self.before_op = before_op

        A context manager which makes the operations created within it contructed before the target ``before_op``.

        Parameters
        ----------
        before_op: Operation
            * The anchor op where the new op is going to be created at (right before `before_op`).
            * If the users explicity specify ``before_op`` when creating ``Operation`` object under this context manager, the builder
              will respect the one provided by the users.
        
coremltools/converters/mil/mil/builder.py