摘要: 各环境安装 我使用的是python3环境 安装scikit-learn:pip3 install scikit-learn 安装numpy:pip3 install numpy 安装scipy:pip3 install scipy 安装matplotlib:pip3 install matplotl 阅读全文
posted @ 2019-04-14 17:06 RomanticChopin 阅读(184) 评论(0) 推荐(0) 编辑
摘要: 该函数可以把yes和no转化为0和1,或是把incident和normal转化为0和1。 标签都是非数字化的,所以我们需要对其进行转换。 from sklearn import preprocessing labelList=['yes', 'no', 'no', 'yes']# 将标签矩阵二值化 阅读全文
posted @ 2019-04-14 15:57 RomanticChopin 阅读(1225) 评论(0) 推荐(1) 编辑
摘要: DictVectorizer的处理对象是符号化(非数字化)的但是具有一定结构的特征数据,如字典等,将符号转成数字0/1表示。 #使用DictVectorizer对使用字典存储的数据进行特征抽取和向量化 #定义一组字典列表,用来表示多个数据样本(每个字典代表一个数据样本) measurements = 阅读全文
posted @ 2019-04-14 15:12 RomanticChopin 阅读(853) 评论(0) 推荐(0) 编辑
摘要: python中有个csv包(build-in),该包有个reader,按行读取csv文件中的数据 reader.next()作用:打印csv文件中的第一行标题header python3中的用法: allElectronicsData = open(r'C:\Users\Lenovo\Desktop 阅读全文
posted @ 2019-04-14 14:07 RomanticChopin 阅读(1375) 评论(0) 推荐(0) 编辑
-->
Live2D