artyom-beilis / pytorch_dlprim

DLPrimitives/OpenCL out of tree backend for pytorch
http://blog.dlprimitives.org/
MIT License
264 stars 17 forks source link

FAQ: Can I use this as a drop in replacement for pytorch? #11

Closed trholding closed 1 year ago

trholding commented 1 year ago

Awesome work. I have question. Can this be used as a drop in replacement for pytorch?

My expectation is that it would work nice on systems that don't have cuda, but where opencl is supported (AMD,ARM).

I also hope that it will be able change lines like these:

checkpoint = load_checkpoint(pth, torch.device("cuda")) or checkpoint = load_checkpoint(pth, torch.device("cpu")) to

checkpoint = load_checkpoint(pth, torch.device("opencl"))

Please let me know, would love to build and try.

artyom-beilis commented 1 year ago

Yes.

However it is early version and lot of the operator/functions aren't implemented yet.