Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

HELP: InvalidArgumentError: Graph execution error #4

Open
TomMoxom opened this issue Feb 11, 2022 · 2 comments
Open

HELP: InvalidArgumentError: Graph execution error #4

TomMoxom opened this issue Feb 11, 2022 · 2 comments

Comments

@TomMoxom
Copy link

Hi, I'm trying to implement your code from your:

Deep-learning-with-Python/Notebooks/Keras_flow_from_directory.ipynb

repo to a different dataset but run into the following error "InvalidArgumentError: Graph execution error" with a load of text afterwards; when trying to fit the model. I've tried a number of things but cant seem to fix it.

The only change I've made is the dataset, which is working and reading fine up to this point. And i've commented out the target_size in the train_generator.

Thanks, Tom

This is the top part of the error:

InvalidArgumentError Traceback (most recent call last)
~\AppData\Local\Temp/ipykernel_264/102295305.py in
1 n_epochs = 30
2
----> 3 history = model.fit(
4 train_generator,
5 steps_per_epoch=total_sample/batch_size,

~\anaconda3\envs\BigData\lib\site-packages\keras\utils\traceback_utils.py in error_handler(*args, **kwargs)
65 except Exception as e: # pylint: disable=broad-except
66 filtered_tb = _process_traceback_frames(e.traceback)
---> 67 raise e.with_traceback(filtered_tb) from None
68 finally:
69 del filtered_tb

~\anaconda3\envs\BigData\lib\site-packages\tensorflow\python\eager\execute.py in quick_execute(op_name, num_outputs, inputs, attrs, ctx, name)
52 try:
53 ctx.ensure_initialized()
---> 54 tensors = pywrap_tfe.TFE_Py_Execute(ctx._handle, device_name, op_name,
55 inputs, attrs, num_outputs)
56 except core._NotOkStatusException as e:

InvalidArgumentError: Graph execution error:

Detected at node 'categorical_crossentropy/softmax_cross_entropy_with_logits' defined at (most recent call last): ...

@rafayqayyum
Copy link

What dataset are you using? Is it binary or categorical?

@TomMoxom
Copy link
Author

TomMoxom commented Aug 13, 2022 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants