I came across the Python library libgpuarray and was reading about it but could not really understand what a GPU array is and why do we need it? What is the difference between a normal array and GPU array?
Please excuse the noobness of the question.
I came across the Python library libgpuarray and was reading about it but could not really understand what a GPU array is and why do we need it? What is the difference between a normal array and GPU array?
Please excuse the noobness of the question.
Libgpuarray is package (like in proxy or wrapper) around cuda and opencl ndarray - meaning that computation is done on device side (GPU side) as opposed to host side (CPU).
This is described in documentation, and also defined what were the goals of this particular library.
It makes sense to talk about "faster" in terms of GPU if we are having a lot of data, which can be solved on different threads or vectorised (SIMT - new to Flynn taxonomy due to massive parallel but limited computation).
Strictly sequential algorithms benefit nothing, CPU has higher power for them, because GPU cores are slower.
It is not like it is fancy to compute on GPU disregarding problem statement.
On GPU you have smaller and constrainef memory, you have to take bandwidth (sending data from host to device, computation time and sending results from device to host) ti know whether there is speed up or slow down effect on your program.
Most probably, a GPU array is an array which is stored and processed on the GPU. Operations on the GPU are faster than those on the CPU, which is why you'd want to use such an array.