Pages

Categories

Pytorch OpenCL backend - simplified

10/27/22, by artyom ; Posted in: Releases; 0 comments

Now installation of opencl backend for pytorch is really simple.

  1. Install nighly version of pytorch for CPU in virtual environment
  2. Clone dlrpim_backend repository and checkout true_out_of_tree_support branch
  3. Update submodules
  4. Run few commands inside repo

     mkdir build
     cd build
     cmake -DCMAKE_PREFIX_PATH=$VIRTUAL_ENV/lib/python3.8/site-packages/torch/share/cmake/Torch ..
     make
     cd ..
    
  5. Run mnist training:

     python mnist.py --device=ocl:0
    

That's it.

Keep updated

Add Comment:

 
 the email would not displayed
 

You can write your messages using Markdown syntax.

You must enable JavaScript in order to post comments.