官术网_书友最值得收藏!

Summary

Setting up your Python environment for GPU programming can be a very delicate process. The Anaconda Python 2.7 distribution is suggested for both Windows and Linux users for the purposes of this text. First, we should ensure that we have the correct hardware for GPU programming; generally speaking, a 64-bit Windows or Linux PC with 4 gigabytes of RAM and any entry-level NVIDIA GPU from 2016 or later will be sufficient for our ends. Windows users should be careful in using a version of Visual Studio that works well with both the CUDA Toolkit and Anaconda (such as VS 2015), while Linux users should be particularly careful in the installation of their GPU drivers, and set up the appropriate environment variables in their .bashrc file. Furthermore, Windows users should create an appropriate launch script that will set up their environment for GPU programming and should use a pre-compiled wheel file for the installation of the PyCUDA library.

Now, with our programming environment set up and in place, we will spend the next chapter learning the very basics of GPU programming. We will see how to write and read data to and from the GPU's memory, and how to write some very simple elementwise GPU functions in CUDA C. (If you have seen the classic 1980's film The Karate Kid, then you might think of the following chapter as the "wax on, wax off" of GPU programming.)

主站蜘蛛池模板: 梓潼县| 同江市| 双城市| 来凤县| 台中县| 盐边县| 启东市| 奉节县| 迁西县| 新宁县| 平泉县| 南丰县| 英德市| 克东县| 惠东县| 巫溪县| 襄樊市| 潼关县| 射阳县| 张家界市| 新闻| 浦城县| 五河县| 松阳县| 方山县| 常熟市| 高密市| 滦南县| 泾阳县| 剑川县| 恩平市| 怀宁县| 玉树县| 社旗县| 开原市| 伊吾县| 穆棱市| 牟定县| 文登市| 张家川| 定日县|