class_docstr: This model extracts X-vectors for speaker recognition
  
  Arguments
  ---------
  activation : torch class
      A class for constructing the activation layers.
  tdnn_blocks : int
      Number of time-delay neural (TDNN) layers.
  tdnn_channels : list of ints
      Output channels for TDNN layer.
  tdnn_kernel_sizes : list of ints
      List of kernel sizes for each TDNN layer.
  tdnn_dilations : list of ints
      List of dilations for kernels in each TDNN layer.
  lin_neurons : int
      Number of neurons in linear layers.
  
  Example
  -------
  >>> compute_xvect = Xvector()
  >>> input_feats = torch.rand([5, 10, 40])
  >>> outputs = compute_xvect(input_feats)
  >>> outputs.shape
  torch.Size([5, 1, 512])
docstr: Returns the x-vectors.
  
  Arguments
  ---------
  x : torch.Tensor
docstr_tok: ["Returns","the","x-vectors",".","Arguments","--","--","--","--","-","x",":","torch.Tensor"]
code: def forward(self, x, lens=None):
      """Returns the x-vectors.
  
      Arguments
      ---------
      x : torch.Tensor
      """
  
      for layer in self.blocks:
          try:
              x = layer(x, lengths=lens)
          except TypeError:
              x = layer(x)
      return x
  
file_path: speechbrain/templates/hyperparameter_optimization_speaker_id/custom_model.py
imports: import torch
  import torch.nn
  import speechbrain
  from speechbrain.nnet.pooling import StatisticsPooling
  from speechbrain.nnet.CNN import Conv1d
  from speechbrain.nnet.linear import Linear
  from speechbrain.nnet.normalization import BatchNorm1d
label_desc: Use image node_id 2 for calling the Xvector obj's underlying member method code with example usage: obj.forward(x, lens) and returns: x