class_docstr: Test class for `PearsonsContingencyCoefficient` metric.
class_docstr_tok: ["Test","class","for","`","PearsonsContingencyCoefficient","`","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_pearsons_t_differentiability(self, preds, target):
      """Test the differentiability of the metric, according to its `is_differentiable` attribute."""
      metric_args = {"num_classes": NUM_CLASSES}
      self.run_differentiability_test(
          preds,
          target,
          metric_module=PearsonsContingencyCoefficient,
          metric_functional=pearsons_contingency_coefficient,
          metric_args=metric_args,
      )
  
file_path: torchmetrics/tests/unittests/nominal/test_pearson.py
imports: import itertools
  import operator
  import pandas
  import pytest
  import torch
  from lightning_utilities.core.imports import compare_version
  from scipy.stats.contingency import association
  from torchmetrics.functional.nominal.pearson import pearsons_contingency_coefficient, pearsons_contingency_coefficient_matrix
  from torchmetrics.nominal.pearson import PearsonsContingencyCoefficient
  from unittests import BATCH_SIZE, NUM_BATCHES, _Input
  from unittests.helpers.testers import MetricTester
label_desc: Use image node_id 3 for calling the TestPearsonsContingencyCoefficient obj's underlying member method code with example usage: obj.test_pearsons_t_differentiability(preds, target) without return types