-
Notifications
You must be signed in to change notification settings - Fork 28.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[SPARK-29269][PYTHON][ML] Pyspark ALSModel support getters/setters #25947
Conversation
Test build #111468 has finished for PR 25947 at commit
|
@@ -131,7 +131,7 @@ private[recommendation] trait ALSModelParams extends Params with HasPredictionCo | |||
* Common params for ALS. | |||
*/ | |||
private[recommendation] trait ALSParams extends ALSModelParams with HasMaxIter with HasRegParam | |||
with HasPredictionCol with HasCheckpointInterval with HasSeed { | |||
with HasCheckpointInterval with HasSeed { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Because ALSModelParams already has HasPredictionCol?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes. It seems to be redundant to me.
""" | ||
Model fitted by ALS. | ||
|
||
.. versionadded:: 1.4.0 | ||
""" | ||
|
||
@since("1.4.0") | ||
def setUserCol(self, value): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These are newly added, right? So which one is more correct, since(1.4.0) or since(3.0.0)?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should be since(3.0.0). Thanks for catching that problem.
Test build #111505 has finished for PR 25947 at commit
|
Test build #111748 has finished for PR 25947 at commit
|
Test build #111758 has finished for PR 25947 at commit
|
retest this please |
Test build #111866 has finished for PR 25947 at commit
|
Merged to master. Thanks all! |
Thanks! @viirya @zhengruifeng |
### What changes were proposed in this pull request? Add getters/setters in Pyspark ALSModel. ### Why are the changes needed? To keep parity between python and scala. ### Does this PR introduce any user-facing change? Yes. add the following getters/setters to ALSModel ``` get/setUserCol get/setItemCol get/setColdStartStrategy get/setPredictionCol ``` ### How was this patch tested? add doctest Closes apache#25947 from huaxingao/spark-29269. Authored-by: Huaxin Gao <[email protected]> Signed-off-by: zhengruifeng <[email protected]>
What changes were proposed in this pull request?
Add getters/setters in Pyspark ALSModel.
Why are the changes needed?
To keep parity between python and scala.
Does this PR introduce any user-facing change?
Yes.
add the following getters/setters to ALSModel
How was this patch tested?
add doctest