class_docstr: Builds a NASNet subnetwork for AdaNet.
docstr: See `adanet.subnetwork.Builder`.
docstr_tok: ["See","`","adanet.subnetwork.Builder","`","."]
code: def build_subnetwork(
      self,
      features,
      logits_dimension,
      training,
      iteration_step,
      summary,
      previous_ensemble=None,
  ):
      """See `adanet.subnetwork.Builder`."""
  
      # Prepare the input.
      assert (
          len(self._feature_columns) == 1
      ), "Got feature columns: {}".format(self._feature_columns)
      images = tf.to_float(features[self._feature_columns[0].name])
      self._name_scope = tf.get_default_graph().get_name_scope()
  
      seed = self._seed
      if seed is not None and previous_ensemble:
          # Deterministically change the seed for different iterations so that
          # subnetworks are not correlated.
          seed += len(previous_ensemble.weighted_subnetworks)
  
      arg_scope = nasnet.nasnet_cifar_arg_scope(
          weight_decay=self._weight_decay
      )
  
      with tf.contrib.slim.arg_scope(arg_scope):
          build_fn = nasnet.build_nasnet_cifar
          logits, end_points = build_fn(
              images,
              num_classes=logits_dimension,
              is_training=training,
              config=self._hparams,
          )
      last_layer = end_points["global_pool"]
  
      subnetwork_shared_data = {
          _PREVIOUS_NUM_CELLS: tf.constant(self._num_cells),
          _PREVIOUS_CONV_FILTERS: tf.constant(self._num_conv_filters),
      }
  
      return adanet.Subnetwork(
          last_layer=last_layer,
          logits=logits,
          complexity=1,
          shared=subnetwork_shared_data,
      )
  
imports: from __future__ import absolute_import
  from __future__ import division
  from __future__ import print_function
  import functools
  import adanet
  import tensorflow.compat.v1
label_desc: Use image node_id 2 for calling the Builder obj's underlying member method code with example usage: obj.build_subnetwork(features, logits_dimension, training, iteration_step, summary, previous_ensemble) and returns: adanet