code: def predict(self, X, y):
          
          y_pred = self.model.predict_on_batch(X)
  
          # reduce dimension.
          y_true = np.argmax(y, -1)
          y_pred = np.argmax(y_pred, -1)
  
          lens = self.get_length(y_true)
  
          y_true = self.convert_idx_to_name(y_true, lens)
          y_pred = self.convert_idx_to_name(y_pred, lens)
  
          return y_true, y_pred
docs: Predict sequences.
  
          Args:
              X (list): input data.
              y (list): tags.
  
          Returns:
              y_true: true sequences.
              y_pred: predicted sequences.