docstr: calculates yingram from raw audio (multi segment)
  
  Args:
      x: raw audio, torch.Tensor of shape (t)
      W: yingram Window Size
      tau_max:
      fs: sampling rate
      w_step: yingram bin step size
  
  Returns:
      yingram: yingram. torch.Tensor of shape (80 x t')
docstr_tok: ["calculates","yingram","from","raw","audio","(","multi","segment",")","Args",":","x",":","raw","audio",",","torch.Tensor","of","shape","(","t",")","W",":","yingram","Window","Size","tau_max",":","fs",":","sampling","rate","w_step",":","yingram","bin","step","size","Returns",":","yingram",":","yingram",".","torch.Tensor","of","shape","(","80","x","t","'",")"]
code: def yingram(self, x: torch.Tensor):
      """calculates yingram from raw audio (multi segment)
  
      Args:
          x: raw audio, torch.Tensor of shape (t)
          W: yingram Window Size
          tau_max:
          fs: sampling rate
          w_step: yingram bin step size
  
      Returns:
          yingram: yingram. torch.Tensor of shape (80 x t')
  
      """
      # x.shape: t -> B,T, B,T = x.shape
      B, T = x.shape
      w_len = self.W
  
      frames = self.unfold(x.view(B, 1, 1, T))
      frames = (
          frames.permute(0, 2, 1).contiguous().view(-1, self.W)
      )  # [B* frames, W]
      # If not using gpu, or torch not compatible,
      # implemented numpy batch function is still fine
      dfs = differenceFunctionTorch(
          frames, frames.shape[-1], self.tau_max
      )
      cmndfs = cumulativeMeanNormalizedDifferenceFunctionTorch(
          dfs, self.tau_max
      )
      yingram = self.yingram_from_cmndf(cmndfs)  # [B*frames,F]
      yingram = yingram.view(B, -1, self.len_midis).permute(
          0, 2, 1
      )  # [B,F,T]
      return yingram
  
file_path: espnet/espnet2/tts/feats_extract/ying.py
imports: import math
  from typing import Any, Dict, Tuple, Union
  import torch
  from espnet2.tts.feats_extract.abs_feats_extract import AbsFeatsExtract
  from espnet2.tts.feats_extract.yin import *
  from espnet.nets.pytorch_backend.nets_utils import pad_list
label_desc: Use image node_id 6 for calling the Ying obj's underlying member method code with example usage: obj.yingram(x) and returns: yingram