We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent edbd6fe commit 415268eCopy full SHA for 415268e
python/pyspark/ml/pipeline.py
@@ -18,22 +18,10 @@
18
from abc import ABCMeta, abstractmethod
19
20
from pyspark.ml.param import Param, Params
21
-
22
-__all__ = ['Estimator', 'Transformer', 'Pipeline', 'PipelineModel']
+from pyspark.ml.util import inherit_doc
23
24
25
-def inherit_doc(cls):
26
- for name, func in vars(cls).items():
27
- # only inherit docstring for public functions
28
- if name.startswith("_"):
29
- continue
30
- if not func.__doc__:
31
- for parent in cls.__bases__:
32
- parent_func = getattr(parent, name, None)
33
- if parent_func and getattr(parent_func, "__doc__", None):
34
- func.__doc__ = parent_func.__doc__
35
- break
36
- return cls
+__all__ = ['Estimator', 'Transformer', 'Pipeline', 'PipelineModel']
37
38
39
@inherit_doc
0 commit comments