-
Notifications
You must be signed in to change notification settings - Fork 705
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
Adding StopWordsRemover #59
Comments
How do I add the pyspark.ml.feature StopWordsRemover to the spark-nlp_2.11-1.2.3.jar file? |
@clayms As I see you have a line self._java_obj = self._new_java_obj("com.johnsnowlabs.nlp.annotators.StopWordsRemover", self.uid) I suggest to add pyspark StopWordsRemover as a first stage of your pipeline. |
Thank you @aleksei-ai . I see that now. I got the Spark ML StopWordsRemover to work previously together with the Spark ML RegexTokenizer, but was having trouble getting them to work in the same pipeline as the John Snow Labs annotators. I ended up putting those Spark ML stages at the end of the John Snow Labs annotator stages. The end results are what I am after. Thank you. |
In the upcoming release of Spark NLP |
I want to add the pyspark.ml.feature StopWordsRemover as a class in the annotator.py file so I can use that function in the same pipeline as the other sparknlp functions.
I have tried the code below, but I get the error:
TypeError: 'JavaPackage' object is not callable
What am I doing wrong?
The text was updated successfully, but these errors were encountered: