code: def _fetch_cpu(
      indices, tensor, feature_shape, device, pin_memory, **kwargs
  ):
      result = torch.empty(
          indices.shape[0],
          *feature_shape,
          dtype=tensor.dtype,
          pin_memory=pin_memory,
      )
      torch.index_select(tensor, 0, indices, out=result)
      kwargs["non_blocking"] = pin_memory
      result = result.to(device, **kwargs)
      return result
  
file_path: dgl/python/dgl/storages/pytorch_tensor.py
imports: import torch
  from ..utils import gather_pinned_tensor_rows
  from .base import register_storage_wrapper
  from .tensor import BaseTensorStorage
label_desc: Use image node_id 1 for calling a global function with example usage: _fetch_cpu(indices, tensor, feature_shape, device, pin_memory) and returns: result