Why Tensorfow takes a long time with memory optimizer?

Viewed 893

I have developed my first layer in Keras and when I run a model based on it, it takes a long time and then it prompts:

tensorflow/core/grappler/optimizers/meta_optimizer.cc:499] memory_optimizer failed: Deadline exceeded: memory_optimizer exceeded deadline., time = 290379.781ms.

After that, based on the batch size that I've set, it might throw OOM (out of memory) error or not. In case it doesn't, the training starts. But since it takes around 30 minutes to come up with the error, it is not easy for me to tune the best batch size possible.

Does anyone know what makes the memory optimizer take so long? And how can I fix this issue?

If you are interested to see the layer's code, you can find it here.

0 Answers
Related