r"""Returns an iterable for all the submodules that are direct attributes of this module.
(self, **kwargs)
| 330 | ) |
| 331 | |
| 332 | def children(self, **kwargs) -> "Iterable[Module]": |
| 333 | r"""Returns an iterable for all the submodules that are direct attributes of this |
| 334 | module. |
| 335 | """ |
| 336 | yield from self._flatten( |
| 337 | with_key=False, predicate=_is_module, recursive=False, **kwargs |
| 338 | ) |
| 339 | |
| 340 | def named_children(self, **kwargs) -> "Iterable[Tuple[str, Module]]": |
| 341 | r"""Returns an iterable of key-submodule pairs for all the submodules that are |