全部版块 我的主页
论坛 数据科学与人工智能 大数据分析 Hadoop论坛
3017 3
2018-12-28
复制代码
-------------------------------------------------------------------------------------------------------------------------------------------
18/12/28 13:57:29 WARN HiveConf: HiveConf of name hive.server2.enable.impersonation does not exist
18/12/28 13:57:29 WARN metastore: Failed to connect to the MetaStore Server...
18/12/28 13:57:30 WARN metastore: Failed to connect to the MetaStore Server...
18/12/28 13:57:31 WARN metastore: Failed to connect to the MetaStore Server...
18/12/28 13:57:32 WARN Hive: Failed to access metastore. This class should not accessed in runtime.
org.apache.hadoop.hive.ql.metadata.HiveException: java.lang.RuntimeException: Unable to instantiate o                      rg.apache.hadoop.hive.ql.metadata.SessionHiveMetaStoreClient
请问为什么会这样呢,其他方法,比如线性回归,SVM,随机森林等等都没有问题,只有logistic回归会报这个错误
二维码

扫码加我 拉你入群

请注明:姓名-公司-职位

以便审核进群资格,未注明则拒绝

全部回复
2018-12-28 14:38:19
尝试用随机梯度就没有问题
二维码

扫码加我 拉你入群

请注明:姓名-公司-职位

以便审核进群资格,未注明则拒绝

2018-12-28 15:02:43
>>> multi_class_data = [
...     LabeledPoint(0.0, [0.0, 1.0, 0.0]),
...     LabeledPoint(1.0, [1.0, 0.0, 0.0]),
...     LabeledPoint(2.0, [0.0, 0.0, 1.0])
... ]
>>> data = sc.parallelize(multi_class_data)
>>> mcm = LogisticRegressionWithLBFGS.train(data, iterations=10, numClasses=3)

=================================

这里会报这个错
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/usr/lib/spark-current/python/pyspark/mllib/classification.py", line 398, in train
    return _regression_train_wrapper(train, LogisticRegressionModel, data, initialWeights)
  File "/usr/lib/spark-current/python/pyspark/mllib/regression.py", line 216, in _regression_train_wrapper
    return modelClass(weights, intercept, numFeatures, numClasses)
  File "/usr/lib/spark-current/python/pyspark/mllib/classification.py", line 176, in __init__
    self._dataWithBiasSize)
TypeError: 'float' object cannot be interpreted as an integer
二维码

扫码加我 拉你入群

请注明:姓名-公司-职位

以便审核进群资格,未注明则拒绝

2019-1-22 17:26:15
您好,如果您的求助没有解决,请到项目交易发布需求,会有更快更专业的用户帮助您 https://bbs.pinggu.org/prj/
二维码

扫码加我 拉你入群

请注明:姓名-公司-职位

以便审核进群资格,未注明则拒绝

相关推荐
栏目导航
热门文章
推荐文章

说点什么

分享

扫码加好友,拉您进群
各岗位、行业、专业交流群