title: classification report in keras
body: <p>i am using the classification report to calculate the precision, recall and fscore for the following model</p>
  
  
  
  <pre class="lang-python prettyprint-override"><code>x_train = train[:,[3,4,5,6,7]]
  x_test = test[:,[3,4,5,6,7]]
  y_train = train[:,8]
  y_test = test[:,8]
  
  n = x_train.shape[0]
  n2 = x_test.shape[0]
  L = 32
  X_train_seq = []
  Y_train_seq = []
  for k in range(n - L + 1):
      X_train_seq.append(x_train[k : k + L])
      Y_train_seq.append(y_train[k : k + L])
  
  X_test_seq = []
  Y_test_seq = []
  for k1 in range(n2 - L + 1):
      X_test_seq.append(x_test[k1 : k1 + L])
      Y_test_seq.append(y_test[k1 : k1 + L])
  
  X_train_seq = np.array(X_train_seq)
  Y_train_seq = np.array(Y_train_seq)
  X_test_seq = np.array(X_test_seq)
  Y_test_seq = np.array(Y_test_seq)
  
  model = Sequential()
  model.add(LSTM(64, input_shape=(32, 5), activation='tanh'))
  model.add(Dense(32, activation='sigmoid' ))
  model.compile(loss='binary_crossentropy',
                optimizer='adam',
                metrics=['accuracy'])
  
  hist = model.fit(X_train_seq, Y_train_seq, batch_size = 200, epochs = 15,
                   verbose = 2)
  avg = np.mean(hist.history['acc'])
  print('The Average Training Accuracy is', avg)
  score=model.evaluate(X_test_seq, Y_test_seq, batch_size=200,verbose=2)
  print(score)
  
  y_pred=model.predict(X_test_seq, batch_size=200, verbose=2)
  report = classification_report(Y_test_seq, y_pred.round())
  print(report)
  </code></pre>
  
  <p>the problem here is the output, it is not true i guess and i don't know why !
  this is a sample of the output</p>
  
  <pre class="lang-python prettyprint-override"><code> precision    recall  f1-score   support
  
  0       0.35      0.11      0.17     30146
  1       0.35      0.12      0.17     30146
  2       0.35      0.12      0.17     30146
  3       0.35      0.12      0.18     30146
  4       0.35      0.12      0.18     30146
  5       0.35      0.12      0.18     30146
  </code></pre>
  
  <p>why the values are very low, although the accuracy is 94%</p>