torchoutil.pyoutil.warnings module¶
- deprecated_alias(alternative: ~typing.Callable[[~torchoutil.pyoutil.warnings.P], ~torchoutil.pyoutil.warnings.U], msg_fmt: str = "Deprecated call to '{fn_name}', use '{alternative_name}' instead.", warn_fn: ~typing.Callable[[str], ~typing.Any] = functools.partial(<functools._lru_cache_wrapper object>, category=<class 'DeprecationWarning'>)) Callable[[...], Callable[[P], U]][source]¶
Decorator to wrap deprecated aliases.
- deprecated_function(msg_fmt: str = "Deprecated call to '{fn_name}'.", warn_fn: ~typing.Callable[[str], ~typing.Any] = functools.partial(<functools._lru_cache_wrapper object>, category=<class 'DeprecationWarning'>)) Callable[[Callable[[P], U]], Callable[[P], U]][source]¶
Decorator to wrap deprecated functions.