graph_tool.inference.MulticanonicalMCMCState#
- class graph_tool.inference.MulticanonicalMCMCState[source]#
Bases:
ABC
Base state that implements multicanonical MCMC sweeps
Methods
multicanonical_sweep
(m_state[, multiflip])Perform
niter
sweeps of a non-Markovian multicanonical sampling using the Wang-Landau algorithm.- multicanonical_sweep(m_state, multiflip=False, **kwargs)[source]#
Perform
niter
sweeps of a non-Markovian multicanonical sampling using the Wang-Landau algorithm.- Parameters:
- m_state
MulticanonicalState
MulticanonicalState
instance containing the current state of the Wang-Landau run.- multiflip
bool
(optional, default:False
) If
True
,multiflip_mcmc_sweep()
will be used, otherwisemcmc_sweep()
.- **kwargsKeyword parameter list
The remaining parameters will be passed to
multiflip_mcmc_sweep()
ormcmc_sweep()
.
- m_state
- Returns:
- dS
float
Entropy difference after the sweeps.
- nattempts
int
Number of vertex moves attempted.
- nmoves
int
Number of vertices moved.
- dS
Notes
This algorithm has an \(O(E)\) complexity, where \(E\) is the number of edges (independent of the number of groups).
References
[wang-efficient-2001]Fugao Wang, D. P. Landau, “An efficient, multiple range random walk algorithm to calculate the density of states”, Phys. Rev. Lett. 86, 2050 (2001), DOI: 10.1103/PhysRevLett.86.2050 [sci-hub, @tor], arXiv: cond-mat/0011174