code: def _send_tensors_to_device(self, device: str):
      self.predictions = self.predictions.to(device)
      self.gold_indices = self.gold_indices.to(device)
      self.label_predictions = self.label_predictions.to(device)
      self.gold_labels = self.gold_labels.to(device)
      self.mask = self.mask.to(device)
  
file_path: allennlp/tests/training/metrics/attachment_scores_test.py
imports: from typing import Any, Dict, List, Tuple, Union
  import torch
  from allennlp.common.testing import AllenNlpTestCase, multi_device, run_distributed_test, global_distributed_metric
  from allennlp.training.metrics import AttachmentScores
label_desc: Use image node_id 2 for calling the AttachmentScoresTest obj's underlying member method code with example usage: obj._send_tensors_to_device(device) without return types