I have an error at model fit generator in image captioning task

30 Views Asked by At

I am trying to apply image captioning code. I have images with 3 captions for each, so I put my training data. When I run the program, I am facing an error at model.fit_generator(). Do the brackets and single quotations appear in the model summary incorrectly? enter image description here

**Here is the error: **InvalidArgumentError Traceback (most recent call last) in <cell line: 8>() 8 for i in range(epochs): 9 generator = data_generator(train_descriptions, train_features, tokenizer, max_length) ---> 10 model.fit_generator(generator, epochs=1, steps_per_epoch=steps, verbose=1) 11 model.save('/content/drive/MyDrive/Laren dataset - Copy/model_' + str(i) + '.h5')

2 frames /usr/local/lib/python3.10/dist-packages/tensorflow/python/eager/execute.py in quick_execute(op_name, num_outputs, inputs, attrs, ctx, name) 51 try: 52 ctx.ensure_initialized() ---> 53 tensors = pywrap_tfe.TFE_Py_Execute(ctx._handle, device_name, op_name, 54 inputs, attrs, num_outputs) 55 except core._NotOkStatusException as e:

InvalidArgumentError: Graph execution error:

0

There are 0 best solutions below