title: 'Tensor' object has no attribute 'ndim'
body: <p>I m tryting to make concat networks which are LSTM,LSTM(EMBEDDING),DNN
  to solve classification problem</p>
  
  <p>but I got this error.
  See the code below:</p>
  
  <pre><code># Shared Feature Extraction Layer
  from keras.utils import plot_model
  from keras.models import Model
  from keras.layers import Input
  from keras.layers import Dense
  from keras.layers.recurrent import LSTM
  from keras.layers.merge import concatenate
  
  # define input
  visible = Input(shape=(190,1))
  visible1 = Input(shape=(3000,1))
  
  # feature extraction
  extract1 =  LSTM(50, return_sequences=False)(visible)
  
  extract2 = LSTM(50, return_sequences=False)(visible1)
  
  # merge interpretation
  merge = concatenate([extract1, extract2])
  # output
  output = Dense(1, activation='sigmoid')(merge)
  model = Model(inputs=[visible,visible1], outputs=output)
  # summarize layers
  print(model.summary())
  model.compile(optimizer = "adam", loss = 'binary_crossentropy', metrics= 
  ['accuracy'])  
  print("test",data.shape) 
  print("test2",data_.shape)
  # model.fit([data,data_],  y,  epochs=20, verbose=1)
  </code></pre>
  
  <p><a href="https://i.stack.imgur.com/affCJ.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/affCJ.png" alt="enter image description here"></a></p>
  
  <blockquote>
    <p>but got this error:
    --------------------------------------------------------------------------- AttributeError                            Traceback (most recent call
    last)  in ()
    ----> 1 model.fit([data,data_], y, epochs = 350, batch_size = 64)</p>
    
    <p>/etc/anaconda3/lib/python3.6/site-packages/keras/engine/training.py in
    fit(self, x, y, batch_size, epochs, verbose, callbacks,
    validation_split, validation_data, shuffle, class_weight,
    sample_weight, initial_epoch, steps_per_epoch, validation_steps,
    **kwargs)    1628             sample_weight=sample_weight,    1629             class_weight=class_weight,
    -> 1630             batch_size=batch_size)    1631         # Prepare validation data.    1632         do_validation = False</p>
    
    <p>/etc/anaconda3/lib/python3.6/site-packages/keras/engine/training.py in
    _standardize_user_data(self, x, y, sample_weight, class_weight, check_array_lengths, batch_size)    1478<br>
    output_shapes,    1479<br>
    check_batch_axis=False,
    -> 1480                                     exception_prefix='target')    1481         sample_weights =
    _standardize_sample_weights(sample_weight,    1482                                                      self._feed_output_names)</p>
    
    <p>/etc/anaconda3/lib/python3.6/site-packages/keras/engine/training.py in
    _standardize_input_data(data, names, shapes, check_batch_axis, exception_prefix)
         74         data = data.values if data.<strong>class</strong>.<strong>name</strong> == 'DataFrame' else data
         75         data = [data]
    ---> 76     data = [np.expand_dims(x, 1) if x is not None and x.ndim == 1 else x for x in data]
         77 
         78     if len(data) != len(names):</p>
    
    <p>/etc/anaconda3/lib/python3.6/site-packages/keras/engine/training.py in
    (.0)
         74         data = data.values if data.<strong>class</strong>.<strong>name</strong> == 'DataFrame' else data
         75         data = [data]
    ---> 76     data = [np.expand_dims(x, 1) if x is not None and x.ndim == 1 else x for x in data]
         77 
         78     if len(data) != len(names):</p>
    
    <p>AttributeError: 'Tensor' object has no attribute 'ndim'</p>
  </blockquote>
  
  <p>plz, help me :)</p>