-
Notifications
You must be signed in to change notification settings - Fork 22
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
iQMC Batch Method #223
iQMC Batch Method #223
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I can't speak to the methods themselves, but I think these changes make the code substantially more readable and will eventually look great in the rendered scheme. On the front of documentation there is a page in the theory guide for iqmc that is currently empty. Eventually adding to that would also go a long way in documenting what you've got here (not urgent tho)
Do you mean "fixed seed mode", @spasmann? |
Thank you @jpmorgan98 ! I've added the theory guide to my todo list. Yes, fixed seed not fixed source. Thanks, @ilhamv. |
All tests passing! @ilhamv |
Description
The primary goals of this PR are to i) implement a randomized-QMC batching method for eigenvalue calculations ii) continue to increase the readability and maintainability of iQMC. Users can now specify an iQMC run mode with
mode='fixed'
ormode='batched'
in the iQMC input settings, which toggles between the fixed seed and randomized-QMC batch methods. Additionally, the user can specify thesample_method
and choose between either'halton'
or'random'
. Both sample methods can be used in either fixed seed or batched mode.halton
refers to the halton sequence (standard and randomized)random
refers to typical prng samples, which are currently generated with numpy.The randomized-QMC batching method uses the randomized halton sequence to accumulate batch statistics in much the same way as batched Monte Carlo eigenvalue calculations. In fixed seed mode the change in the source strength every iteration comes only from convergence towards the solution. Whereas in batched mode the change in source strength is due to convergence towards the solution and some stochastic noise introduced from randomizing the samples. As a result, iQMC tallies now have a
mean
,sdev
, andbin
components like standard Monte Carlo tallies.Additional Changes:
iqmc_kernel.py
andiqmc_loop.py
, grouping functions by operation.iqmc_validate_inputs()
function to validate the iQMC input settings.allreduce_array()
function added tokernel.py
make_type_score()
to be a global function intype_.py
to be accesses by both Monte Carlo and iQMC scores.Planned Work
iqmc_kernel.py
functions.sample_method='random'
, with MCDC's rng functionality.