Why python is used in machine learning:
you don't implement a neural net, press a button to feed it sample sets, then press another button to get the desired informations. It's a hard task which involves a lot of readjustments.
And here comes Python into play. With python it's relatively easy to modify a huge codebase.
If a setup is showing good results you can get a better performance when rebuilding it in c++
tldr: machine learning uses python mainly for prototyping benefits