title: What is wrong with my CNN?
body: <p>I really don't understand what is wrong with my model. Sometimes it gives me excellent results, but in other cases results are just absurd. During training, from one moment to another it gives absurd results. I tried model with 3 dropout layers and without them, and get same strange results. Here's my model definition:</p>
  
  
  
  <pre class="lang-python prettyprint-override"><code>batch_size = 1
  epochs = 25
  model = Sequential()
  model.add(Conv1D(32, input_shape=(1040,1), kernel_size=100,padding='same',name='ConvLayer1', strides=1))
  model.add(LeakyReLU(alpha=0.1))
  model.add(MaxPooling1D(pool_size=70, strides=1, padding='same',name='PoolingLayer1'))
  #model.add(Dropout(0.10))
  model.add(Conv1D(64, kernel_size=70,padding='same',name='ConvLayer2',strides=1))
  model.add(LeakyReLU(alpha=0.1))
  model.add(MaxPooling1D(pool_size=40, strides=1, padding='same',name='PoolingLayer2'))
  #model.add(Dropout(0.10))
  model.add(Conv1D(128, kernel_size=40,padding='same',name='ConvLayer3',strides=1))
  model.add(LeakyReLU(alpha=0.1))
  model.add(MaxPooling1D(pool_size=10, strides=1, padding='same',name='PoolingLayer3'))
  #model.add(Dropout(0.10))
  model.add(Flatten())
  model.add(Dense(1,name='output', activation='linear'))
  w = model.get_weights()
  model.compile(loss='mse', optimizer=keras.optimizers.Adam(lr=0.001),metrics=['mse'])
  </code></pre>
  
  <p>Get that kind of results: <a href="https://ibb.co/feqJr7" rel="nofollow noreferrer">Results screenshot</a></p>
  
  <p>What is happening? And also, do you know how I can improve this model to get better results?</p>