docstr: TensorFlow model is assigned weights from `net_params` dictionary.
  `net_params` contains weights in CoreML format. The dense layers
  need to be transposed to match TF format.
docstr_tok: ["TensorFlow","model","is","assigned","weights","from","`","net_params","`","dictionary",".","`","net_params","`","contains","weights","in","CoreML","format",".","The","dense","layers","need","to","be","transposed","to","match","TF","format","."]
code: def load_weights(self, net_params):
      """
      TensorFlow model is assigned weights from `net_params` dictionary.
      `net_params` contains weights in CoreML format. The dense layers
      need to be transposed to match TF format.
  
      """
      _tf = _lazy_import_tensorflow()
      with self.sc_graph.as_default():
          weights, biases = {}, {}
          for cur_name, cur_layer in net_params["data"].items():
              if "bias" in cur_name:
                  biases[cur_name] = _tf.Variable(
                      cur_layer.astype("float32"), name=cur_name
                  )
              else:
                  assert "weight" in cur_name
                  weights[cur_name] = _tf.Variable(
                      cur_layer.transpose(1, 0).astype("float32"),
                      name=cur_name,
                  )
  
          self.x = _tf.placeholder("float", [None, self.num_inputs])
          (
              self.predictions,
              _,
          ) = SoundClassifierTensorFlowModel._build_network(
              self.x, weights, biases
          )
  
          self.sess.run(_tf.global_variables_initializer())
  
      self.is_initialized = True
  
file_path: turicreate/src/python/turicreate/toolkits/sound_classifier/_tf_sound_classifier.py
imports: from __future__ import print_function
  from __future__ import division
  from __future__ import absolute_import
  from .._tf_model import TensorFlowModel
  import turicreate.toolkits._tf_utils
  from turicreate._deps.minimal_package import _minimal_package_import_check
label_desc: Use image node_id 11 for calling the SoundClassifierTensorFlowModel obj's underlying member method code with example usage: obj.load_weights(net_params) without return types