Commit 2a175140 authored by Tiago Peixoto's avatar Tiago Peixoto

inference: NestedBlockState constructor defaults to sampling=True

parent 8d546347
......@@ -512,6 +512,7 @@ def minimize_nested_blockmodel_dl(g, B_min=None, B_max=None, b_min=None,
state = NestedBlockState(g, bs=bs,
base_type=State,
deg_corr=deg_corr,
sampling=False,
**dmask(state_args, ["deg_corr"]))
bisection_args = dict(dict(mcmc_multilevel_args=mcmc_multilevel_args,
......
......@@ -53,7 +53,7 @@ class NestedBlockState(object):
hentropy_args : ``dict`` (optional, default: `{}`)
Keyword arguments to be passed to the ``entropy()`` method of the
higher-level states.
sampling : ``bool`` (optional, default: ``False``)
sampling : ``bool`` (optional, default: ``True``)
If ``True``, the state will be properly prepared for MCMC sampling (as
opposed to minimization).
state_args : ``dict`` (optional, default: ``{}``)
......@@ -64,7 +64,7 @@ class NestedBlockState(object):
"""
def __init__(self, g, bs, base_type=BlockState, state_args={},
hstate_args={}, hentropy_args={}, sampling=False, **kwargs):
hstate_args={}, hentropy_args={}, sampling=True, **kwargs):
self.g = g
self.base_type = base_type
if base_type is LayeredBlockState:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment