Moved cuda API calls to server class kept kernels in kernel.cu