For ML you really need both a class on probability theory, linear algebra, and/or a dedicated ML class. Lots of ML math ends up being the same principals over and over again. They may be borrowed from bigger subject matter, but often times you don't need to be an expert in those to get far. That said, if you're an ML researcher, then you definitely benefit from a very solid math/physics background. But if you're an ML researcher, chances are you did not only undergrad but a PhD as well, and you're not just considering an online certificate.