π Geometric Computer Vision Library for Spatial AI
Python artificial-intelligencecomputer-visiondeep-learninghacktoberfestimage-processingmachine-learningneural-networkpythonpytorchroboticsspatial-ai
Docs/core docstrings (#3716)
Jeevang1-epicf0c65537d81f
diff --git a/kornia/core/module.py b/kornia/core/module.pyindex 7b938f551..fc6ac4d35 100644--- a/kornia/core/module.py+++ b/kornia/core/module.py@@ -44,10 +44,28 @@ class ImageModule(nn.Module, ImageModuleMixIn, ONNXExportMixin):@propertydef disable_features(self) -> bool:+ """Whether convenience I/O (input/output) helper features are disabled.++ This flag controls the extra behavior provided by :class:`ImageModuleMixIn`,+ such as automatic input conversion (for example, PIL or NumPy inputs),+ automatic output conversion, and output caching for visualization helpers.++ Returns:+ ``True`` if the helper features are bypassed and the module behaves like+ a plain :class:`torch.nn.Module` call. ``False`` if helper features are enabled.+ """return self._disable_features@disable_features.setterdef disable_features(self, value: bool = True) -> None:+ """Enable or disable convenience I/O (input/output) handling features.++ Args:+ value: Feature toggle.+ - ``True``: disable automatic type conversion and output caching,+ so ``__call__`` behaves closer to a raw PyTorch module call.+ - ``False``: keep helper features active.+ """self._disable_features = valuedef __call__(@@ -103,10 +121,28 @@ class ImageSequential(nn.Sequential, ImageModuleMixIn, ONNXExportMixin):@propertydef disable_features(self) -> bool:+ """Whether convenience I/O (input/output) helper features are disabled.++ This flag controls the extra behavior provided by :class:`ImageModuleMixIn`,+ such as automatic input conversion (for example, PIL or NumPy inputs),+ automatic output conversion, and output caching for visualization helpers.++ Returns:+ ``True`` if the helper features are bypassed and the module behaves like+ a plain :class:`torch.nn.Sequential` call. ``False`` if helper features are enabled.+ """return self._disable_features@disable_features.setterdef disable_features(self, value: bool = True) -> None:+ """Enable or disable convenience I/O (input/output) handling features.++ Args:+ value: Feature toggle.+ - ``True``: disable automatic type conversion and output caching,+ so ``__call__`` behaves closer to a raw PyTorch sequential call.+ - ``False``: keep helper features active.+ """self._disable_features = valuedef __call__(