Open alecontuIT opened 7 months ago
You need to clear the session when training multiple models in a loop because Keras is managing a global state which consume more memory the more loops the model training takes. Import with keras import backend as K
and put K.clear_session()
at the end of the for loop.
During the training of the model i can't even finish the first episode because after some time I get the message "Kernel died". I'm using a macbook with m1. I tried to lower the training size, the memory size, but the result is always the same.