Closed cb0s closed 2 years ago
@cb0s , I was facing different error while executing the given code.Please find the gist of it here and provide complete code to reproduce the issue.Thanks!
@tilakrayal This is due to the model structure I had in my original package: I had a trainer module and a model module. The module containing the Autoencoder code was called autoencoder
. This is why it didn't work for you.
The problem is that I did in fact use a custom dataset and therefore can provide you with the loader code but it is specific to my project and I cannot give you all my data due to the size.
It is a simple dataset loaded by dataset = tf.keras.utils.image_dataset_from_directory()
which was mapped through dataset.map(lambda x, y: (x, x))
.
Do you want me to add the loader code anyway or do you want to use MNIST for this purpose ?
I should mention though that I did not get any errors. I only got a warning, this also why I didn't include any stacktrace, as there was none.
@cb0s , In order to expedite the trouble-shooting process, could you please provide the complete code.Thanks!
This issue has been automatically marked as stale because it has no recent activity. It will be closed if no further activity occurs. Thank you.
Closing as stale. Please reopen if you'd like to work on this further.
aww I am facing the same problem.
I am facing the same problem.
Please go to TF Forum for help and support:
https://discuss.tensorflow.org/tag/keras
If you open a GitHub issue, here is our policy:
It must be a bug, a feature request, or a significant problem with the documentation (for small docs fixes please send a PR instead). The form below must be filled out.
Here's why we have that policy:.
Keras developers respond to issues. We want to focus on work that benefits the whole community, e.g., fixing bugs and adding features. Support only helps individuals. GitHub also notifies thousands of people when issues are filed. We want them to see you communicating an interesting problem, rather than being redirected to Stack Overflow.
System information.
You can collect some of this information using our environment capture script:
https://github.com/tensorflow/tensorflow/tree/master/tools/tf_env_collect.sh
You can obtain the TensorFlow version with: python -c "import tensorflow as tf; print(tf.version.GIT_VERSION, tf.version.VERSION)"
Describe the problem.
This issue first appeared here as issue 55060.
I train a multi-scale deep convolutional autoencoder. After some epochs
val_loss
cannot be identified by tensorflow callbacks any more: _WARNING:tensorflow:Learning rate reduction is conditioned on metricval_loss
which is not available. Available metrics are: loss,accuracy,lr WARNING:tensorflow:Early stopping conditioned on metricval_loss
which is not available. Available metrics are: loss,accuracy,lr_My callbacks are:
The last
ModelCheckpoint
callback I added to work around this bug. This sadly means that I have to put more work into it, in order for it to work as I have to reduce the LR manually.In tensorboard it looks like this:
You can see that the
val_loss
is not even calculated any more. This happens after epoch 4, so after theModelCheckpoint
was first reached.Describe the expected behavior.
The expected behaviour would be that
val_loss
is further calculated and can therefore also be used in theModelCheckpoint
s,EarlyStopping
s and other callbacks I use.I am not entirely sure if it is me using the library wrong or whether it really fails due to a bug (I am by no means an expert in TF). The code for the network generation is also included in the PR, the data sets are too big though and are not online available. The used data are Copernicus 4 channel 256x256 images. This is why I did not include the dataloading code as it seems irrelevant to me (I can include it though if you need it).
Contributing.
Standalone code to reproduce the issue.
Provide a reproducible test case that is the bare minimum necessary to generate the problem. If possible, please share a link to Colab/Jupyter/any notebook.
Source code / logs.
Include any logs or source code that would be helpful to diagnose the problem. If including tracebacks, please include the full traceback. Large logs and files should be attached. Try to provide a reproducible test case that is the bare minimum necessary to generate the problem.