code: def testExtractChordsForMelodies(self):
      music_testing_lib.add_track_to_sequence(
          self.note_sequence, 0, [(12, 100, 2, 4), (11, 1, 6, 11)]
      )
      music_testing_lib.add_track_to_sequence(
          self.note_sequence,
          1,
          [
              (12, 127, 2, 4),
              (14, 50, 6, 8),
              (50, 100, 33, 37),
              (52, 100, 34, 37),
          ],
      )
      music_testing_lib.add_chords_to_sequence(
          self.note_sequence, [("C", 2), ("G7", 6), ("Cmaj7", 33)]
      )
      quantized_sequence = sequences_lib.quantize_note_sequence(
          self.note_sequence, self.steps_per_quarter
      )
  
      melodies, _ = melody_pipelines.extract_melodies(
          quantized_sequence,
          min_bars=1,
          gap_bars=2,
          min_unique_pitches=2,
          ignore_polyphonic_notes=True,
      )
      (
          chord_progressions,
          _,
      ) = chord_pipelines.extract_chords_for_melodies(
          quantized_sequence, melodies
      )
      expected = [
          [
              NO_CHORD,
              NO_CHORD,
              "C",
              "C",
              "C",
              "C",
              "G7",
              "G7",
              "G7",
              "G7",
              "G7",
          ],
          [NO_CHORD, NO_CHORD, "C", "C", "C", "C", "G7", "G7"],
          ["G7", "Cmaj7", "Cmaj7", "Cmaj7", "Cmaj7"],
      ]
      self.assertEqual(
          expected, [list(chords) for chords in chord_progressions]
      )
  
file_path: magenta/magenta/pipelines/chord_pipelines_test.py
imports: from absl.testing import absltest
  from magenta.common import testing_lib
  from magenta.pipelines import chord_pipelines
  from magenta.pipelines import melody_pipelines
  from note_seq import chords_lib
  from note_seq import constants
  from note_seq import sequences_lib
  from note_seq import testing_lib
  from note_seq.protobuf import music_pb2
label_desc: Use image node_id 6 for calling the ChordPipelinesTest obj's underlying member method code with example usage: obj.testExtractChordsForMelodies() without return types