
纠错
iken_g
肝肝肝
展开
-
【scala使用spark报错】illegal cyclic inheritance involving trait Iterable val df = Seq(
报错信息illegal cyclic inheritance involving trait Iterable val df = Seq(原因scala和spark版本不相符笔者报错版本spark 2.1.1scala 2.13更改后版本spark 2.1.1scala 2.11.8运行成功注笔者在project structure的global Libraries (如上)添加scala版本,运行无效,报同样的错。后来在libraries添加后成功(如下),知道原因的留言教教小原创 2021-03-20 19:30:55 · 5396 阅读 · 0 评论 -
TypeError: expected string or bytes-like object
TypeError: expected string or bytes-like object报错代码:def json(self,strs, key): #print(type(strs)) strs =str(strs) strs = re.sub("'",'"',strs) #print(strs) dict_ = json.loads(strs...原创 2019-05-01 22:13:39 · 5905 阅读 · 0 评论 -
错误:TypeError: can't multiply sequence by non-int of type 'numpy.float64'
错误:TypeError: can’t multiply sequence by non-int of type ‘numpy.float64’错误代码:该代码是逻辑回归(Logistic Regression)中的改进后的随机梯度上升算法def stocGradAscent1(dataMatrix, classLabels, numIter=150): #dataMatrix=n...原创 2019-05-03 18:36:49 · 29402 阅读 · 7 评论