class_docstr: A dataset that accepts as argument multiple datasets and then samples from them based on the specified 
  sampling technique.
  Args:
      datasets (list): A list of datasets to sample from.
      shuffle (bool): Whether to shuffle individual datasets. Only works with non-iterable datasets. 
          Defaults to True.
      sampling_technique (str): Sampling technique to choose which dataset to draw a sample from.
          Defaults to 'temperature'. Currently supports 'temperature', 'random' and 'round-robin'.
      sampling_temperature (int): Temperature value for sampling. Only used when sampling_technique = 'temperature'.
          Defaults to 5.
      sampling_scale: Gives you the ability to upsample / downsample the dataset. Defaults to 1.
      sampling_probabilities (list): Probability values for sampling. Only used when sampling_technique = 'random'.
      seed: Optional value to seed the numpy RNG.
      global_rank (int): Worker rank, used for partitioning map style datasets. Defaults to 0.
      world_size (int): Total number of processes, used for partitioning map style datasets. Defaults to 1.
code: def temperature_generator(datasets, **kwargs):
      temp = kwargs.get("temperature")
      if not temp:
          raise ValueError(
              "Temperature generator expects a 'temperature' keyword argument."
          )
  
      seed = kwargs.get("seed", None)
      np_rng = np.random.RandomState(seed)
      lengths = []
      num = len(datasets)
      for dataset in datasets:
          lengths.append(len(dataset))
  
      p = np.array(lengths) / np.sum(lengths)
      p = np.power(p, 1 / temp)
      p = p / np.sum(p)
  
      while True:
          ind = np_rng.choice(np.arange(num), p=p)
          yield ind
  
imports: import io
  import logging
  from typing import Any, List, Optional, Tuple, Union
  import numpy
  import torch
  import torch.utils.data
  from torch.utils.data import Dataset, IterableDataset
label_desc: Use image node_id 5 for calling the ConcatDataset obj's underlying member method code with example usage: obj.temperature_generator(datasets) without return types