class_docstr: Returns a tensor with the specified shape, with random values from a Bernoulli
  distribution.
  
  .. math::
     f(k) = \begin{cases}1-p  &\text{if } k = 0\\
                      p    &\text{if } k = 1\end{cases}
  
  for :math:`k` in :math:`\{0, 1\}`.
  
  Parameters
  ----------
  shape: <K, i32> (Required)
      * Target output tensor shape.
      * ``K`` is the rank of the output tensor.
        ``shape[k] > 0`` for ``k = 0,..., K-1``.
  prob: const<T> (Optional)
      * The probability of sampling ``1``. Defaults to ``0.5``.
  seed: const<i32> (Optional)
      * Seed to create a reproducible sequence of values across multiple invokes.
  
  Returns
  -------
  <\*, T>
      * A tensor of the given target output shape filled with random values.
  
  Attributes
  ----------
  T: fp16, fp32
  
  See Also
  --------
  random_categorical, random_normal, random_uniform
class_docstr_tok: ["Returns","a","tensor","with","the","specified","shape",",","with","random","values","from","a","Bernoulli","distribution",".","..","math",":",":","f","(","k",")","=","\\begin","{","cases","}","1-p","&","\\text","{","if","}","k","=","0\\\\","p","&","\\text","{","if","}","k","=","1\\end","{","cases","}","for",":","math",":","`","k","`","in",":","math",":","`","\\","{","0",",","1\\","}","`",".","Parameters","--","--","--","--","--","shape",":","<","K",",","i32",">","(","Required",")","*","Target","output","tensor","shape",".","*","``","K","``","is","the","rank","of","the","output","tensor",".","``","shape","[","k","]",">","0","``","for","``","k","=","0",",","...",",","K-1","``",".","prob",":","const","<","T",">","(","Optional",")","*","The","probability","of","sampling","``","1","``",".","Defaults","to","``","0.5","``",".","seed",":","const","<","i32",">","(","Optional",")","*","Seed","to","create","a","reproducible","sequence","of","values","across","multiple","invokes",".","Returns","--","--","--","-","<","\\","*",",","T",">","*","A","tensor","of","the","given","target","output","shape","filled","with","random","values",".","Attributes","--","--","--","--","--","T",":","fp16",",","fp32","See","Also","--","--","--","--","random_categorical",",","random_normal",",","random_uniform"]
code: def type_inference(self):
      self.out_dtype = self.prob.dtype
      return super().type_inference()
  
imports: from coremltools.converters.mil.mil import get_new_symbol, get_new_variadic_symbol, types
  from coremltools.converters.mil.mil.input_type import DefaultInputs, InputSpec, TensorInputType
  from coremltools.converters.mil.mil.operation import Operation
  from coremltools.converters.mil.mil.ops.defs._op_reqs import register_op
  from coremltools.converters.mil.mil.types.symbolic import any_symbolic
label_desc: Use image node_id 2 for calling the random_bernoulli obj's underlying member method code with example usage: obj.type_inference() and returns: super