Следующий код генерирует предупреждение в API-интерфейсе python tenorflow r1.12:
#!/usr/bin/python3
import tensorflow as tf
M = tf.keras.models.Sequential();
M.add(tf.keras.layers.Dense(2));
Полный текст предупреждения таков:
WARNING: Logging before flag parsing goes to stderr.
W0213 15:50:07.239809 140701996246848 deprecation.py:506] From /home/matias/anaconda3/lib/python3.6/site-packages/tensorflow/python/ops/init_ops.py:1253: calling VarianceScaling.__init__ (from tensorflow.python.ops.init_ops) with dtype is deprecated and will be removed in a future version.
Instructions for updating:
Call initializer instance with the dtype argument instead of passing it to the constructor
Я пробовал разные подходы, такие как инициализация ивызов инициализатора ядра перед добавлением слоя Dense и передача его конструктору Dense, но, похоже, это ничего не меняет.Это предупреждение неизбежно?Мне достаточно ответа «да».