title: Why can't I use preprocessing module in Keras?
body: <p>I'm trying to use the function pad_sequences() but the same error keeps rising: 'AttributeError: 'module' object has no attribute 'sequence''</p>
  
  <p>I have followed Keras documentation and I can't figure out why It does not work. Here is the line of code:</p>
  
  <pre><code>from keras import preprocessing
  import keras
  
  X_test = sequence.pad_sequences(X_test, maxlen=500)
  X_test = preprocessing.sequence.pad_sequences(X_test, maxlen=500)   
  X_test = keras.preprocessing.sequence.pad_sequences(X_test, maxlen=500)
  </code></pre>
  
  <p>None of the above lines seem to work.</p>