code: def test_issue564():
      import torch
  
      if CupyOps.xp is not None:
          ops = CupyOps()
          t = torch.zeros((10, 2)).cuda()
          a = ops.asarray(t)
  
          assert a.shape == t.shape
          ops.xp.testing.assert_allclose(
              a,
              ops.alloc2f(10, 2),
          )
  
imports: import pytest
  from thinc.api import CupyOps
  from thinc.compat import has_torch, has_torch_cuda_gpu
label_desc: Use image node_id 1 for calling a global function with example usage: test_issue564() without return types