How can a specific model be cleared from the memory?
you can use del[] to explicitly delete the variables you no longer need, this triggers python's garbage collector. so put all the variables associated with that model inside del[] and python would free the memory.
I created several Keras models (Model_1, Model_2...Model_N) in one code. I would like to clear only one specified model (e.g. Model_1).
I guess K.clear_session(), which will clear all models from the memory, is not useful in this case. Is there any solution?
Thank you in advance.