class_docstr: uniform mutator
  
  Parameters
  ----------
  nas_modules: 
      nas_modules in NAS algorithms , including choices of modules
  mutation_prob: float
      probability of doing mutation in each choice.
  parent : dict
      parent individual's choices
class_docstr_tok: ["uniform","mutator","Parameters","--","--","--","--","--","nas_modules",":","nas_modules","in","NAS","algorithms",",","including","choices","of","modules","mutation_prob",":","float","probability","of","doing","mutation","in","each","choice",".","parent",":","dict","parent","individual","'s","choices"]
code: def resample(self, parent):
      search_space = self.selection_dict
      child = {}
      for k, v in parent.items():
          if random.uniform(0, 1) < self.mutation_prob:
              child[k] = np.random.choice(
                  range(search_space[k])
              )  # do not exclude the original operator
          else:
              child[k] = v
      return child
  
imports: import copy
  from logging import Logger
  from numpy.core.fromnumeric import sort
  import torch
  import torch.nn
  import torch.nn.functional
  from .None import register_nas_algo
  from .base import BaseNAS
  from ..space import BaseSpace
  from ..utils import AverageMeterGroup, replace_layer_choice, replace_input_choice, get_module_order, sort_replaced_module, PathSamplingLayerChoice, PathSamplingInputChoice
  from tqdm import tqdm, trange
  from ....utils import get_logger
  import numpy
  import collections
  import dataclasses
  import random
label_desc: Use image node_id 2 for calling the MutationSampler obj's underlying member method code with example usage: obj.resample(parent) and returns: child