title: Approximation with keras
body: <p>I am trying to approximate function with keras model, that has only one hidden layer and whatever I do - I can't reach necessary result.</p>
  
  <p>I'm trying to do it with following code</p>
  
  <p></p>
  
  <pre><code>from __future__ import print_function
  from keras.models import Sequential
  from keras.layers import Dense
  from keras.optimizers import Adam
  
  from LABS.ZeroLab import E_Function as dataset5
  
  train_size = 2000
  
  # 2 model and data initializing
  (x_train, y_train), (x_test, y_test) = dataset5.load_data(train_size=train_size, show=True)
  
  model = Sequential()
  
  model.add(Dense(50, kernel_initializer='he_uniform', bias_initializer='he_uniform', activation='sigmoid'))
  
  model.add(Dense(1, kernel_initializer='he_uniform', bias_initializer='he_uniform', activation='linear'))
  
  model.compile(optimizer=Adam(), loss='mae', metrics=['mae'])
  
  history = model.fit(x=x_train, y=y_train, batch_size=20, epochs=10000, validation_data=(x_test, y_test), verbose=1)
  </code></pre>
  
  <p></p>
  
  <p><a href="https://i.stack.imgur.com/VX2f5.png" rel="nofollow noreferrer">It's function that loads from dataset5</a></p>
  
  <p><a href="https://i.stack.imgur.com/4zJT9.png" rel="nofollow noreferrer">It's comparison of model prediction with testing data</a></p>
  
  <p>I tryied to fit this network with different optimizers and neurons number (from 50 to 300), but result was the same.</p>
  
  <p>What should I change?</p>