I use pyspark.ml.tuning.CrossValidator and Pipline to train a CrossValidatorModel named cv_model,after that,I want to persist the model, so i use cv_model.save to save my model,but an error occured:AttributeError: 'Pipeline' object has no attribute '_transfer_param_map_to_java' mycode
error message
I do not know how to solve the error. thanks for help me!
i find a way to solve the problem myself:
pip_model = cv_model.bestModel
pip_model.write().overwrite().save("/Users/fushuai/PyCharmProject/CTREstimation/model")
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With