50% off: Unlimited data and AI learning.
The Learning Leader's Guide to AI Literacy

torch (version 0.11.0)

distr_poisson: Creates a Poisson distribution parameterized by rate, the rate parameter.

Description

Samples are nonnegative integers, with a pmf given by ratekeratek!

Usage

distr_poisson(rate, validate_args = NULL)

Arguments

rate

(numeric, torch_tensor): the rate parameter

validate_args

whether to validate arguments or not.

See Also

Distribution for details on the available methods.

Other distributions: distr_bernoulli(), distr_chi2(), distr_gamma(), distr_multivariate_normal(), distr_normal()

Examples

Run this code
if (torch_is_installed()) {
m <- distr_poisson(torch_tensor(4))
m$sample()
}

Run the code above in your browser using DataLab