Water Tank
  • Home
  • Notebooks
  • API Reference
  1. Random distributions
  2. Bernouilli
  • API reference
  • Layers
    • RecurrentLayer
    • LinearReadout
    • StaticInput
    • TimeSeriesInput
  • Projections
    • connect
  • Learning rules
    • DeltaLearningRule
    • RLS
  • Random distributions
    • Const
    • Uniform
    • Normal
    • Bernouilli
  • Utilities
    • Recorder

On this page

  • Bernouilli
    • Parameters
    • Methods
      • sample

Bernouilli

random.Bernouilli(self, values, p=0.5)

Bernouilli (binomial) distribution, returning the first of the two values with probability p.

Parameters

Name Type Description Default
values list list of values. required
p float probability of returning the first value. 0.5

Methods

Name Description
sample Samples from the distribution and returns an array of the desired shape.

sample

random.Bernouilli.sample(shape)

Samples from the distribution and returns an array of the desired shape.

Normal
Recorder
 

Copyright Julien Vitay