Skip to content
This repository has been archived by the owner on Sep 16, 2024. It is now read-only.

Running evaluation on images of different size #184

Open
burhanbvk opened this issue Jun 5, 2018 · 1 comment
Open

Running evaluation on images of different size #184

burhanbvk opened this issue Jun 5, 2018 · 1 comment

Comments

@burhanbvk
Copy link

burhanbvk commented Jun 5, 2018

Hello,

I am trying to create a service that evaluates images. To improve performance I am trying to use the same network on all images. I use inference.py as a starting point and I moved the net variable to the global scope using the following code:

img_ph = tf.placeholder(tf.float32, shape = [None, None, None, 3])
net = DeepLabResNetModel({'data': img_ph}, is_training=False, num_classes=NUM_CLASSES)

But I get the following error when I evaluate an image:

File "C:\Users\Administrator\AppData\Local\Programs\Python\Python36\lib\site-packages\tensorflow\python\framework\ops.py", line 5573, in _assert_same_graph original_item)) ValueError: Tensor("strided_slice:0", shape=(2,), dtype=int32) must be from the same graph as Tensor("fc_out/Conv2D:0", shape=(?, ?, ?, 27), dtype=float32).

Thanks for any pointers.

@DrSleep
Copy link
Owner

DrSleep commented Jul 27, 2018

I am not sure where this is coming from

Tensor("fc_out/Conv2D:0", shape=(?, ?, ?, 27), dtype=float32)

Did you modify the network? If so, it is better if you provide more description; otherwise, I might not be able to help at all

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

No branches or pull requests

2 participants