code: def separate_walks_turns(data, window=[1, 1, 1]):
      
      clusters, peaks, promi = cluster_walk_turn(data, window=window)
      
      group_one = []
      group_two = []
      
      start = 0
  
      for i in range(1, len(clusters)):
          
          if clusters[i-1] != clusters[i]:
              assert np.all(clusters[start: i] == clusters[start]), 'Some values are mixed up, please check!'
              
              add = group_one if clusters[start] == 0 else group_two
              add.append(peaks[start: i])
              start = i
          
          # hacky fix for the last part of the signal ...
          # I need to change this ...
          if i == len(clusters)-1:
              if not peaks[start] in add[-1]:
                  add = group_one if clusters[start] == 0 else group_two
                  add.append(peaks[start: ])
                  
      maxes_one = [np.max(data[c]) for c in group_one]
      maxes_two = [np.max(data[c]) for c in group_two]
      
      walks, turns = group_two, group_one
      
      if np.max(maxes_one) > np.max(maxes_two):
          walks, turns = group_one, group_two
      
      # let's drop any turns at the end of the signal
  #     if len(turns[-1]) > len(walks[-1]):
  #         turns.pop()
      
      return walks, turns
docs: Will separate peaks into the clusters by following the trend in the clusters array.
          This is usedful because scipy's k-mean clustering will give us a continous clusters
          array.
          
          :param clusters array: A continous array representing different classes.
          :param peaks array: The peaks that we want to separate into the classes from the custers.
          
          :return walks arrays: An array of arrays that will have all the peaks corresponding to every
                                individual walk.
          :return turns arraays: Array of array which has all the indices of the peaks that correspond
                                 to turning.