You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@spark.apache.org by GitBox <gi...@apache.org> on 2020/10/10 17:41:27 UTC
[GitHub] [spark] zero323 commented on pull request #29998: [SPARK-32907][ML] adaptively blockify instances - LinearSVC
zero323 commented on pull request #29998:
URL: https://github.com/apache/spark/pull/29998#issuecomment-706585945
Thanks for the changes @zhengruifeng
Could also modify `shared.pyi` and add the import?
```
diff --git a/python/pyspark/ml/classification.pyi b/python/pyspark/ml/classification.pyi
index 74d11cfd11..241f5baf8d 100644
--- a/python/pyspark/ml/classification.pyi
+++ b/python/pyspark/ml/classification.pyi
@@ -26,6 +26,7 @@ from pyspark.ml.base import _PredictorParams
from pyspark.ml.param.shared import (
HasAggregationDepth,
HasBlockSize,
+ HasBlockSizeInMB,
HasElasticNetParam,
HasFitIntercept,
HasMaxIter,
diff --git a/python/pyspark/ml/param/shared.pyi b/python/pyspark/ml/param/shared.pyi
index 5999c0eaa4..bbb4890455 100644
--- a/python/pyspark/ml/param/shared.pyi
+++ b/python/pyspark/ml/param/shared.pyi
@@ -185,3 +185,8 @@ class HasBlockSize(Params):
blockSize: Param[int]
def __init__(self) -> None: ...
def getBlockSize(self) -> int: ...
+
+class HasBlockSizeInMB(Params):
+ blockSizeInMB: Param[float]
+ def __init__(self) -> None: ...
+ def getBlockSizeInMB(self) -> float: ...
```
In general you can verify consistency of annotations locally (sorry, still working on the pipeline):
```bash
# Checks annotations
mypy --no-incremental --config python/mypy.ini python/pyspark
# Checks Spark examples
MYPYPATH=python/ mypy --no-incremental --config python/mypy.ini examples/src/main/python/ml examples/src/main/python/sql examples/src/main/python/sql/streaming
```
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org