code: def get_mvdr_vector_with_rtf(
      psd_n: torch.Tensor,
      psd_speech: torch.Tensor,
      psd_noise: torch.Tensor,
      iterations: int = 3,
      reference_vector: Union[int, torch.Tensor, None] = None,
      diagonal_loading: bool = True,
      diag_eps: float = 1e-7,
      eps: float = 1e-8,
  ) -> torch.Tensor:
      """Return the MVDR (Minimum Variance Distortionless Response) vector
          calculated with RTF:
  
          h = (Npsd^-1 @ rtf) / (rtf^H @ Npsd^-1 @ rtf)
  
      Reference:
          On optimal frequency-domain multichannel linear filtering
          for noise reduction; M. Souden et al., 2010;
          https://ieeexplore.ieee.org/document/5089420
  
      Args:
          psd_n (torch.complex64):
              observation/noise covariance matrix (..., F, C, C)
          psd_speech (torch.complex64):
              speech covariance matrix (..., F, C, C)
          psd_noise (torch.complex64):
              noise covariance matrix (..., F, C, C)
          iterations (int): number of iterations in power method
          reference_vector (torch.Tensor or int): (..., C) or scalar
          diagonal_loading (bool): Whether to add a tiny term to the diagonal of psd_n
          diag_eps (float):
          eps (float):
      Returns:
          beamform_vector (torch.complex64): (..., F, C)
      """  # noqa: H405, D205, D400
      # (B, F, C)
      rtf = get_rtf(
          psd_speech,
          psd_noise,
          reference_vector=reference_vector,
          iterations=iterations,
          diagonal_loading=diagonal_loading,
          diag_eps=diag_eps,
      )
      return torchaudio.functional.mvdr_weights_rtf(
          rtf,
          psd_n,
          reference_vector,
          diagonal_loading=diagonal_loading,
          diag_eps=diag_eps,
          eps=eps,
      )
  
imports: from typing import List, Union
  import torch
  import torch_complex.functional
  import torchaudio
label_desc: Use image node_id 4 for calling a global function with example usage: get_mvdr_vector_with_rtf(psd_n, psd_speech, psd_noise, iterations, reference_vector, diagonal_loading, diag_eps, eps) and returns: torchaudio