title: Python script hangs when running lstm on multiple cores
body: <p>I am trying to create different lstm models on different data using multiprocessing Pool.
  The program hangs when it tries to create a lstm layer.</p>
  
  <pre><code>def create_model(neurons, X):
      model = Sequential() 
      model.add(LSTM(neurons, input_shape=(X.shape[1], X.shape[2]), return_sequences=False))
      model.add(Dense(1, kernel_initializer='uniform', activation='relu'))
      model.compile(loss='mean_squared_error', optimizer='adam', metrics=['mae', 'mse','accuracy'])
      return model
  
  from pathos.multiprocessing import ProcessingPool
  from itertools import repeat
  pool = ProcessingPool(4)
  neurons = [50, 100]
  results = pool.map(create_model, neurons, repeat(X))
  </code></pre>
  
  <p>The script hangs at the lstm layer creation. Program works if I replace lstm by dense. What is wrong in the code?</p>