integratorAPI module¶
- class SurveyRefineIntegratorAPI(*args, **kwargs)[source]¶
Bases:
better_abc.ABC
API specification for an integrator that performs a number of survey steps in which a flow model is trained and then a number of refine steps in which sampling is done through the model The interaction with the model is done through the GenericTrainerAPI
- abstract finalize_integration(**kwargs)[source]¶
Perform the final operations of the whole integration
- format_arguments(**kwargs)[source]¶
Format keyword arguments passed to the train function in a suitable way In this generic API definition, the kwargs must be passed in the correct format however for a specific realization, options should be made accessible through keywords which will then be sorted into the right structure.
- abstract process_refine_step(sample, integral, integral_var, **kwargs)[source]¶
Process the result of a refine step
- abstract process_survey_step(sample, integral, integral_var, **kwargs)[source]¶
Process the result of a survey step
- refine(n_refine_steps=10, **kwargs)[source]¶
Perform the refine phase of integration
Possible keyword arguments:
trainer_config_args: dict refine_step_args: dict finalize_refine_args: dict
- refine_step(**kwargs)[source]¶
Basic refine step: sample points, estimate the integral, its error, train model
- possible keyword arguments:
sampling_args: dict