Skip to content

Running error #2

@Ni-Chen

Description

@Ni-Chen

Hi,

I use Anaconda 3 and Python 3.6 to run your code, but always got the bellow error message, do you have any idea to solve this problem? I didn't modified your code except the image_size in the main.py file.

Thanks a lot.

FusionNet Loading
Complete!!
Traceback (most recent call last):
File "D:\Users\NeysaChen\Anaconda3\lib\site-packages\tensorflow\python\framework\tensor_shape.py", line 558, in merge_with
new_dims.append(dim.merge_with(other[i]))
File "D:\Users\NeysaChen\Anaconda3\lib\site-packages\tensorflow\python\framework\tensor_shape.py", line 133, in merge_with
self.assert_is_compatible_with(other)
File "D:\Users\NeysaChen\Anaconda3\lib\site-packages\tensorflow\python\framework\tensor_shape.py", line 106, in assert_is_compatible_with
other))
ValueError: Dimensions 38 and 37 are not compatible

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "C:\Users\NeysaChen\Desktop\FusionNet\main.py", line 39, in
tf.app.run()
File "D:\Users\NeysaChen\Anaconda3\lib\site-packages\tensorflow\python\platform\app.py", line 48, in run
_sys.exit(main(_sys.argv[:1] + flags_passthrough))
File "C:\Users\NeysaChen\Desktop\FusionNet\main.py", line 31, in main
train_with_cpu(FLAGS)
File "C:\Users\NeysaChen\Desktop\FusionNet\train.py", line 41, in train_with_cpu
grads_and_vars = optimizer.compute_gradients(loss, var_list=var_list)
File "D:\Users\NeysaChen\Anaconda3\lib\site-packages\tensorflow\python\training\optimizer.py", line 386, in compute_gradients
colocate_gradients_with_ops=colocate_gradients_with_ops)
File "D:\Users\NeysaChen\Anaconda3\lib\site-packages\tensorflow\python\ops\gradients_impl.py", line 560, in gradients
in_grad.set_shape(t_in.get_shape())
File "D:\Users\NeysaChen\Anaconda3\lib\site-packages\tensorflow\python\framework\ops.py", line 443, in set_shape
self._shape = self._shape.merge_with(shape)
File "D:\Users\NeysaChen\Anaconda3\lib\site-packages\tensorflow\python\framework\tensor_shape.py", line 561, in merge_with
raise ValueError("Shapes %s and %s are not compatible" % (self, other))
ValueError: Shapes (1, 38, 38, 1024) and (1, 37, 37, 1024) are not compatible
[Finished in 34.4s with exit code 1]

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions