class_docstr: Test class for `SpeechReverberationModulationEnergyRatio` metric.
class_docstr_tok: ["Test","class","for","`","SpeechReverberationModulationEnergyRatio","`","metric","."]
docstr: Test the differentiability of the metric, according to its `is_differentiable` attribute.
docstr_tok: ["Test","the","differentiability","of","the","metric",",","according","to","its","`","is_differentiable","`","attribute","."]
code: def test_srmr_differentiability(self, preds, fs, fast, norm):
      """Test the differentiability of the metric, according to its `is_differentiable` attribute."""
      if fast is True:
          pytest.xfail(
              "SRMR metric is not differentiable when `fast=True`"
          )
      else:
          pytest.xfail(
              "differentiable test for SRMR metric is skipped as it is too slow"
          )
  
imports: from functools import partial
  from typing import Any, Dict
  import pytest
  import torch
  from srmrpy import srmr
  from torch import Tensor
  from torchmetrics.audio.srmr import SpeechReverberationModulationEnergyRatio
  from torchmetrics.functional.audio.srmr import speech_reverberation_modulation_energy_ratio
  from torchmetrics.utilities.imports import _TORCHAUDIO_GREATER_EQUAL_0_10
  from unittests.helpers import seed_all
  from unittests.helpers.testers import MetricTester
label_desc: Use image node_id 3 for calling the TestSRMR obj's underlying member method code with example usage: obj.test_srmr_differentiability(preds, fs, fast, norm) without return types