scikit-learn:6. Strategies to scale computationally: bigger data
2015-07-27 09:12
585 查看
参考:http://scikit-learn.org/stable/modules/scaling_strategies.html
对于examples、features(或者两者)数量很大的情况,挑战传统的方法要解决两个问题:内存和效率。办法是Out-of-core (or “external memory”) learning。有三种方法可以实现out-of-core,分别是:
1、Streaming instances(流体化实例):
简单说就是,instances是一个一个来的。具体实现不在scikit-learn文档范围。
2、Extracting features:
简单说就是利用different feature
extraction methods(翻译之后的文章:/article/1323243.html)实现大数据提取有用数据,简化内存、提高效率。不细讲。
3、Incremental
learning:
all
estimators implementing the partial_fit API
are candidates。
the
ability to learn incrementally from a mini-batch of instances (sometimes called “online learning”) is key to out-of-core learning as it guarantees that at any given time there will be only a small amount of instances in the main memory。
所有实现 partial_fit API
的estimators都可以实现增量学习,包括:
Classification
sklearn.naive_bayes.MultinomialNB
sklearn.naive_bayes.BernoulliNB
sklearn.linear_model.Perceptron
sklearn.linear_model.SGDClassifier
sklearn.linear_model.PassiveAggressiveClassifier
Regression
sklearn.linear_model.SGDRegressor
sklearn.linear_model.PassiveAggressiveRegressor
Clustering
sklearn.cluster.MiniBatchKMeans
Decomposition / feature Extraction
sklearn.decomposition.MiniBatchDictionaryLearning
sklearn.decomposition.IncrementalPCA
sklearn.cluster.MiniBatchKMeans
注意:对于分类问题,由于incremental
learner可能不知道所有的classes有哪些,所以第一次调用partial_fit时,最好人工设定参数 classes= ,指明所有类别。
4、Examples:
a
example of Out-of-core
classification of text documents. 通过例子可以更好理解上面的内容。
对于examples、features(或者两者)数量很大的情况,挑战传统的方法要解决两个问题:内存和效率。办法是Out-of-core (or “external memory”) learning。有三种方法可以实现out-of-core,分别是:
1、Streaming instances(流体化实例):
简单说就是,instances是一个一个来的。具体实现不在scikit-learn文档范围。
2、Extracting features:
简单说就是利用different feature
extraction methods(翻译之后的文章:/article/1323243.html)实现大数据提取有用数据,简化内存、提高效率。不细讲。
3、Incremental
learning:
all
estimators implementing the partial_fit API
are candidates。
the
ability to learn incrementally from a mini-batch of instances (sometimes called “online learning”) is key to out-of-core learning as it guarantees that at any given time there will be only a small amount of instances in the main memory。
所有实现 partial_fit API
的estimators都可以实现增量学习,包括:
Classification
sklearn.naive_bayes.MultinomialNB
sklearn.naive_bayes.BernoulliNB
sklearn.linear_model.Perceptron
sklearn.linear_model.SGDClassifier
sklearn.linear_model.PassiveAggressiveClassifier
Regression
sklearn.linear_model.SGDRegressor
sklearn.linear_model.PassiveAggressiveRegressor
Clustering
sklearn.cluster.MiniBatchKMeans
Decomposition / feature Extraction
sklearn.decomposition.MiniBatchDictionaryLearning
sklearn.decomposition.IncrementalPCA
sklearn.cluster.MiniBatchKMeans
注意:对于分类问题,由于incremental
learner可能不知道所有的classes有哪些,所以第一次调用partial_fit时,最好人工设定参数 classes= ,指明所有类别。
4、Examples:
a
example of Out-of-core
classification of text documents. 通过例子可以更好理解上面的内容。
相关文章推荐
- 关于外贸淡季的几点看法
- Cookie和Session的的区别
- SVN常用命令
- velocity基础
- JS 动态加载脚本的4种方法
- Ubuntu12.04以及centos jdk7 32位安装 和设置tomcat监听内网地址
- 多列布局自适应法则
- Oracle 应用和网络结构
- 05-算术运算符
- SAP HANA分布式系统及高可用性(一)
- linux中关于时间函数的线程安全
- git常用命令
- 什么时候该写函数,什么时候该写类。
- Dynamics CRM2013/2015 插件注册工具登录后无法显示assembly列表问题的解决办法
- excel 如何提取分类汇总后的数据
- Dynamics CRM2013/2015 插件注册工具登录后无法显示assembly列表问题的解决办法
- Dynamics CRM2013/2015 插件注册工具登录后无法显示assembly列表问题的解决办法
- Dynamics CRM2013/2015 插件注册工具登录后无法显示assembly列表问题的解决办法
- PRML5-神经网络(2)
- 【日常学习】【并查集+map】codevs2639 约会计划题解