MulticanonicalState#

class graph_tool.inference.MulticanonicalState(state, S_min, S_max, nbins=1000)[source]#

Bases: object

The density of states of a multicanonical Monte Carlo algorithm. It is used by graph_tool.inference.multicanonical_equilibrate().

Parameters:
stateBlockState or OverlapBlockState or NestedBlockState

Block state to be used.

S_minfloat

Minimum energy.

S_maxfloat

Maximum energy.

nbinsint (optional, default: 1000)

Number of bins.

Methods

get_allowed_energies()

Get allowed energy bounds.

get_bin(S)

get_density([B])

Get density of states, normalized so that total sum is \(B^N\), where \(B\) is the number of groups, and \(N\) is the number of nodes.

get_energies()

Get energy bounds.

get_entropy(S[, B])

get_flatness([h, allow_gaps])

Get energy histogram flatness.

get_hist()

Get energy histogram.

get_perm_hist()

Get permanent energy histogram.

get_posterior([N])

Get posterior probability.

get_range()

Get energy range.

reset_hist()

Reset energy histogram.

sweep(**kwargs)

get_allowed_energies()[source]#

Get allowed energy bounds.

get_bin(S)[source]#
get_density(B=None)[source]#

Get density of states, normalized so that total sum is \(B^N\), where \(B\) is the number of groups, and \(N\) is the number of nodes. If not supplied \(B=N\) is assumed.

get_energies()[source]#

Get energy bounds.

get_entropy(S, B=None)[source]#
get_flatness(h=None, allow_gaps=True)[source]#

Get energy histogram flatness.

get_hist()[source]#

Get energy histogram.

get_perm_hist()[source]#

Get permanent energy histogram.

get_posterior(N=None)[source]#

Get posterior probability.

get_range()[source]#

Get energy range.

reset_hist()[source]#

Reset energy histogram.

sweep(**kwargs)[source]#