tf.nn.dropout使用时输出相同的值

时间:2018-09-11 10:17:32

标签: tensorflow dropout

当我不在模型中对猫和狗进行分类时,预测值保持正常,即所有图像的值都不相同。

但是,当我将tf.nn.dropoutkeep_prob = 0.8一起用于我的模型时,为了规范化模型和提高准确性,建议使用tflearn,它会不断预测相同的值。我该如何解决?那里的每个教程或代码都使用array([[ 2.20128131e+00, 1.78127408e+00], [ 2.20128131e+00, 1.78127408e+00]` [ 2.20128131e+00, 1.78127408e+00], [ 2.20128131e+00, 1.78127408e+00], [ 2.20128131e+00, 1.78127408e+00], [ 2.20128131e+00, 1.78127408e+00], [ 2.20128131e+00, 1.78127408e+00], [ 2.20128131e+00, 1.78127408e+00], [ 2.20128131e+00, 1.78127408e+00], [ 2.20128131e+00, 1.78127408e+00], [ 2.20128131e+00, 1.78127408e+00], [ 2.20128131e+00, 1.78127408e+00], [ 2.20128131e+00, 1.78127408e+00], [ 2.20128131e+00, 1.78127408e+00], [ 2.20128131e+00, 1.78127408e+00], [ 2.20128131e+00, 1.78127408e+00], [ 2.20128131e+00, 1.78127408e+00], [ 2.20128131e+00, 1.78127408e+00], [ 2.20128131e+00, 1.78127408e+00], [ 2.20128131e+00, 1.78127408e+00], [ 2.20128131e+00, 1.78127408e+00], [ 2.20128131e+00, 1.78127408e+00], [ 2.20128131e+00, 1.78127408e+00], [ 2.20128131e+00, 1.78127408e+00], [ 2.20128131e+00, 1.78127408e+00], [ 2.20128131e+00, 1.78127408e+00], [ 2.20128131e+00, 1.78127408e+00], [ 2.20128131e+00, 1.78127408e+00], [ 2.20128131e+00, 1.78127408e+00], [ 2.20128131e+00, 1.78127408e+00], [ 2.20128131e+00, 1.78127408e+00], [ 2.20128131e+00, 1.78127408e+00], [ 2.20128131e+00, 1.78127408e+00], [ 2.20128131e+00, 1.78127408e+00], [ 2.20128131e+00, 1.78127408e+00], [ 2.20128131e+00, 1.78127408e+00], [ 2.20128131e+00, 1.78127408e+00], ,但这不会发生。

{{1}}

0 个答案:

没有答案