Skip to content

Commit fbc686c

Browse files
committed
Fix docstring formatting
1 parent 0836e68 commit fbc686c

File tree

1 file changed

+17
-16
lines changed

1 file changed

+17
-16
lines changed

adaptive/runner.py

Lines changed: 17 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -891,22 +891,23 @@ def auto_goal(
891891
goal
892892
The goal to extract. Can be a callable, an integer, a float, a datetime,
893893
a timedelta or None.
894-
If it is a callable, it is returned as is.
895-
If it is an integer, the goal is reached after that many points have been
896-
returned.
897-
If it is a float, the goal is reached when the learner has reached a loss
898-
equal or less than that.
899-
If it is a datetime, the goal is reached when the current time is after the
900-
datetime.
901-
If it is a timedelta, the goal is reached when the current time is after
902-
the start time plus that timedelta.
903-
If it is None, and
904-
- the learner type is `adaptive.SequenceLearner`, it continues until
905-
it no more points to add
906-
- the learner type is `adaptive.IntegratorLearner`, it continues until the
907-
error is less than the tolerance specified in the learner.
908-
- otherwise, it continues forever, unless `allow_running_forever` is
909-
False, in which case it raises a ValueError.
894+
If the type of `goal` is:
895+
896+
* ``callable``, it is returned as is.
897+
* ``int``, the goal is reached after that many points have been added.
898+
* ``float``, the goal is reached when the learner has reached a loss
899+
equal or less than that.
900+
* `datetime.datetime`, the goal is reached when the current time is after the
901+
datetime.
902+
* `datetime.timedelta`, the goal is reached when the current time is after
903+
the start time plus that timedelta.
904+
* ``None`` and
905+
* the learner type is `adaptive.SequenceLearner`, it continues until
906+
it no more points to add
907+
* the learner type is `adaptive.IntegratorLearner`, it continues until the
908+
error is less than the tolerance specified in the learner.
909+
* otherwise, it continues forever, unless ``allow_running_forever`` is
910+
False, in which case it raises a ValueError.
910911
learner
911912
Learner for which to determine the goal.
912913
allow_running_forever

0 commit comments

Comments
 (0)