class_docstr: Model helper for building models on top of layers abstractions.
  
  Each layer is the abstraction that is higher level than Operator. Layer
  is responsible for ownership of it's own parameters and can easily be
  instantiated in multiple nets possible with different sets of ops.
  As an example: one can easily instantiate predict and train nets from
  the same set of layers, where predict net will have subset of the
  operators from train net.
class_docstr_tok: ["Model","helper","for","building","models","on","top","of","layers","abstractions",".","Each","layer","is","the","abstraction","that","is","higher","level","than","Operator",".","Layer","is","responsible","for","ownership","of","it","'s","own","parameters","and","can","easily","be","instantiated","in","multiple","nets","possible","with","different","sets","of","ops",".","As","an","example",":","one","can","easily","instantiate","predict","and","train","nets","from","the","same","set","of","layers",",","where","predict","net","will","have","subset","of","the","operators","from","train","net","."]
docstr: TODO(amalevich): more documnetation on input args
  
  use_attribution:
      if True, will generate the atrribution net for feature importance
      calculation; Need to turn it to false when FC is quantized as FP16
      This attribute access will be consistent with MTML model.
docstr_tok: ["TODO","(","amalevich",")",":","more","documnetation","on","input","args","use_attribution",":","if","True",",","will","generate","the","atrribution","net","for","feature","importance","calculation",";","Need","to","turn","it","to","false","when","FC","is","quantized","as","FP16","This","attribute","access","will","be","consistent","with","MTML","model","."]
code: def __init__(
      self,
      name,
      input_feature_schema,
      trainer_extra_schema,
      keep_blobs=False,
      use_attribution=True,
  ):
      """TODO(amalevich): more documnetation on input args
  
      use_attribution:
          if True, will generate the atrribution net for feature importance
          calculation; Need to turn it to false when FC is quantized as FP16
          This attribute access will be consistent with MTML model.
      """
  
      super().__init__(name=name)
      self._layer_names = set()
      self._layers = []
      self._param_to_shape = {}
  
      # seed default
      self._seed = None
      self._sequence_seed = True
  
      # optimizer bookkeeping
      self.param_to_optim = {}
      self.param_to_reg = {}
  
      self._default_optimizer = None
      self._loss = None
      self._prediction = []
      self._output_schema = None
  
      self._post_grad_net_modifiers = []
      self._final_net_modifiers = []
  
      # breakdown map; breakdown features are categorical (like dense) but not
      # necessarily used to represent data for training
      self._breakdown_map = None
  
      # Connect Schema to self.net. That particular instance of schmea will be
      # use for generation of the Layers across the network and would be used
      # for connection with Readers.
      self._input_feature_schema = (
          schema.NewRecord(self.net, input_feature_schema)
          if not keep_blobs
          else input_feature_schema.clone()
      )
      self._trainer_extra_schema = (
          schema.NewRecord(self.net, trainer_extra_schema)
          if not keep_blobs
          else trainer_extra_schema.clone()
      )
      self._metrics_schema = schema.Struct()
  
      self._preproc_output_schema = None
  
      self._init_global_constants()
      self.param_init_net = self.create_init_net("param_init_net")
      self._initialize_params = True
  
      self._transfer_learning_blob_name_mappings = None
  
      # additional (hard-coded) diagnose_options to report based on the model
      # TODO(xlwang): it's hack!
      self.ad_hoc_diagnose_blobs_and_operations = []
      self.ad_hoc_plot_blobs = []
      self.use_attribution = use_attribution
  
imports: from caffe2.python import core, model_helper, schema, scope, utils, muji
  from caffe2.python.modeling.parameter_info import ParameterInfo
  from caffe2.python.modeling.parameter_sharing import parameter_sharing_context
  from caffe2.python.modeling.net_modifier import NetModifier
  from caffe2.python.optimizer import get_param_device, Optimizer
  from caffe2.python.regularizer import Regularizer, RegularizationBy
  from caffe2.python.layers import layers
  import logging
  import numpy
  import copy
label_desc: Use image node_id 1 to create a new LayerModelHelper object from inherited base classes: model_helper with example: obj = LayerModelHelper(name, input_feature_schema, trainer_extra_schema, keep_blobs, use_attribution)