Simulation

A DMC simulation class. Uses a number of subclasses to manage its methods

Properties and Methods

load_lib: method
reload_lib: method

 

__init__(self, params): 

Initializes the simulation from the simulation parameters

  • params: SimulationParameters

    the parameters for the simulation

 

configure_simulation(self, name='dmc', description='a dmc simulation', walker_set=None, time_step=0, alpha=None, potential=None, atomic_units=False, steps_per_propagation=None, mpi_manager=True, importance_sampler=None, num_wavefunctions=0, ignore_errors=False, branching_threshold=1.0, energy_error_value=1000000000.0, max_weight_threshold=None, min_potential_threshold=None, branch_on_steps=False, parallelize_diffusion=True, branch_on_cores=False, random_seed=None, pre_run_script=None, post_run_script=None): 
  • name: str

    No description…

  • description: str

    No description…

  • walker_set: WalkerSet

    No description…

  • time_step: int

    No description…

  • alpha: float

    No description…

  • potential: str | Potential

    No description…

  • mpi_manager: MPIManagerObject

    No description…

  • steps_per_propagation: int

    No description…

  • importance_sampler: ImportanceSampler

    No description…

  • :returns: _

    No description…

 

@property
config_string(self): 

 

checkpoint(self, test=True): 

 

garbage_collect(self, test=True): 

 

reload(self, energies_file='energies.npy', walkers_file='walkers_{n}.npz', full_weights_file='full_weights.npy', full_energies_file='full_energies.npy'): 

Reloads the core data in a Simulation object from a checkpoint file

  • core_dir: Any

    No description…

  • params_file: Any

    No description…

 

log_print(self, *arg, allow_dummy=False, **kwargs): 

 

run(self): 

Runs the DMC until we’ve gone through the requested number of time steps, checkpoint-ing if there’s a crash

  • :returns: _

    No description…

 

@property
lib(self): 

 

apply_branching(self, energies): 

 

evaluate_potential_and_branch(self, nsteps): 

 

propagate(self, nsteps=None): 

Propagates the system forward n steps

  • nsteps: Any

    number of steps to propagate for; None means automatic

  • :returns: _

    No description…

 

update_weights(self, energies, weights): 

Iteratively updates the weights over a set of vectors of energies

  • energies: np.ndarray

    No description…

  • weights: np.ndarray

    No description…

  • :returns: np.ndarray

    No description…

 

chop_weights(eliminated_walkers, weights, parents, walkers, energies): 

 

branch(self, energies): 

Handles branching in the system.

  • :returns: _

    No description…

 

descendent_weight(self): 

Calls into the walker descendent weighting if the timing is right

  • :returns: _

    No description…

Examples


Edit Examples or Create New Examples
Edit Template or Create New Template
Edit Docstrings