I am planning to do my PhD in machine learning. From my personal experience, I found that mathematics is a primary way to make a good research, but I'm doubting about the depth of mathematics required. Most of the impressive inventions in most of the computer science domains comes from mathematics only. But if I spend most of my time in learning mathematics, then I may end up with wasting my time. So, how much depth of mathematics is recommended to carry my PhD? Shall I study only books on machine learning or core mathematics also?