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

ValueError: Operands could not be broadcast together with shapes (21, 34, 4) (21, 34, 3) #60

Open
JadBatmobile opened this issue Apr 8, 2019 · 2 comments

Comments

@JadBatmobile
Copy link

Running the demo as instructed, giving this output

Traceback (most recent call last): File "run_demo.py", line 48, in <module> main() File "run_demo.py", line 38, in main model = get_crfrnn_model_def() File "./src/crfrnn_model.py", line 91, in get_crfrnn_model_def score_fused = Add()([score2, score_pool4c]) File "/home/hallab/.local/lib/python3.5/site-packages/keras/engine/base_layer.py", line 431, in __call__ self.build(unpack_singleton(input_shapes)) File "/home/hallab/.local/lib/python3.5/site-packages/keras/layers/merge.py", line 91, in build shape) File "/home/hallab/.local/lib/python3.5/site-packages/keras/layers/merge.py", line 61, in _compute_elemwise_op_output_shape str(shape1) + ' ' + str(shape2)) ValueError: Operands could not be broadcast together with shapes (21, 34, 4) (21, 34, 3)

@JadBatmobile
Copy link
Author

JadBatmobile commented Apr 8, 2019

It seems the line 91:

score_fused = Add()([score2, score_pool4c])

@sadeepj
Copy link
Owner

sadeepj commented Jul 26, 2019

@JadBatmobile was this resolved? It looks like the problem was caused by using an image size other than (500 x 500).

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