sparkexception:由于阶段失败而中止作业:

jv4diomz  于 2021-07-12  发布在  Spark
关注(0)|答案(0)|浏览(302)

边做边学。有这个问题。

featurizer = DeepImageFeaturizer(inputCol="image",outputCol="features",modelName="InceptionV3")

lr = LogisticRegression(maxIter=1,regParam=0.03,elasticNetParam=0.5, labelCol="label")

sparkdn = Pipeline(stages=[featurizer,lr])
spark_model = sparkdn.fit(train)

出现错误

/usr/spark/spark-2.4.7-bin-hadoop2.7/python/lib/py4j-0.10.7-src.zip/py4j/protocol.py in get_return_value(answer, gateway_client, target_id, name)
    326                 raise Py4JJavaError(
    327                     "An error occurred while calling {0}{1}{2}.\n".
--> 328                     format(target_id, ".", name), value)
    329             else:
    330                 raise Py4JError(

Py4JJavaError: An error occurred while calling o371.collectToPython.
: org.apache.spark.SparkException: Job aborted due to stage failure: Task 0 in stage 21.0 failed 1 times, most recent failure: Lost task 0.0 in stage 21.0 (TID 700, localhost, executor driver): org.apache.spark.SparkException: 
Error from python worker:
  Traceback (most recent call last):
    File "/usr/lib/python3.8/runpy.py", line 185, in _run_module_as_main
      mod_name, mod_spec, code = _get_module_details(mod_name, _Error)
    File "/usr/lib/python3.8/runpy.py", line 111, in _get_module_details
      __import__(pkg_name)

尝试为conda安装jdk-8重新安装py4j

暂无答案!

目前还没有任何答案,快来回答吧!

相关问题