class_docstr: An `adanet.Generator` from a pool of `Estimator` and `Model` instances.
class_docstr_tok: ["An","`","adanet.Generator","`","from","a","pool","of","`","Estimator","`","and","`","Model","`","instances","."]
code: def _maybe_call_candidate_pool(self, config, iteration_number):
      if callable(self._candidate_pool):
          # candidate_pool can be a function.
          candidate_pool_args = inspect.getargs(
              self._candidate_pool.__code__
          ).args
          if "iteration_number" in candidate_pool_args:
              # TODO: Make the "config" argument optional using introspection.
              return self._candidate_pool(
                  config=config, iteration_number=iteration_number
              )
          else:
              return self._candidate_pool(config=config)
  
      return self._candidate_pool
  
imports: from __future__ import absolute_import
  from __future__ import division
  from __future__ import print_function
  import collections
  import inspect
  from adanet import subnetwork
  from adanet import tf_compat
  import tensorflow.compat.v2
label_desc: Use image node_id 3 for calling the _GeneratorFromCandidatePool obj's underlying member method code with example usage: obj._maybe_call_candidate_pool(config, iteration_number) and returns: self, self, self