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

python validate.py problem #35

Closed
gydlcc opened this issue Aug 2, 2018 · 4 comments
Closed

python validate.py problem #35

gydlcc opened this issue Aug 2, 2018 · 4 comments

Comments

@gydlcc
Copy link

gydlcc commented Aug 2, 2018

hi there!
when i type python validate.py and i type 1.jpg
i got follow error

2018-08-02 15-42-18

how could i solve this,
thanks

@weinman
Copy link
Owner

weinman commented Aug 2, 2018

The validate script is tied to the MJsynth data, which is only 31 pixels high. Thus the raw data's placeholder is (31,?,1) and the tensor gets expanded to 32 pixels high in the _preprocess_image function.

If you delete line 65

image = tf.concat([first_row, image], 0)

and change line 74 in _get_input to to create a 32-pixel high value instead,

image = tf.placeholder(tf.uint8, shape=[32, None, 1])

it should work for your data, which seems to be 32 pixels high already.

@gydlcc
Copy link
Author

gydlcc commented Aug 3, 2018

oh oh thanks pretty much ! !
so if i use the data trained the model, and if i use another data which has different size from the train data to validate the trained model, is that possible?

@weinman
Copy link
Owner

weinman commented Aug 3, 2018

The width is variable, but the height is ostensibly fixed, unless perhaps you introduce a new pooling operation. See #33 for more.

@gydlcc
Copy link
Author

gydlcc commented Aug 4, 2018

alright, thank you very much ! ! !

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