DenseNet icon indicating copy to clipboard operation
DenseNet copied to clipboard

Unable to convert to frozen graph or checkpoint

Open venkat-kittu opened this issue 4 years ago • 0 comments

I am trying to convert the densenet161 model to frozen graph(pb) or checkpoint, but after loading the model and while saving the checkpoint file I am getting the below error. Thanks in advance

tensorflow.python.framework.errors_impl.FailedPreconditionError: Attempting to use uninitialized value batch_normalization_1/beta [[node save/SaveV2 (defined at /usr/local/lib/python3.6/dist-packages/tensorflow_core/python/framework/ops.py:1748) ]]

Below is the code for your reference

import densenet import tensorflow as tf model = densenet.DenseNetImageNet161(input_shape=(224,224,3)) saver = tf.train.Saver() sess = tf.keras.backend.get_session() save_path = saver.save(sess, "./checkpoint/model")

getting issue in the last line of code.

venkat-kittu avatar Oct 08 '21 09:10 venkat-kittu