Skip to content

Latest commit

 

History

History
42 lines (26 loc) · 617 Bytes

File metadata and controls

42 lines (26 loc) · 617 Bytes

nilearn-stubs: unofficial type stubs for nilearn

Install

pip install -e '.[dev]'

Run tests with monkeytype

For example on nilearn/_utils

monkeytype run -m pytest nilearn/nilearn/_utils

List annotated modules

monkeytype list-modules

Generate stub

For example on nilearn/_utils/path_finding.py

monkeytype stub nilearn._utils.path_finding > nilearn/_utils/path_finding.pyi

Several files at once

Use a script:

python generate_nilearn_stubs.py

Add annotation to codebase

python maint_tools/apply_types.py _utils/bids.pyi