-
Notifications
You must be signed in to change notification settings - Fork 2
Description
The hypergeometric variate generator, used for the FixedTotalNumberConnector(with_replacement=False) connector, fails for large parameter values.
The hypergeometric generator generates a sample from the hypergeometric distribution with parameters ngood, nbad, and nsample. This is the distribution over the number of red balls we find when we sample nsample times without replacement from an urn containing ngood red balls and nbad white balls.
The generator works only if ngood, nbad, and nsample are less than 2^16.
In our case nbad is the size of the submatrix of the synaptic matrix we are dealing with, minus the number of synapses within the submatrix. This can take values at least as high as 1024^2.
Note that this sampler is only used for the FixedTotalNumberConnector with with_replacement=False. This is not a commonly used connector; it is currently unimplemented in PyNN, which ignores the with_replacement flag.