0

For example, I have a cuda tensor in pytorch, how to directly convert it to mxnet/tensorflow in gpu without copying it to cpu? Frequently copying data between cpu and gpu is very time-consuming.

talonmies
  • 70,661
  • 34
  • 192
  • 269
Meta Fan
  • 1,545
  • 2
  • 17
  • 28

1 Answers1

0

The fastest way would be to use CUDA API for that.

Sharing tensors via PyTorch is only supported on CPU.

And if you would try to do some Python exhibition you will be slow because of GIL.

prosti
  • 42,291
  • 14
  • 186
  • 151