keras load_model raise error when executed a second time
You can create a new sesstion and load the model to it.
from keras.models import load_model
import keras
def network(campaign):
with keras.backend.get_session().graph.as_default():
model = load_model("sunshade/neural_network/model.h5")
label = model.predict(images, batch_size = 128, verbose = 1)