Basically the only time you'll want to do this from Python is if there is specific Fortran or C++ library you want to use. You'd have to do the same in Swift or Julia in this case.
It's kind of a silly point to try to score: "it's possible to write an efficient deep learning library in Julia (although no one has done it yet), and yes, you can do the same in Numpy in Python, and XLA in Python will outpeform it, but someone else wrote some C/C++ there to make that possible!"
You are much more likely to want to write CUDA kernels (in C!) than you are to write C framework code to interface with Python for machine learning.
The person is looking to "get into ML". I've been working as a professional ML developer for 6 years, and I've never written any C or C++ for it.
This may be generally true (though the benchmarks I've seen show Knet.jl and sometimes Flux.jl on par with TF/PyTorch with a single machine + single GPU), but there are definitely domains where it is categorically not. The most prominent one is neural *DEs, where the SciML [1] ecosystem has SOTA performance. You can really see Python/C++-based frameworks struggle here because they have slow "glue code" and don't (one could argue can't effectively) optimize for latency. That's not a problem for most CV models and transformers, but really stunts research into more dynamic approaches.
I started looking for benchmarks (because it sounds like the kind of thing JAX would do well) and the very first link I clicked included:
Wraps for common C/Fortran methods like Sundials and Hairer's radau
which is exactly what was claimed wasn't needed.
Currently Jax has an in-progress stiff ODE solver that's about 200x slower than SciPy
https://github.com/google/jax/issues/3686#issuecomment-65709...
and SciPy (with JIT) is about 50x-100x slower than the pure Julia methods
https://benchmarks.sciml.ai/html/MultiLanguage/wrapper_packa...
so Jax has more than a little bit of a way to go.
Those are exactly the things wrapping fortran and c won't give you
You don't need to learn C/C++ or fortran. I've been working with python and ML for about 4 years and haven't touched any C/C++ or fortran to get work done. I agree that it'd be better if we could do everything with just one language but the truth is that Julia is not that language. It's great for HPC but expressive enough for generic things like Web.
See https://genieframework.com/ and interact.jl
Once it can compile it web assembly (work in progress) it be the obvious choice.
> To me Julia is more to Fortran than Python. And it doesn't have many usages outside numeric programming.
Again, you're making unsubstantiated claims.
> Python is just used to glue everything and provide a nice and rich interface. That's what really matters.
So, now I have to not only learn Python but also Fortran/C++/C because the underlying library that I might want to adapt is written in one of these languages. In Julia the DL library, for example, is written in Julia. What you are claiming is a pro is actually a con.
> Scapping the Web, building rest APIs, Performing Data Analysis, Automation scripts is much easier in Python than Julia or Swift.
That might be true for Swift, but certainly not for Julia.