hellochick / PSPNet-tensorflow

TensorFlow-based implementation of "Pyramid Scene Parsing Network".
326 stars 123 forks source link

Issue freezing graph #35

Open mdlockyer opened 6 years ago

mdlockyer commented 6 years ago

I've been testing out this implementation and it's quite good! I do have a slight issue though.

I'm trying to freeze the graph into a pb file, however I cant seem to ascertain the proper output node name. From my understanding, the output should be conv6, however when I try to convert the vars to constants the output name conv6 isn't found in the graph. Any ideas?

kmonachopoulos commented 6 years ago

Hello @MichaelDylan77,

In the inference script you will see that the output of the network before passing the information to the decoder is :

raw_output_up = tf.argmax(raw_output_up, axis=3)

Converting the ckpt to tf.events and visualizing it to tensorboard you will see that the output of the network is : ArgMax layer without scope name.

screenshot from 2018-09-17 11-55-50

Don't forget to call the decoder : pred = decode_labels(raw_output_up, img_shape, num_classes) after inference using the .pb file.