sayakpaul / ConvNeXt-TF

Includes PyTorch -> Keras model porting code for ConvNeXt family of models with fine-tuning and inference notebooks.

Home Page:https://tfhub.dev/sayakpaul/collections/convnext/1

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

I got error when I used your model file "convnext_tf.py" and use trained with callback for model save. Is there model prior save model weight file or error from my side? Need your help and suggestions. Thank you.

AIFahim opened this issue · comments

I need to see the full code to know why this error is coming.

Code Link
Callback Link

Thanks for your response please check. Thanks.

Please provide a Colab Notebook link that would allow me to reproduce the issue.

Colab Notebook Link
[Error happen after one epoch end when try to save model weight file]
In the output, you will find output exists. You can run all to reproduce the same error. Please look at the following cell for error:

2022-03-08_14-43

It's probably best to open this issue in the Keras repository. There's a similar issue here: https://stackoverflow.com/questions/70739244/valueerror-unable-to-create-dataset-name-already-exists-while-saving-tensorfl.

Thanks but I tried with other models but didn't get this error.

I see. Since the model definition itself is a bit contrived it's currently not possible for me to dig deeper. The easiest fix I can suggest is serializing the model as a SavedModel resource rather h5 file.

Thanks sayak for your response will check this hope to solve it anyhow. Thanks for your contribution.

The error is caused by missing get_config() and from_config() methods in Class StochasticDepth.
See Tensorflow Guide.