class_docstr: This lobe enables the integration of use of weighted sum representations
  from different layers in a SSL encoder.
  
  The model can be used as a fixed feature extractor for SSL benchmarking. It
  will download automatically the model from HuggingFace or use a local path.
  
  More details in recipes/SSL_benchmark
  
  Arguments
  ---------
  hub : str
      HuggingFace hub name: e.g "facebook/wav2vec2-large-lv60"
  layernorm: bool, (default: False)
      Whether layer representations should be layernormed before sum
  
  Example
  -------
  >>> inputs = torch.rand([10, 600])
  >>> model_hub = "facebook/wav2vec2-base-960h"
  >>> model = WeightedSSLModel(model_hub)
  >>> outputs = model(inputs)
docstr: If the config needs to be overrided, here is the place
  
  Arguments
  ---------
  config : Wav2Vec2Config
      The original config needs to be overrided.
  
  Returns
  -------
  Overridded config
docstr_tok: ["If","the","config","needs","to","be","overrided",",","here","is","the","place","Arguments","--","--","--","--","-","config",":","Wav2Vec2Config","The","original","config","needs","to","be","overrided",".","Returns","--","--","--","-","Overridded","config"]
code: def override_config(self, config):
      """If the config needs to be overrided, here is the place
  
      Arguments
      ---------
      config : Wav2Vec2Config
          The original config needs to be overrided.
  
      Returns
      -------
      Overridded config
      """
      config.output_hidden_states = True
      return config
  
file_path: speechbrain/speechbrain/lobes/models/huggingface_transformers/weighted_ssl.py
imports: import torch
  import logging
  import torch.nn.functional
  from speechbrain.lobes.models.huggingface_transformers.huggingface import HFTransformersInterface
label_desc: Use image node_id 3 for calling the WeightedSSLModel obj's underlying member method code with example usage: obj.override_config(config) and returns: config