title: Conv1D and batch_size questions
body: <p>I face two problems when I implement 1D convnet for multi-channel sequential data.
  (224 samples x 300 time sequential x 19 channels)</p>
  
  <p>1) I set batch_size as 7 but it jumps with 5 times of that.
  not 7 14 21 28, but 7, 56, 105, 147... what's wrong with mine?</p>
  
  <p>2) when I look at the records of accuracy, it looks like to learn NOTHING.
  is it impossible implement classifier for multi-channel sequential data with Conv1D?
  If possible can you give me some advice from my code?</p>
  
  <pre><code>#result
  x_train shape: (224, 300, 19)
  224 train samples
  28 test samples
  
  Train on 224 samples, validate on 28 samples
  
  Epoch 1/50
    7/224 [..............................] - ETA: 68s - loss: 0.6945 - acc: 0.5714
   56/224 [======&gt;.......................] - ETA: 6s - loss: 0.6993 - acc: 0.4464 
  105/224 [=============&gt;................] - ETA: 2s - loss: 0.6979 - acc: 0.4381
  147/224 [==================&gt;...........] - ETA: 1s - loss: 0.6968 - acc: 0.4422
  189/224 [========================&gt;.....] - ETA: 0s - loss: 0.6953 - acc: 0.4444
  224/224 [==============================] - 2s - loss: 0.6953 - acc: 0.4420 - val_loss: 0.6956 - val_acc: 0.5000
  
  Epoch 2/50
    7/224 [..............................] - ETA: 0s - loss: 0.6759 - acc: 0.5714
   63/224 [=======&gt;......................] - ETA: 0s - loss: 0.6924 - acc: 0.5556
  133/224 [================&gt;.............] - ETA: 0s - loss: 0.6905 - acc: 0.5338
  203/224 [==========================&gt;...] - ETA: 0s - loss: 0.6903 - acc: 0.5567
  224/224 [==============================] - 0s - loss: 0.6923 - acc: 0.5357 - val_loss: 0.6968 - val_acc: 0.5000
  
  # code
  
  from __future__ import print_function
  import keras
  from keras.models import Sequential
  from keras.layers import Dense, Dropout, Flatten, Activation
  from keras.layers import Conv2D, MaxPooling2D, Conv1D, MaxPooling1D
  import numpy as np
  
  batch_size = 7
  num_classes = 2
  epochs = 50
  
  # input data dimensions : 300 sequential x 19 channels
  eeg_rows, num_ch = 300, 19
  
  x_train = np.load('eeg_train.npy')
  y_train = np.load('label_train.npy')
  
  x_test = np.load('eeg_test.npy')
  y_test = np.load('label_test.npy')
  
  x_valid = np.load('eeg_valid.npy')
  y_valid = np.load('label_valid.npy')
  
  x_train = x_train.reshape(x_train.shape[0], eeg_rows, num_ch)
  x_test = x_test.reshape(x_test.shape[0], eeg_rows,num_ch)
  x_valid = x_valid.reshape(x_valid.shape[0], eeg_rows, num_ch)
  
  input_shape = (eeg_rows, num_ch)
  
  x_train = x_train.astype('float32')
  x_test = x_test.astype('float32')
  x_valid = x_test.astype('float32')
  
  x_train /= 100
  x_test /= 100
  x_valid /= 100
  
  print('x_train shape:', x_train.shape)
  print(x_train.shape[0], 'train samples')
  print(x_test.shape[0], 'test samples')
  # model
  conv = Sequential()
  
  conv.add(Conv1D(32, 3, input_shape=input_shape, activation='relu', padding='same'))
  conv.add(Conv1D(32, 3, activation='relu', padding='same'))
  conv.add(MaxPooling1D(pool_size=2, strides=2, padding='same'))
  conv.add(Dropout(0.2))
  
  conv.add(Flatten())
  conv.add(Dense(16, activation='relu'))
  conv.add(Dropout(0.5))
  conv.add(Dense(2, activation='softmax'))
  
  conv.compile(loss='categorical_crossentropy',
                optimizer=keras.optimizers.Adam(),
                metrics=['accuracy'])
  
  # train
  conv.fit(x_train, y_train,
            batch_size=batch_size,
            epochs=epochs,
            verbose=1,
            validation_data=(x_valid, y_valid))
  
  score = conv.evaluate(x_valid, y_valid, verbose=0)
  
  print(conv.summary())
  print(conv.input_shape)
  print(conv.output_shape)
  print('Test loss:', score[0])
  print('Test accuracy:', score[1])
  </code></pre>