code: def resample(self, search_fields, selection):
      # search_fields act as group of fields in the paper (like activation group)
      self._initialize()
      result = selection.copy()
  
      # 1. update initial state with fields not searched
      for field in self.fields:
          if field not in search_fields:
              self._update_state(field, selection[field.name])
  
      # 2. get probability of field to search
      for field in search_fields:
          result[field.name] = self._sample_single(field)
      return result
  
file_path: AutoGL/autogl/module/nas/algorithm/agnn_rl.py
imports: from .rl import *
  import numpy
label_desc: Use image node_id 1 for calling the AGNNReinforceController obj's underlying member method code with example usage: obj.resample(search_fields, selection) and returns: result