class_docstr: Transformation controller which applies multi transformations
  to each data sample.
class_docstr_tok: ["Transformation","controller","which","applies","multi","transformations","to","each","data","sample","."]
docstr: Returns a list of possible generated samples for ``dataset``.
  
  :param textflint.Dataset dataset: the input dataset
  :param textflint.FlintModel model: the model to attack if given.
  :return: yield (original samples, new samples,
      generated function string).
docstr_tok: ["Returns","a","list","of","possible","generated","samples","for","``","dataset","``",".",":","param","textflint.Dataset","dataset",":","the","input","dataset",":","param","textflint.FlintModel","model",":","the","model","to","attack","if","given",".",":","return",":","yield","(","original","samples",",","new","samples",",","generated","function","string",")","."]
code: def generate(self, dataset, model=None):
      r"""
      Returns a list of possible generated samples for ``dataset``.
  
      :param textflint.Dataset dataset: the input dataset
      :param textflint.FlintModel model: the model to attack if given.
      :return: yield (original samples, new samples,
          generated function string).
  
      """
      for data in self.generate_by_transformations(dataset):
          yield data
      for data in self.generate_by_subpopulations(dataset):
          yield data
      for data in self.generate_by_attacks(dataset, model):
          yield data
  
imports: from tqdm import tqdm
  from abc import ABC
  from itertools import product
  from ...input.dataset import Dataset
  from ...common.utils.seed import set_seed
  from ...common.utils.logger import logger
  from ...common.preprocess import EnProcessor
  from ...common.utils.load import pkg_class_load, load_module_from_file
  from ..transformation import Transformation, Pipeline
  from ..subpopulation import SubPopulation
  from ...common.settings import TASK_TRANSFORMATION_PATH, ALLOWED_TRANSFORMATIONS, TASK_SUBPOPULATION_PATH, ALLOWED_SUBPOPULATIONS
label_desc: Use image node_id 3 for calling the Generator obj's underlying member method code with example usage: obj.generate(dataset, model) without return types