Skip to content

Commit 3fb80ae

Browse files
committed
fix: remove doctest, fix sloppy/debug flag
1 parent e7d7ac8 commit 3fb80ae

File tree

3 files changed

+20
-15
lines changed

3 files changed

+20
-15
lines changed

docs/api.rst

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,11 @@
44
Developers - API
55
================
66

7+
Internal configuration system
8+
-----------------------------
9+
10+
.. automodule:: fmriprep.config
11+
712
Workflows
813
---------
914

fmriprep/cli/parser.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -278,7 +278,7 @@ def _bids_filter(value):
278278
'the FMRIPREP developers. This information helps to '
279279
'improve FMRIPREP and provides an indicator of real '
280280
'world usage crucial for obtaining funding.')
281-
g_other.add_argument('--sloppy', action='store_true', default=False,
281+
g_other.add_argument('--sloppy', dest='debug', action='store_true', default=False,
282282
help='Use low-quality tools for speed - TESTING ONLY')
283283

284284
latest = check_latest()

fmriprep/config.py

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -10,19 +10,19 @@
1010
1111
.. code-block:: Python
1212
13-
>>> from fmriprep import config
14-
>>> config_file = config.execution.work_dir / '.fmriprep.toml'
15-
>>> config.to_filename(config_file)
16-
>>> # Call build_workflow(config_file, retval) in a subprocess
17-
>>> with Manager() as mgr:
18-
>>> from .workflow import build_workflow
19-
>>> retval = mgr.dict()
20-
>>> p = Process(target=build_workflow, args=(str(config_file), retval))
21-
>>> p.start()
22-
>>> p.join()
23-
>>> config.load(config_file)
24-
>>> # Access configs from any code section as:
25-
>>> value = config.section.setting
13+
from fmriprep import config
14+
config_file = config.execution.work_dir / '.fmriprep.toml'
15+
config.to_filename(config_file)
16+
# Call build_workflow(config_file, retval) in a subprocess
17+
with Manager() as mgr:
18+
from .workflow import build_workflow
19+
retval = mgr.dict()
20+
p = Process(target=build_workflow, args=(str(config_file), retval))
21+
p.start()
22+
p.join()
23+
config.load(config_file)
24+
# Access configs from any code section as:
25+
value = config.section.setting
2626
2727
The module also has a :py:func:`to_filename` function to allow writting out
2828
the settings to hard disk in *ToML* format, which looks like
@@ -313,7 +313,7 @@ class execution(_Config):
313313
"""A dictionary of BIDS selection filters."""
314314
boilerplate_only = False
315315
"""Only generate a boilerplate."""
316-
debug = None
316+
debug = False
317317
"""Run in sloppy mode (meaning, suboptimal parameters that minimize run-time)."""
318318
echo_idx = None
319319
"""Select a particular echo for multi-echo EPI datasets."""

0 commit comments

Comments
 (0)