【发布时间】:2018-08-27 07:16:52
【问题描述】:
我不知道随机梯度下降算法的详细工作原理,目前我不需要知道这一点。我所知道的是,它通过计算梯度并进入局部最小值的方向来最小化损失函数。但是我在使用 Keras 的项目中使用随机梯度下降作为优化器,我不知道这个优化器的参数是什么意思。显然,这些参数在文档中有简短的描述,但不够具体,我仍然不明白它们的含义。
那么你能解释一下这 4 个参数吗:
lr: float >= 0. Learning rate.
momentum: float >= 0. Parameter that accelerates SGD in the relevant direction and dampens oscillations.
decay: float >= 0. Learning rate decay over each update.
nesterov: boolean. Whether to apply Nesterov momentum.
我怎么知道我应该如何设置它们?
【问题讨论】:
-
你错了我现在不需要知道这个。至少阅读
BOTTOU, Léon. Stochastic gradient descent tricks. In: Neural networks: Tricks of the trade. Springer, Berlin, Heidelberg, 2012. S. 421-436.link -
如果你想以实用的方式学习这个主题,我可以建议你由 Ian Goodfellow 和 Yoshua Bengio 撰写的“深度学习”
标签: python parameters deep-learning keras gradient-descent