code: def test_fixed_bucket_sampler_with_single_key(
      bucket_keys, ratio, shuffle
  ):
      seq_lengths = [np.random.randint(10, 100) for _ in range(N)]
      sampler = s.FixedBucketSampler(
          seq_lengths,
          batch_size=8,
          num_buckets=None,
          bucket_keys=bucket_keys,
          ratio=ratio,
          shuffle=shuffle,
      )
      print(sampler)
      total_sampled_ids = []
      for batch_sample_ids in sampler:
          total_sampled_ids.extend(batch_sample_ids)
      assert len(set(total_sampled_ids)) == len(total_sampled_ids) == N
  
file_path: gluon-nlp/tests/test_data_sampler.py
imports: import pytest
  import numpy
  from mxnet.gluon import data
  from gluonnlp.data import sampler
label_desc: Use image node_id 3 for calling a global function with example usage: test_fixed_bucket_sampler_with_single_key(bucket_keys, ratio, shuffle) without return types