class_docstr: Subnetwork training and evaluation `Tensors` and `Ops`.
  
  Args:
    name: String name of this subnetwork. Should be unique in the graph.
    subnetwork: The `adanet.subnetwork.Subnetwork` for this spec.
    builder: The `adanet.subnetwork.Builder` that produced `subnetwork`.
    predictions: Predictions `Tensor` or dict of `Tensor`.
    step: `tf.Variable` step counter representing the number of steps this
      subnetwork trained for. Resets at every AdaNet iteration.
    loss: Loss `Tensor` as computed by the `Head`. Must be either scalar, or
      with shape `[1]`.
    train_op: Candidate subnetwork's `TrainOpSpec`.
    eval_metrics: `_SubnetworkMetrics` object.
    asset_dir: Checkpoint directory for the sub-estimators.
  
  Returns:
    A `_SubnetworkSpec` object.
code: def __new__(
      cls,
      name,
      subnetwork,
      builder,
      predictions,
      step,
      variables,
      loss=None,
      train_op=None,
      eval_metrics=None,
      asset_dir=None,
  ):
      return super(_SubnetworkSpec, cls).__new__(
          cls,
          name=name,
          subnetwork=subnetwork,
          builder=builder,
          predictions=predictions,
          step=step,
          variables=variables,
          loss=loss,
          train_op=train_op,
          eval_metrics=eval_metrics,
          asset_dir=asset_dir,
      )
  
imports: from __future__ import absolute_import
  from __future__ import division
  from __future__ import print_function
  import collections
  import contextlib
  import copy
  import functools
  import inspect
  import os
  from absl import logging
  from adanet import ensemble
  from adanet import subnetwork
  from adanet import tf_compat
  from adanet.core.architecture import _Architecture
  from adanet.core.eval_metrics import _EnsembleMetrics
  from adanet.core.eval_metrics import _SubnetworkMetrics
  from adanet.core.summary import monkey_patched_summaries
  import tensorflow.compat.v1
  import tensorflow.compat.v2
label_desc: Use image node_id 1 for calling the _SubnetworkSpec obj's underlying member method code with example usage: obj.__new__(cls, name, subnetwork, builder, predictions, step, variables, loss, train_op, eval_metrics, asset_dir) and returns: super