apache-spark - org.apache.spark.SparkException:作业因 pyspark 中的阶段失败而中止
问题描述
抱歉重复的帖子。我正在再次创建另一个帖子,因为这些帖子无法解决我的问题。我在 pyspark 3.0.1 上运行 ML 回归。我在 640 GB 内存和 32 个工作节点的集群上运行它。我有一个包含 33751 行和 63 列的数据集。我正在尝试为 ML 回归准备数据集。所以我写了以下代码
from pyspark.ml.feature import VectorAssembler, StandardScaler
input_col=[...]
vector_assembler=VectorAssembler(inputCols=input_col,outputCol='ss_feature')
temp_train=vector_assembler.transform(train)
standard_scaler=StandardScaler(inputCol='ss_feature',outputCol='scaled')
train=standard_scaler.fit(temp_train).transform(temp_train)
但我在最后一行执行时收到错误消息
org.apache.spark.SparkException: Job aborted due to stage failure: Task 169 in stage 57.0 failed 4
times, most recent failure: Lost task 169.3 in stage 57.0 (TID 5522, 10.8.64.22, executor 11):
org.apache.spark.SparkException: Failed to execute user defined
function(VectorAssembler$$Lambda$6296/1890764576:
你能建议我如何解决这个问题吗?
解决方案
推荐阅读
- react-native - 我可以让我的应用在没有任何 UI 的情况下在后台运行吗
- r - 如何从 r 中的列表中消除行
- kubernetes - 如何在 Kubernetes 部署中用 jq 替换 Image?
- arrays - 数组值需要 Fortan 建议
- vba - Word 宏,选择并附加到粗体文本
- c++ - 编译得很好,但是当它达到某个点时运行失败。我究竟做错了什么?
- javascript - 从顶部开始滚动 30px 的 div
- powershell - Flutter 更新导致错误“Flutter 需要 PowerShell 5.0 或更新版本”不可恢复
- python - Toplevel 中的 CheckButton 状态检查
- android - 谁能告诉我如何在 Firebase Firestore (Android) 中存储一组自定义对象