Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

here I met some questions , I hope to get your help #3

Open
alexliyang opened this issue Sep 4, 2018 · 1 comment
Open

here I met some questions , I hope to get your help #3

alexliyang opened this issue Sep 4, 2018 · 1 comment

Comments

@alexliyang
Copy link

hi, thank you for your code.

when I use these codes, I met some problems:

  1. when I test one image , although I expend_dims the image, I can not get the right predict, but ,when test a batch images , the predict is right

  2. when I try to save ckpt to pb file, here reuse should be set True, but when set True, there will be some problems , when set False, _classification_layer's flatten0 = tf.reshape(global_avgpool, [shape[0], -1]) maybe wrong

what can I do for it?

@nnUyi
Copy link
Owner

nnUyi commented Dec 17, 2018

for Q1:
self.input_train = tf.placeholder(tf.float32, [self.batchsize, self.input_height, self.input_width, self.input_channel], name='input_train')
self.input_test = tf.placeholder(tf.float32, [self.batchsize, self.input_height, self.input_width, self.input_channel], name='input_test')

Once you want to test only one image, you should rewrite this code in build_mode function of peleenet.py to be:
self.input_train = tf.placeholder(tf.float32, [None, self.input_height, self.input_width, self.input_channel], name='input_train')
self.input_test = tf.placeholder(tf.float32, [None, self.input_height, self.input_width, self.input_channel], name='input_test')

This requires no constraint in batchsize of training or testing phase.

for Q2:
Could you describe your problem in detail? I confuse about that. Thank you.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants