hellochick / ICNet-tensorflow

TensorFlow-based implementation of "ICNet for Real-Time Semantic Segmentation on High-Resolution Images".
405 stars 153 forks source link

ValueError: Shape must be rank 4 but is rank 3 for 'data_sub2' (op: 'ResizeBilinear') with input shapes: [720,720,3], [2]. #110

Closed helingjiao2025 closed 5 years ago

helingjiao2025 commented 5 years ago

Hi hellochick, when I was training on ADE20K, I got this problem: ValueError: Shape must be rank 4 but is rank 3 for 'data_sub2' (op: 'ResizeBilinear') with input shapes: [720,720,3], [2]. curiously, I can evaluate and inference this. What happend? thank u

helingjiao2025 commented 5 years ago

it's my fault.

ym641925331 commented 4 years ago

How can solve it

helingjiao2025 commented 4 years ago

This problem has happened for a long time. I have forgotten the specific reason. Maybe it's because of the TensorFlow version.

maybe you can try this:

in /utils/ image_reader.py

       #dataset = dataset.batch(cfg.BATCH_SIZE, drop_remainder=True)
       dataset = dataset.batch(cfg.BATCH_SIZE)

hope it can help you

在2019-11-28 11:58:53,ym641925331notifications@github.com写道:

How can solve it

— You are receiving this because you modified the open/close state. Reply to this email directly, view it on GitHub, or unsubscribe.