code: def test_torch_metrics_on_gpu(self):
      with torch.cuda.device(MetricsModelIntegrationTest.cuda_device):
          expected_names = ["r2_score", "spearman_corr_coef"]
          model = Model(
              self.pytorch_network,
              self.optimizer,
              self.loss_function,
              batch_metrics=[
                  torchmetrics.R2Score(),
                  torchmetrics.SpearmanCorrCoef(),
              ],
          )
          model.cuda()
          self._test_history(model, expected_names, [ANY, ANY])
  
imports: import os
  import unittest
  from unittest import skipIf
  from unittest.mock import ANY
  import numpy
  import torch
  import torch.nn
  import torchmetrics
  from poutyne import Metric, Model, do_register_metric_class, rename_doubles, unregister_metric_class
label_desc: Use image node_id 25 for calling the MetricsModelIntegrationTest obj's underlying member method code with example usage: obj.test_torch_metrics_on_gpu() without return types