docstr: 将张量移到设备上
  
  :param tensor: 需要移动的张量
  :param device: 设备名， 一般为 "cpu", "cuda:0"等字符串
docstr_tok: ["\u5c06\u5f20\u91cf\u79fb\u5230\u8bbe\u5907\u4e0a",":","param","tensor",":","\u9700\u8981\u79fb\u52a8\u7684\u5f20\u91cf",":","param","device",":","\u8bbe\u5907\u540d\uff0c","\u4e00\u822c\u4e3a","``","cpu","''",",","``","cuda:0","''","\u7b49\u5b57\u7b26\u4e32"]
code: def move_tensor_to_device(self, tensor, device):
      """
      将张量移到设备上
  
      :param tensor: 需要移动的张量
      :param device: 设备名， 一般为 "cpu", "cuda:0"等字符串
      """
      return tensor.to(device)
  
file_path: fastNLP/fastNLP/core/metrics/backend/oneflow_backend/backend.py
imports: from typing import List
  import numpy
  from fastNLP.core.metrics.backend import Backend
  from fastNLP.core.metrics.utils import AggregateMethodError
  from fastNLP.core.utils import is_in_oneflow_dist
  from fastNLP.envs.imports import _NEED_IMPORT_ONEFLOW
  from fastNLP.core.drivers.oneflow_driver.dist_utils import fastnlp_oneflow_all_gather
label_desc: Use image node_id 8 for calling the OneflowBackend obj's underlying member method code with example usage: obj.move_tensor_to_device(tensor, device) and returns: tensor