Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

rand_distr: Fix dirichlet sample method for small alpha. #1209

Merged
merged 9 commits into from
May 1, 2023

Commits on Jan 2, 2022

  1. rand_distr: Fix dirichlet sample method for small alpha.

    Generating Dirichlet samples using the method based on samples from
    the gamma distribution can result in samples being nan if all the
    values in alpha are sufficiently small.  The fix is to instead use
    the method based on the marginal distributions being the beta
    distribution (i.e. the "stick breaking" method) when all values in
    alpha are small.
    WarrenWeckesser committed Jan 2, 2022
    Configuration menu
    Copy the full SHA
    745ace8 View commit details
    Browse the repository at this point in the history

Commits on Feb 28, 2023

  1. Configuration menu
    Copy the full SHA
    c44ac16 View commit details
    Browse the repository at this point in the history
  2. Refactor:

    * Create a struct for each random variate generation method:
      DirichletFromGamma and DirichletFromBeta.
    * Move the initialization of the data required by the generators
      into the new() method.
    * Make the main Dirichlet object an enum.
    WarrenWeckesser committed Feb 28, 2023
    Configuration menu
    Copy the full SHA
    4ecb35e View commit details
    Browse the repository at this point in the history

Commits on Mar 1, 2023

  1. Configuration menu
    Copy the full SHA
    7513e83 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    030d2ad View commit details
    Browse the repository at this point in the history

Commits on Mar 25, 2023

  1. Merge master and fix conflicts.

    The main change is that Dirichlet now has a const trait N for
    the dimension.  The other significant change is to propagate
    errors that could occur when Beta:new or Gamma::new is called.
    WarrenWeckesser committed Mar 25, 2023
    Configuration menu
    Copy the full SHA
    7c97f9b View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    7fcb25f View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    2225652 View commit details
    Browse the repository at this point in the history

Commits on Mar 30, 2023

  1. Configuration menu
    Copy the full SHA
    c12db0b View commit details
    Browse the repository at this point in the history