超参数优化随机搜索的改进
Improvements of Random Search for Hyperparameter Optimization
随机搜索是机器学习中超参数优化的一种可能性。我应用随机搜索来搜索具有 RBF 核的 SVM 分类器的最佳超参数。除了连续的 Cost 和 gamma 参数之外,我还有一个离散参数以及对某些参数的等式约束。
现在,我想进一步开发随机搜索,例如通过自适应随机搜索。这意味着例如调整搜索方向或搜索范围。
有人知道如何做到这一点,或者可以参考一些现有的相关工作吗?也欢迎改进随机搜索的其他想法。
你为什么要重新发明轮子?超参数优化是一个很好研究的主题,至少有一些最先进的方法可以简单地解决 SVM 的问题,包括:
- 贝叶斯优化(通常通过使用高斯过程对模型质量进行建模),例如 bayesopt http://rmcantin.bitbucket.org/html/
- hyperopt http://hyperopt.github.io/hyperopt/
中包含(特别是)parzen 估计量树(有时更适合离散的、复杂的超参数空间)
改进随机搜索程序,可参考Hyperband。
Hyperband 是加州大学伯克利分校 AMP 实验室提出的一种方法,旨在提高随机搜索等调优方法的效率。
我想补充一点,Bayesian optimization 是 自适应随机搜索 的完美示例,所以看起来它正是您想要应用的内容。
贝叶斯优化的思想是使用Gaussian Processes (GP), select the best next point according to the current model and update the model after seeing the actual outcome. So, effectively, Bayesian optimization starts like a random search, gradually builds a picture of what the function looks like and shifts its focus to the most promising areas (note that "promising" can be defined differently by different particular methods - PI, EI, UCB, etc). There are further techniques to help it to find a right balance between exploration and exploitation, for example portfolio strategy对目标函数进行建模。如果这就是您所说的 自适应,那么贝叶斯优化就是您的选择。
如果您想在没有外部库的情况下扩展您的代码,这完全有可能,因为贝叶斯优化并不难实现。你可以看看我在my research, for example here中使用的示例代码是大部分与GP相关的代码。
随机搜索是机器学习中超参数优化的一种可能性。我应用随机搜索来搜索具有 RBF 核的 SVM 分类器的最佳超参数。除了连续的 Cost 和 gamma 参数之外,我还有一个离散参数以及对某些参数的等式约束。
现在,我想进一步开发随机搜索,例如通过自适应随机搜索。这意味着例如调整搜索方向或搜索范围。
有人知道如何做到这一点,或者可以参考一些现有的相关工作吗?也欢迎改进随机搜索的其他想法。
你为什么要重新发明轮子?超参数优化是一个很好研究的主题,至少有一些最先进的方法可以简单地解决 SVM 的问题,包括:
- 贝叶斯优化(通常通过使用高斯过程对模型质量进行建模),例如 bayesopt http://rmcantin.bitbucket.org/html/
- hyperopt http://hyperopt.github.io/hyperopt/ 中包含(特别是)parzen 估计量树(有时更适合离散的、复杂的超参数空间)
改进随机搜索程序,可参考Hyperband。
Hyperband 是加州大学伯克利分校 AMP 实验室提出的一种方法,旨在提高随机搜索等调优方法的效率。
我想补充一点,Bayesian optimization 是 自适应随机搜索 的完美示例,所以看起来它正是您想要应用的内容。
贝叶斯优化的思想是使用Gaussian Processes (GP), select the best next point according to the current model and update the model after seeing the actual outcome. So, effectively, Bayesian optimization starts like a random search, gradually builds a picture of what the function looks like and shifts its focus to the most promising areas (note that "promising" can be defined differently by different particular methods - PI, EI, UCB, etc). There are further techniques to help it to find a right balance between exploration and exploitation, for example portfolio strategy对目标函数进行建模。如果这就是您所说的 自适应,那么贝叶斯优化就是您的选择。
如果您想在没有外部库的情况下扩展您的代码,这完全有可能,因为贝叶斯优化并不难实现。你可以看看我在my research, for example here中使用的示例代码是大部分与GP相关的代码。