title: ValueError: all the input array dimensions for the concatenation axis must match exactly but along dimension 1,
body: <p>While working on a ML project, we encountered the following value error:
  ValueError: all the input array dimensions for the concatenation axis must match exactly, but along dimension 1, the array at index 0 has size 118 and the array at index 1 has size 850.</p>
  
  <p>The function that we have been working on is given below:</p>
  
  <pre><code>def function_FeatureExtract(path, indices, featureNum, classLabel):
  
      extension = '.wav'
  
      ListOfFrame2Vec = np.empty((0, frame_number, featureNum))
      LabelOfTotalFrame2Vec = np.empty((0, 1, 1))
  
      DictionaryFiletoIndex=[]
  
      for root, dirs_list, files_list in os.walk(path):
          for file_name in files_list:
              #if os.path.splitext(file_name)[-1] == extension:
              audiofile = os.path.join(root, file_name)
              print(audiofile)
              audio, s_rate = librosa.load(audiofile, sr=sample_rate)
              #print(file_name)
              segment_start_flag=0
              start_seg = 0
              while (start_seg + segment_length) &lt; len(audio):
  
                  sound1 = audio[start_seg:(start_seg + segment_length)]
  
                  featureSet=function_FeatureExtractfromSinglewindow(sound1, hop_length, sample_rate)
  
                  if segment_start_flag==0:
                      SegAllFeat=featureSet
                      segment_start_flag=1
                  else:
                      SegAllFeat=np.vstack((SegAllFeat,featureSet))
  
                  start_seg = start_seg + overlappiong
  
              if segment_start_flag==1:
                  SegAllFeat=normalize(SegAllFeat, norm = 'l2', axis=0)
                  SegAllFeat=SegAllFeat[:, indices[0:featureNum]]
  
              ListOfFrame2Vec = np.append(ListOfFrame2Vec, array([SegAllFeat]), axis=0)
  
              if classLabel == 1:
                  LabelOfTotalFrame2Vec=np.append(LabelOfTotalFrame2Vec,np.array([1]))
              else:
                  LabelOfTotalFrame2Vec = np.append(LabelOfTotalFrame2Vec, np.array([0]))
              #LabelOfTotalFrame2Vec
  
  
  
              DictionaryFiletoIndex.append(file_name)
  
  
              print(ListOfFrame2Vec.shape)
              print(LabelOfTotalFrame2Vec.shape)
      return ListOfFrame2Vec, LabelOfTotalFrame2Vec, DictionaryFiletoIndex
  </code></pre>
  
  <p>The line of code causing the error is:</p>
  
  <pre><code>ListOfFrame2Vec = np.append(ListOfFrame2Vec, array([SegAllFeat]), axis=0)
  </code></pre>
  
  <p>The shape of SegAllFeat is (850,80) and that of ListOfFrame2Vec is (0,118,80), but reshaping these arrays has not been successfull.</p>