facebookresearch / nevergrad

A Python toolbox for performing gradient-free optimization

Home Page:https://facebookresearch.github.io/nevergrad/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Incorrect code blocks in doc

londumas opened this issue · comments

In section "Optimization with constraints" of the documentation,
some code blocks are not rendered properly.

https://facebookresearch.github.io/nevergrad/optimization.html#optimization-with-constraints

"""
Then, if you want to work with the ask/tell form, instead of .. code-block:: python

optimizer.tell(candidate, value)

you can do .. code-block:: python

optimizer.tell(candidate, value, [constraint_violation1, constraint_violation2, constraint_violation3])

Or, if you work with minimize, you can also replace .. code-block:: python

optimizer.minimize(loss_function)

by .. code-block:: python

optimizer.minimize(loss_function, constraint_violations)

where constraint_violations maps a candidate to a vector of constraint violations.
"""