Skip to content

ZelasYou/Hands-On-GPU-Programming-with-Python-and-CUDA

 
 

Repository files navigation

Hands-On GPU Programming with Python and CUDA

Hands-On GPU Programming with Python and CUDA

This is the code repository for Hands-On GPU Programming with Python and CUDA, published by Packt.

Explore high-performance parallel computing with CUDA

What is this book about?

Hands-On GPU Programming with Python and CUDA hits the ground running: you’ll start by learning how to apply Amdahl’s Law, use a code profiler to identify bottlenecks in your Python code, and set up an appropriate GPU programming environment. You’ll then see how to “query” the GPU’s features and copy arrays of data to and from the GPU’s own memory.

This book covers the following exciting features:

  • Launch GPU code directly from Python
  • Write effective and efficient GPU kernels and device functions
  • Use libraries such as cuFFT, cuBLAS, and cuSolver
  • Debug and profile your code with Nsight and Visual Profiler
  • Apply GPU programming to datascience problems
  • Build a GPU-based deep neuralnetwork from scratch
  • Explore advanced GPU hardware features, such as warp shuffling

If you feel this book is for you, get your copy today!

https://www.packtpub.com/

Instructions and Navigations

All of the code is organized into folders. For example, Chapter02.

The code will look like the following:

cublas.cublasDestroy(handle)
print 'cuBLAS returned the correct value: %s' % np.allclose(np.dot(A,x), y_gpu.get())

Following is what you need for this book: Hands-On GPU Programming with Python and CUDA is for developers and data scientists who want to learn the basics of effective GPU programming to improve performance using Python code. You should have an understanding of first-year college or university-level engineering mathematics and physics, and have some experience with Python as well as in any C-based programming language such as C, C++, Go, or Java.

With the following software and hardware list you can run all code files present in the book (Chapter 1-12).

Software and Hardware List

Chapter Software required OS required
1-11 Anaconda 5 (Python 2.7 version) Windows, Linux
2-11 CUDA 9.2, CUDA 10.x Windows, Linux
2-11 PyCUDA (latest) Windows, Linux
7 Scikit-CUDA (latest) Windows, Linux
2-11 Visual Studio Community 2015 Windows
2-11 GCC, GDB, Eclipse Linux
Chapter Hardware required OS required
1-11 64-bit Intel/AMD PC Windows, Linux
1-11 4 Gigabytes RAM Windows, Linux
2-11 NVIDIA GPU (GTX 1050 or better) Windows, Linux

We also provide a PDF file that has color images of the screenshots/diagrams used in this book. Click here to download it.

Related products

Get to Know the Author

Dr Brian Tuomanen has been working with CUDA and general-purpose GPU programming since 2014. He received his bachelor of science in electrical engineering from the University of Washington in Seattle, and briefly worked as a software engineer before switching to mathematics for graduate school. He completed his PhD in mathematics at the University of Missouri in Columbia, where he first encountered GPU programming as a means for studying scientific problems. Dr. Tuomanen has spoken at the US Army Research Lab about general-purpose GPU programming and has recently led GPU integration and development at a Maryland-based start-up company. He currently works as a machine learning specialist (Azure CSI) for Microsoft in the Seattle area.

Suggestions and Feedback

Click here if you have any feedback or suggestions.

About

Hands-On GPU Programming with Python and CUDA, published by Packt

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Python 92.0%
  • Cuda 7.5%
  • Batchfile 0.5%