class_docstr: Creates transposed versions of the input NoteSequence.
class_docstr_tok: ["Creates","transposed","versions","of","the","input","NoteSequence","."]
code: def transform(self, input_object):
      sequence = input_object
      stats = dict(
          (state_name, statistics.Counter(state_name))
          for state_name in [
              "skipped_due_to_range_exceeded",
              "transpositions_generated",
          ]
      )
  
      if sequence.key_signatures:
          tf.logging.warn(
              "Key signatures ignored by TranspositionPipeline."
          )
      if any(note.pitch_name for note in sequence.notes):
          tf.logging.warn(
              "Pitch names ignored by TranspositionPipeline."
          )
      if any(
          ta.annotation_type == CHORD_SYMBOL
          for ta in sequence.text_annotations
      ):
          tf.logging.warn(
              "Chord symbols ignored by TranspositionPipeline."
          )
  
      transposed = []
      for amount in self._transposition_range:
          # Note that transpose is called even with a transpose amount of zero, to
          # ensure that out-of-range pitches are handled correctly.
          ts = self._transpose(sequence, amount, stats)
          if ts is not None:
              transposed.append(ts)
  
      stats["transpositions_generated"].increment(len(transposed))
      self._set_stats(stats.values())
      return transposed
  
imports: import copy
  from magenta.pipelines import pipeline
  from magenta.pipelines import statistics
  from note_seq import constants
  from note_seq import sequences_lib
  from note_seq.protobuf import music_pb2
  import tensorflow.compat.v1
label_desc: Use image node_id 2 for calling the TranspositionPipeline obj's underlying member method code with example usage: obj.transform(input_object) and returns: transposed