基于过采样的聚类。
cluster-over-sampling的Python项目详细描述
群集过采样
基于过采样的聚类通用接口的实现 算法[1],[2]。它与scikit-learn和 imbalanced-learn。
文件
安装文档、API文档和示例可以在 documentation。
依赖性
在python 3.6+下测试了集群过度采样。依赖关系 如下所示:
- 纽比(>;=1.1)
- 科学套件学习(>;=0.21)
- 不平衡学习(>;=0.4.3)
此外,要运行示例,需要matplotlib(>;=2.0.0)和 熊猫(>;=0.22)。
安装
pypi的存储库中当前提供了集群过度采样 您可以通过pip安装它
pip install -U cluster-over-sampling
该软件包也在anaconda云平台发布:
conda install -c algowit cluster-over-sampling
如果愿意,可以克隆它并运行setup.py文件。使用以下命令 从github获取副本并安装所有依赖项的命令:
git clone https://github.com/AlgoWit/cluster-over-sampling.git cd cluster-over-sampling pip install .
或者使用pip和github安装:
pip install -U git+https://github.com/AlgoWit/cluster-over-sampling.git
测试
安装后,您可以使用pytest运行测试套件:
make test
关于
如果你在科学出版物中使用过多抽样,我们会 感谢引用下列任何一篇论文:
@article{Douzas2017, doi = {10.1016/j.eswa.2017.03.073}, url = {https://doi.org/10.1016/j.eswa.2017.03.073}, year = {2017}, month = oct, publisher = {Elsevier {BV}}, volume = {82}, pages = {40--52}, author = {Georgios Douzas and Fernando Bacao}, title = {Self-Organizing Map Oversampling ({SOMO}) for imbalanced data set learning}, journal = {Expert Systems with Applications} } @article{Douzas2018, doi = {10.1016/j.ins.2018.06.056}, url = {https://doi.org/10.1016/j.ins.2018.06.056}, year = {2018}, month = oct, publisher = {Elsevier {BV}}, volume = {465}, pages = {1--20}, author = {Georgios Douzas and Fernando Bacao and Felix Last}, title = {Improving imbalanced learning through a heuristic oversampling method based on k-means and {SMOTE}}, journal = {Information Sciences} }
从班级不平衡的数据中学习仍然是一个普遍而具有挑战性的问题。 标准分类算法中的监督学习问题 设计用于处理平衡的类分布。而不同的策略 存在着解决这个问题的方法,产生人工数据来实现 均衡的类分布比修改 分类算法。smote算法[3],以及任何其他 基于烟雾机理的过采样方法,生成合成样品 连接少数类实例的直线段。仅删除地址 阶级之间不平衡的问题。另一方面,通过将 输入空间和对每个结果聚类应用任何过采样算法 在适当的重采样率下,类内不平衡问题可以是 演说。
参考文献:
[1] | G. Douzas, F. Bacao, “Self-Organizing Map Oversampling (SOMO) for imbalanced data set learning”, Expert Systems with Applications, vol. 82, pp. 40-52, 2017. |
[2] | G. Douzas, F. Bacao, F. Last, “Improving imbalanced learning through a heuristic oversampling method based on k-means and SMOTE”, Information Sciences, vol. 465, pp. 1-20, 2018. |
[3] | N. V. Chawla, K. W. Bowyer, L. O. Hall, W. P. Kegelmeyer, “SMOTE: synthetic minority over-sampling technique”, Journal of Artificial Intelligence Research, vol. 16, pp. 321-357, 2002. |