Spark Streaming通过直连的方式消费Kafka中的数据 |
您所在的位置:网站首页 › sparkstreaming读取kafka代码 › Spark Streaming通过直连的方式消费Kafka中的数据 |
Spark GraphX学习(一)Connected Components算法
岸芷汀兰whu: 这。。。是API使用还差不多 Python实现分类器性能度量(混淆矩阵,正确率,准确率,召回率,ROC,AUC)Tiger_pop: 我感觉这里有点问题,您可以说说吗?[code=python] [/code][code=python] def roc_coord(self): """ :return: roc坐标 """ xy_arr = [] tp, fp = 0., 0. neg = self.TN + self.FP pos = self.TP + self.FN for i in range(len(self.db)): tp += self.db[i][0] # 看不懂了. 这里应该替换为一个判断,在标签为1,且预测为1时,tp+ = self.db[i][0] fp += 1 - self.db[i][0] # 看不懂了. 这里应该替换为一个判断,在标签为1,且预测为1时,fp+ = 1 - self.db[i][0] [/code] Python实现分类器性能度量(混淆矩阵,正确率,准确率,召回率,ROC,AUC)Tiger_pop: 我感觉有个地方有问题,不知道对不对: def roc_coord(self): """ :return: roc坐标 """ xy_arr = [] tp, fp = 0., 0. neg = self.TN + self.FP pos = self.TP + self.FN for i in range(len(self.db)): tp += self.db[i][0] # 看不懂了. 这里应该替换为一个判断,在标签为1,且预测为1时,tp+ = self.db[i][0] fp += 1 - self.db[i][0] # 看不懂了. 这里应该替换为一个判断,在标签为1,且预测为1时,fp+ = 1 - self.db[i][0] Python实现分类器性能度量(混淆矩阵,正确率,准确率,召回率,ROC,AUC)trophyy: 这个混淆矩阵怎么画的 TensorFlow用训练好的CNN模型检测小飞鱼_bigdata 回复 Cabbage: 看这里持久化模型那段代码https://blog.csdn.net/zryowen123/article/details/79889540 |
今日新闻 |
推荐新闻 |
CopyRight 2018-2019 办公设备维修网 版权所有 豫ICP备15022753号-3 |