Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions monai/transforms/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -1544,13 +1544,17 @@ def get_transform_backends():
not in [
"BatchInverseTransform",
"Compose",
"CuCIM",
"CuCIMD",
"Decollated",
"InvertD",
"InvertibleTransform",
"Lambda",
"LambdaD",
"MapTransform",
"OneOf",
"RandCuCIM",
"RandCuCIMD",
"RandomOrder",
"PadListDataCollate",
"RandLambda",
Expand Down
32 changes: 32 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -35,3 +35,35 @@ exclude = '''
[tool.pycln]
all = true
exclude = "monai/bundle/__main__.py"

[tool.pytype]
# Space-separated list of files or directories to exclude.
exclude = ["versioneer.py", "_version.py"]
# Space-separated list of files or directories to process.
inputs = ["monai"]
# Keep going past errors to analyze as many files as possible.
keep_going = true
# Run N jobs in parallel.
jobs = 8
# All pytype output goes here.
output = ".pytype"
# Paths to source code directories, separated by ':'.
pythonpath = "."
# Check attribute values against their annotations.
check_attribute_types = true
# Check container mutations against their annotations.
check_container_types = true
# Check parameter defaults and assignments against their annotations.
check_parameter_types = true
# Check variable values against their annotations.
check_variable_types = true
# Comma or space separated list of error names to ignore.
disable = ["pyi-error"]
# Report errors.
report_errors = true
# Experimental: Infer precise return types even for invalid function calls.
precise_return = true
# Experimental: solve unknown types to label with structural types.
protocols = true
# Experimental: Only load submodules that are explicitly imported.
strict_import = false
2 changes: 1 addition & 1 deletion runtests.sh
Original file line number Diff line number Diff line change
Expand Up @@ -570,7 +570,7 @@ then
else
${cmdPrefix}${PY_EXE} -m pytype --version

${cmdPrefix}${PY_EXE} -m pytype -j ${NUM_PARALLEL} --python-version="$(${PY_EXE} -c "import sys; print(f'{sys.version_info.major}.{sys.version_info.minor}')")"
${cmdPrefix}${PY_EXE} -m pytype -j ${NUM_PARALLEL} --python-version="$(${PY_EXE} -c "import sys; print(f'{sys.version_info.major}.{sys.version_info.minor}')")" "$(pwd)"

pytype_status=$?
if [ ${pytype_status} -ne 0 ]
Expand Down
32 changes: 0 additions & 32 deletions setup.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -215,38 +215,6 @@ check_untyped_defs = True
# Warns about usage of untyped decorators.
disallow_untyped_decorators = True

[pytype]
# Space-separated list of files or directories to exclude.
exclude = versioneer.py _version.py
# Space-separated list of files or directories to process.
inputs = monai
# Keep going past errors to analyze as many files as possible.
keep_going = True
# Run N jobs in parallel.
jobs = 8
# All pytype output goes here.
output = .pytype
# Paths to source code directories, separated by ':'.
pythonpath = .
# Check attribute values against their annotations.
check_attribute_types = True
# Check container mutations against their annotations.
check_container_types = True
# Check parameter defaults and assignments against their annotations.
check_parameter_types = True
# Check variable values against their annotations.
check_variable_types = True
# Comma or space separated list of error names to ignore.
disable = pyi-error
# Report errors.
report_errors = True
# Experimental: Infer precise return types even for invalid function calls.
precise_return = True
# Experimental: solve unknown types to label with structural types.
protocols = True
# Experimental: Only load submodules that are explicitly imported.
strict_import = False

[coverage:run]
concurrency = multiprocessing
source = .
Expand Down