DeepQA icon indicating copy to clipboard operation
DeepQA copied to clipboard

Input to reshape is a tensor with 1 values, but the requested shape has 0

Open ycui123 opened this issue 7 years ago • 3 comments

Hi everyone,

I got the problem:Input to reshape is a tensor with 1 values, but the requested shape has 0 while I was trainning the model. I run python train/train.py and the mistake happened in the middle of trainning. Sometimes it happens in iter 30+, sometimes it happens in iter 300+. I don't know how to fix it.

Does anyone have the same problem with me?

ycui123 avatar Jul 19 '17 19:07 ycui123

this problem usually occurs when I've been running multiple models / parameters.

make sure your ./data/samples and ./save are clean

I even get so paranoid as to move things into clean folders with the --modelTag NAMEMODEL

EMCP avatar Aug 11 '17 18:08 EMCP

Hi, i've looked into this bug. Actually bad string is coco.py: gt_boxes = tf.decode_raw(features['label/gt_boxes'], tf.float32) The problem is if we call tf.decode_raw from empty string('') it returns tensor [0] i.e. tf.decode_raw('', tf.float32).eval() == array([ 0.], dtype=float32) I think we should handle empty in special way string here. I'll try to make a fix

update: sorry I was answered to a bug in different project https://github.com/CharlesShang/FastMaskRCNN/issues/113 Haven't noticed after googling bug text

anatolix avatar Oct 19 '17 14:10 anatolix

this is dup of #113, I made fix look for it in pull requests.

anatolix avatar Oct 19 '17 15:10 anatolix