tensorflow - I am training my own dataset and I got InvalidArgumentError in tf.image.decode_jpeg -


part of code:

label = input_queue[1] image_contents = tf.read_file(input_queue[0])     image = tf.image.decode_jpeg(image_contents, channels=3)     image = tf.image.resize_image_with_crop_or_pad(image, image_w, image_h) 

error:

info:tensorflow:error reported coordinator: <class 'tensorflow.python.framework.errors_impl.invalidargumenterror'>, invalid jpeg data, size 300          [[node: decodejpeg_2 = decodejpeg[acceptable_fraction=1, channels=3, dct_method="", fancy_upscaling=true, ratio=1, try_recover_truncated=false, _device="/job:localhost/replica:0/task:0/cpu:0"](readfile_3)]]    file "c:/users/mcrc/made/catdog/training.py", line 97, in <module>     run_training()    file "c:/users/mcrc/made/catdog/training.py", line 60, in run_training     capacity)    file "c:\users\mcrc\made\catdog\input_data.py", line 100, in get_batch     image = tf.image.decode_jpeg(image_contents, channels=3)    file "d:\a3\lib\site-packages\tensorflow\python\ops\gen_image_ops.py", line 345, in decode_jpeg     dct_method=dct_method, name=name) 

i using tensorflow-gpu 1.0 python3.5 in windows. help?

sounds image (or 1 of images, can't tell since depends on how input_queue constructed) not valid jpeg image (and file contents 300 bytes).


Comments