pickle.PicklingError: args[0] from __newobj__ args has the wrong class with hadoop python

前端 未结 3 967
死守一世寂寞
死守一世寂寞 2021-01-13 08:44

I am trying to I am tring to delete stop words via spark,the code is as follow

from nltk.corpus import stopwords
from pyspark.context import SparkContext
fro         


        
3条回答
  •  独厮守ぢ
    2021-01-13 09:25

    Probably, it's just because you are defining the stopwords.words('english') every time on the executor. Define it outside and this would work.

提交回复
热议问题