code: def test_generate_unique_mixes(self):
      sourceid_to_exids = [
          ("source1", "a"),
          ("source1", "b"),
          ("source2", "c"),
          ("source2", "d"),
      ]
      exid_to_mixids = create_dataset_lib.generate_mixes(
          val="unused",
          num_mixes=100,
          sourceid_to_exids=sourceid_to_exids,
      )
      mix_ids = set(itertools.chain(*list(exid_to_mixids.values())))
      # Requested 100, but there are only 4 unique mixes, so that's how many
      # we should end up with.
      self.assertEqual(4, len(mix_ids))
  
file_path: magenta/magenta/models/onsets_frames_transcription/create_dataset_lib_test.py
imports: import itertools
  from magenta.models.onsets_frames_transcription import create_dataset_lib
  import numpy
  import tensorflow.compat.v1
label_desc: Use image node_id 1 for calling the CreateDatasetLibTest obj's underlying member method code with example usage: obj.test_generate_unique_mixes() without return types