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

rng configuration object #323

Open
richfitz opened this issue Nov 8, 2021 · 0 comments
Open

rng configuration object #323

richfitz opened this issue Nov 8, 2021 · 0 comments

Comments

@richfitz
Copy link
Member

richfitz commented Nov 8, 2021

Now that we have multiple algorithms possible, some sort of rng state object that includes:

  • real_type
  • rng_state_type
  • normal algorithm
  • and the state

Then make overloads for things like

random_normal<real_type, algorithm, rng_state>(rng_state_type)

so that we can just write

random_normal(rng_state_type_wrapped)

something like

template <typename T>
typename T::real_type random_normal(T& state) {
  return random_normal<typename T::real_type, T::normal>(state.state);
}

See also #303 which is the same reallly

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant