10 2018 档案

摘要:scipy.sparse.hstack(blocks, format=None, dtype=None)[source]¶ Stack sparse matrices horizontally (column wise) sequence of sparse matrices with compat 阅读全文
posted @ 2018-10-11 16:58 在下小白 阅读(425) 评论(0) 推荐(0)
摘要:for feature in short_cate_feature: enc.fit(data[feature].values.reshape(-1, 1)) base_train_csr = sparse.hstack((base_train_csr, enc.transform(train_x[ 阅读全文
posted @ 2018-10-10 17:30 在下小白 阅读(641) 评论(0) 推荐(0)
摘要:今天在计算机矩阵相关性,准备删除相关性高的列中,出现了这样的问题: During handling of the above exception, another exception occurred: 问题原因又说python版本过高,我确实是3.7有点高,还有其他的。 不清楚,直接import 阅读全文
posted @ 2018-10-08 21:43 在下小白 阅读(27699) 评论(1) 推荐(0)
摘要:def get_feature(df,all_data,cols,vec_col): enc = OneHotEncoder() df_x=np.int64(df[cols]) cv=CountVectorizer() for feature in vec_col: cv.fit(all_data[ 阅读全文
posted @ 2018-10-07 01:27 在下小白 阅读(3012) 评论(0) 推荐(0)