You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When I'm trying to run pokeGAN.py, line 225 throws the following error: tensorflow.python.framework.errors_impl.OutOfRangeError: RandomShuffleQueue '_0_shuffle_batch/random_shuffle_queue' is closed and has insufficient elements (requested 64, current size 0)
[[Node: shuffle_batch = QueueDequeueManyV2[component_types=[DT_FLOAT], timeout_ms=-1, _device="/job:localhost/replica:0/task:0/cpu:0"](shuffle_batch/random_shuffle_queue, shuffle_batch/n)]]
While this error is throwing during the train_image = sess.run(image_batch) instruction, it seems to be related to line 58, where is defined a shuffle batch instruction:
@ayrtondenner I may be a little late on this but i found by setting a guard on the image import fixed this problem for me. Initially i thought it had something to do with the number of samples in the dataset but that wasn't the problem
Here is what i did, i inserted if each.endswith(".png"): to make make sure only png images were being imported as sometimes there can be a hidden .ini file
def process_data():
print('importing data...')
images = []
#import every file with a png extension
for each in os.listdir(TRAINING_DIR):
if each.endswith(".png"):
images.append(os.path.join(TRAINING_DIR,each))
# print images
all_images = tf.convert_to_tensor(images, dtype = tf.string)
When I'm trying to run
pokeGAN.py
, line 225 throws the following error: tensorflow.python.framework.errors_impl.OutOfRangeError: RandomShuffleQueue '_0_shuffle_batch/random_shuffle_queue' is closed and has insufficient elements (requested 64, current size 0)[[Node: shuffle_batch = QueueDequeueManyV2[component_types=[DT_FLOAT], timeout_ms=-1, _device="/job:localhost/replica:0/task:0/cpu:0"](shuffle_batch/random_shuffle_queue, shuffle_batch/n)]]
While this error is throwing during the
train_image = sess.run(image_batch)
instruction, it seems to be related to line 58, where is defined a shuffle batch instruction:I couldn't find anyone else on the internet with the same mistake, but it happens when I try to run this code without any changes.
The text was updated successfully, but these errors were encountered: