Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
graph-tool
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
43
Issues
43
List
Boards
Labels
Service Desk
Milestones
Merge Requests
1
Merge Requests
1
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Incidents
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Tiago Peixoto
graph-tool
Commits
64789f16
Commit
64789f16
authored
Feb 21, 2017
by
Tiago Peixoto
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
mcmc_equilibrate(): Fix error in docstring
parent
dc6d19ff
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
4 deletions
+5
-4
src/graph_tool/inference/mcmc.py
src/graph_tool/inference/mcmc.py
+5
-4
No files found.
src/graph_tool/inference/mcmc.py
View file @
64789f16
...
@@ -63,8 +63,9 @@ def mcmc_equilibrate(state, wait=1000, nbreaks=2, max_niter=numpy.inf,
...
@@ -63,8 +63,9 @@ def mcmc_equilibrate(state, wait=1000, nbreaks=2, max_niter=numpy.inf,
mcmc_args : ``dict`` (optional, default: ``{}``)
mcmc_args : ``dict`` (optional, default: ``{}``)
Arguments to be passed to ``state.mcmc_sweep`` (or ``state.gibbs_sweep``).
Arguments to be passed to ``state.mcmc_sweep`` (or ``state.gibbs_sweep``).
history : ``bool`` (optional, default: ``False``)
history : ``bool`` (optional, default: ``False``)
If ``True``, a list of tuples of the form ``(iteration, entropy)`` will
If ``True``, a list of tuples of the form ``(entropy, nmoves)`` will
be kept and returned.
be kept and returned, where ``entropy`` is the current entropy and
``nmoves`` is the number of vertices moved.
callback : ``function`` (optional, default: ``None``)
callback : ``function`` (optional, default: ``None``)
If given, this function will be called after each iteration. The
If given, this function will be called after each iteration. The
function must accept the current state as an argument, and its return
function must accept the current state as an argument, and its return
...
@@ -93,7 +94,7 @@ def mcmc_equilibrate(state, wait=1000, nbreaks=2, max_niter=numpy.inf,
...
@@ -93,7 +94,7 @@ def mcmc_equilibrate(state, wait=1000, nbreaks=2, max_niter=numpy.inf,
Returns
Returns
-------
-------
history : list of tuples of the form ``(
iteration, entropy
)``
history : list of tuples of the form ``(
entropy, nmoves
)``
Summary of the MCMC run. This is returned only if ``history == True``.
Summary of the MCMC run. This is returned only if ``history == True``.
entropy : ``float``
entropy : ``float``
Current entropy value after run. This is returned only if ``history ==
Current entropy value after run. This is returned only if ``history ==
...
@@ -181,7 +182,7 @@ def mcmc_equilibrate(state, wait=1000, nbreaks=2, max_niter=numpy.inf,
...
@@ -181,7 +182,7 @@ def mcmc_equilibrate(state, wait=1000, nbreaks=2, max_niter=numpy.inf,
str
(
extra
)
if
len
(
extra
)
>
0
else
""
))
str
(
extra
)
if
len
(
extra
)
>
0
else
""
))
if
history
:
if
history
:
hist
.
append
(
[
S
,
nmoves
]
+
extra
)
hist
.
append
(
tuple
([
S
,
nmoves
]
+
extra
)
)
if
niter
>=
max_niter
:
if
niter
>=
max_niter
:
break
break
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment