Exemplo n.º 1
0
  def to_tensors(self, note_sequence):
    """Python method that converts `note_sequence` into list of tensors."""
    note_sequences = data.preprocess_notesequence(
        note_sequence, self._presplit_on_time_changes)

    results = []
    for ns in note_sequences:
      results.append(
          super(BaseHierarchicalNoteSequenceConverter, self).to_tensors(ns))
    return self._combine_to_tensor_results(results)
Exemplo n.º 2
0
  def to_tensors(self, note_sequence):
    """Python method that converts `note_sequence` into list of tensors."""
    note_sequences = data.preprocess_notesequence(
        note_sequence, self._presplit_on_time_changes)

    results = []
    for ns in note_sequences:
      results.append(
          super(BaseHierarchicalNoteSequenceConverter, self).to_tensors(ns))
    return self._combine_to_tensor_results(results)