创建ML NLP的原因:EXC_BAD_INSTRUCTION(代码= EXC_I386_INVOP,子代码= 0x0)

时间:2019-04-01 03:24:19

标签: nlp createml

我正在尝试在Xcode操场上为NLP Create ML运行以下代码:

import Cocoa
import CreateML

let data = try MLDataTable(contentsOf: URL(fileURLWithPath: "/Users/limjunqu/Downloads/spam.csv"))

let (trainingData, testingData) = data.randomSplit(by: 0.8, seed: 5)

let sentimentClassifier = try MLTextClassifier(trainingData: trainingData,textColumn: "v2",labelColumn: "v1")

这似乎很简单,但我不断收到错误消息:

error: Execution was interrupted, reason: EXC_BAD_INSTRUCTION (code=EXC_I386_INVOP, subcode=0x0).
The process has been left at the point where it was interrupted, use "thread return -x" to return to the state before expression evaluation.

在最后一行。

0 个答案:

没有答案