This could be due to various reasons. Please run your code on the CPU to get a specific error message.