tensorflow中keep_prob的修改方法
warning:
WARNING:tensorflow:From D:\software\pycharm_location\venv\Dehaze-GAN-master\Dehaze-GAN-master\legacy\utils.py:67: calling dropout (from tensorflow.python.ops.nn_ops) with keep_prob is deprecated and will be removed in a future version.
Instructions for updating:
Please use `rate` instead of `keep_prob`. Rate should be set to `rate = 1 - keep_prob`.
源码:
h_fc1_drop = tf.nn.dropout(h_fc1,keep_prob)
修改为:
h_fc1_drop = tf.nn.dropout(h_fc1, rate = 1-keep_prob)