def add_random_bernoulli_like(
        self, name, input_name, output_name, prob=0.5, seed=-1
    ):
        """
        Add a random_bernoulli_like layer to the model that fills the output
        tensor with random values from Bernoulli distribution.
        Refer to the ``RandomBernoulliLikeLayerParams`` message in the specification
        (NeuralNetwork.proto) for more details.

        Parameters
        ----------
        name: str
            The name of this layer.
        input_name: str
            The input blob name of this layer.
        output_name: str
            The output blob name of this layer.
        prob: float, optional
            Probabilities for Bernoulli distribution, default: 0.5.
        seed: int, optional
            Used to create a random seed for the distribution. default -1 (random).

        See Also
        --------
        add_random_bernoulli_static, add_random_bernoulli_dynamic
        """

        spec_layer = self._add_generic_layer(name, [input_name], [output_name])
        spec_layer_params = spec_layer.randomBernoulliLike

        spec_layer_params.prob = prob
        spec_layer_params.seed = seed

        return spec_layer

        Add a random_bernoulli_like layer to the model that fills the output
        tensor with random values from Bernoulli distribution.
        Refer to the ``RandomBernoulliLikeLayerParams`` message in the specification
        (NeuralNetwork.proto) for more details.

        Parameters
        ----------
        name: str
            The name of this layer.
        input_name: str
            The input blob name of this layer.
        output_name: str
            The output blob name of this layer.
        prob: float, optional
            Probabilities for Bernoulli distribution, default: 0.5.
        seed: int, optional
            Used to create a random seed for the distribution. default -1 (random).

        See Also
        --------
        add_random_bernoulli_static, add_random_bernoulli_dynamic
        
coremltools/models/neural_network/builder.py