CPUs and GPUs both process data, but they do it in different ways.
To provide a more technical answer requires understanding computer architecture and machine learning, this will be too long of an answer if done in detail.
The CPU processes one instruction at a time through multiple cores can work on the same task for higher throughput (i.e., multitasking). The GPU processes many small tasks in parallel (i.e. doing at once) because its hardware is meant to render graphics to screen quickly; the downside is that it cannot do anything else while rendering graphics to screen quickly, but there are motherboard slots that support multiple PCI-E slots that feature discrete graphic cards that can work like a GPU or like another card to increase performance.