code: def generate_noise_utterances(
      augmented_utterances,
      noise,
      num_intents,
      data_augmentation_config,
      language,
      random_state,
  ):
      import numpy as np
  
      if not augmented_utterances or not num_intents:
          return []
      avg_num_utterances = len(augmented_utterances) / float(
          num_intents
      )
      if (
          data_augmentation_config.unknown_words_replacement_string
          is not None
      ):
          noise = generate_smart_noise(
              noise,
              augmented_utterances,
              data_augmentation_config.unknown_words_replacement_string,
              language,
          )
  
      noise_size = min(
          int(
              data_augmentation_config.noise_factor * avg_num_utterances
          ),
          len(noise),
      )
      utterances_lengths = [
          len(tokenize_light(get_text_from_chunks(u[DATA]), language))
          for u in augmented_utterances
      ]
      mean_utterances_length = np.mean(utterances_lengths)
      std_utterances_length = np.std(utterances_lengths)
      noise_it = get_noise_it(
          noise,
          mean_utterances_length,
          std_utterances_length,
          random_state,
      )
      # Remove duplicate 'unknownword unknownword'
      return [
          text_to_utterance(
              UNKNOWNWORD_REGEX.sub(UNKNOWNWORD, next(noise_it))
          )
          for _ in range(noise_size)
      ]
  
imports: from __future__ import division, unicode_literals
  import itertools
  import re
  from builtins import next, range, str
  from copy import deepcopy
  from uuid import uuid4
  from future.utils import iteritems, itervalues
  from snips_nlu.constants import DATA, ENTITY, INTENTS, TEXT, UNKNOWNWORD, UTTERANCES
  from snips_nlu.data_augmentation import augment_utterances
  from snips_nlu.dataset import get_text_from_chunks
  from snips_nlu.entity_parser.builtin_entity_parser import is_builtin_entity
  from snips_nlu.preprocessing import tokenize_light
  from snips_nlu.resources import get_noise
label_desc: Use image node_id 5 for calling a global function with example usage: generate_noise_utterances(augmented_utterances, noise, num_intents, data_augmentation_config, language, random_state) and returns: unknown, list