usage: pybind11-stubgen [-h] [-o OUTPUT_DIR] [--root-suffix ROOT_SUFFIX] [--ignore-invalid-expressions REGEX] [--ignore-invalid-identifiers REGEX] [--ignore-unresolved-names REGEX] [--ignore-all-errors] [--enum-class-locations REGEX:LOC] [--numpy-array-wrap-with-annotated | --numpy-array-use-type-var | --numpy-array-remove-parameters] [--print-invalid-expressions-as-is] [--print-safe-value-reprs REGEX] [--print-value-comments] [--exit-code] [--dry-run] [--stub-extension EXT] MODULE_NAMES [MODULE_NAMES ...] Generates stubs for specified modules positional arguments: MODULE_NAMES module names options: -h, --help show this help message and exit -o, --output-dir OUTPUT_DIR The root directory for output stubs --root-suffix ROOT_SUFFIX Top-level module directory suffix --ignore-invalid-expressions REGEX Ignore invalid expressions matching REGEX --ignore-invalid-identifiers REGEX Ignore invalid identifiers matching REGEX --ignore-unresolved-names REGEX Ignore unresolved names matching REGEX --ignore-all-errors Ignore all errors during module parsing --enum-class-locations REGEX:LOC Locations of enum classes in : format. Example: `MyEnum:foo.bar.Baz` --numpy-array-wrap-with-annotated Replace numpy/scipy arrays of 'ARRAY_T[TYPE, [*DIMS], *FLAGS]' format with 'Annotated[ARRAY_T, TYPE, FixedSize|DynamicSize(*DIMS), *FLAGS]' --numpy-array-use-type-var Replace 'numpy.ndarray[numpy.float32[m, 1]]' with 'numpy.ndarray[tuple[M, typing.Literal[1]], numpy.dtype[numpy.float32]]' --numpy-array-remove-parameters Replace 'numpy.ndarray[...]' with 'numpy.ndarray' --print-invalid-expressions-as-is Suppress the replacement with '...' of invalid expressionsfound in annotations --print-safe-value-reprs REGEX Override the print-safe check for values matching REGEX --print-value-comments Print attribute values as comments for debugging, i.e., '... # value = ' --exit-code On error exits with 1 and skips stub generation --dry-run Don't write stubs. Parses module and report errors --stub-extension EXT The file extension of the generated stubs. Must be 'pyi' (default) or 'py'