Does anyone use Julia Language?
Posted by Fats_Runyan2020@reddit | learnprogramming | View on Reddit | 16 comments
Been reading about Julia programming language which i have never heard of before nor used.
From what I've read and have asked AI about it:
- Newer language
- Specializing in computation
- Similar syntax to python and matlab
- unique features such as multiple dispatch
- high execution speeds
- etc...
- Does anyone currently use it regularly?
- What has been your experience with it?
- Is it worth learning if you already use python and matlab?
- What's the learning curve like?
- What specifically do you use it for (DSP, Differential EQs, control systems, etc...)?
- general pros and cons about it
WitnessEquivalent793@reddit
Used it briefly for a stats project and the speed difference is real but the ecosystem is nowhere near python yet so the tradeoff depends on what you
Fats_Runyan2020@reddit (OP)
Probably similar to what python was like in the 90s i would guess. 10-20yrs down the road Julia might be more mainstream in some applications
Bob_Dieter@reddit
Julia used to be my main language and my favorite one back in the days, although I rarely get to use it these days anymore. Here are some of my opinions:
On the surface, Julia is a dynamically typed, imperative language that is designed to directly compete with languages like python, R and the lot. However, as you get deeper into it, Julia turns out to fundamentally differ in several aspects to these others.
In a vacuum, Julia is an excellent language, beating other comparable languages by orders of magnitudes, not just in terms of performance, but also expressiveness, flexibility, features and general design.
However, if you are looking for something that's going to be useful on a job application, it does not hold up simply due to the fact that barely anyone outside of universities and research groups uses it.
Getting to the point where you have some running Programm in Julia is very easy by design, the core language features like functions, loops, variables etc work just as you would expect. However, as Julia tries to give the programmer a more powerful and complete toolkit and thus brings a lot more features than, for example, python, it is going to take a bit longer before you can claim to have mastered it. In return, Julia is going to get you further than its competitors if you need it.
Also, I have read others say that Julia is a cross between python and Haskell. As someone with experience in all three of these languages I don't think that's true. Haskell and Julia are very different languages with little overlap.
Alternative_Act_6548@reddit
I've looked at Julia, but don't see what it does better than python/numpy...it certainly has fewer libraries...if it's just speed, then there are ways to improve python performance if needed.
Bob_Dieter@reddit
Python is more popular and has thus more packages and external tooling, yes. Apart from speed, which is always the big ticket reason for julia, there are dozens of small to moderate reasons to prefer it over Python. Here is a random selection:
Julias built-in package manager Pkg is much more reliable (and convenient) than pythons pip, and can help with package creation and management.
Julia is NOT Object Oriented, but instead brings something called multiple dispatch, which, once you "get the hang of it", offers much more flexibility and modularity than OO.
Julia has typed data structures (if you want them) and a type system that actually interfaces with the rest of the language.
A macro system inspired by lisp that allows the programmer to "extend" the language in meaningful ways to fit your custom needs.
Metaprogramming and compile time programming in general, if you're into that stuff.
Many, many small syntactic advantages: much better support for operators, unicode, better syntax for creating named and anonymous functions (multi line anonymous functions!), argument destructuring, broadcasting and much more.
The Base library - what is available if you install the core language and nothing else - is IMO much more organized and complete.
Much better performance - Yes, I said apart from speed , but julias speed has many secondary benefits as well. Python packages that reach a certain critical mass tend to be rewritten in Rust, while Julia packages that reach a certain critical mass tend to be rewritten in pure Julia (if they were'nt to begin with). That means that there is a much higher flexibility and reusability in these systems, since your runtime actually understands what it is importing instead of seeing nothing but a Foreign Function Interface. It also means that it is much easier for the average Julia dev to understand the tools they are using and even contribute, since they tend to be written in their native language.
Better REPL (even though recent python versions are catching up)
These are some of the bigger points I can point out off the top of my hat. There is probably more, but I think this is enough for now.
Fats_Runyan2020@reddit (OP)
Thanks for the in depth response!
Prudent_Candidate566@reddit
It looks like Matlab has kind of a workaround now, but for a while a big advantage of Julia was automatic differentiation.
If you’re doing scientific computing with a lot of partial derivatives, like say a modular Kalman filter, automatic differentiation can save you a ton of time compared to calculating the partials symbolically (either by hand or with Matlab/mathematica) and then implementing that in code. Or suffering the inaccuracies of numerical differentiation.
I’ve also used it in lieu of python for making plots to analyze the performance of C++ real-time algorithms for robotics, which Julia is great for also.
I think it’s definitely worth learning, but only if you’re serious about scientific computing.
Fats_Runyan2020@reddit (OP)
Ok i see. This makes sense
AdventurousLime309@reddit
Yes Julia is used, but mostly in niche, math-heavy domains.
In practice:
Compared to Python:
Learning curve is moderate if you already know Python + MATLAB.
Worth it if you work in research, DSP, physics, control systems, or heavy numerical computing.
Not really worth it for general backend, web dev, or industry-standard tooling.
Fats_Runyan2020@reddit (OP)
Ok thanks for the reply. This seems to be consistent with my reading. What makes it slightly difficult to learn? You said moderate learning curve, so what makes it moderate?
NewRengarIsBad@reddit
Quite popular in academic math circles.
vegan_antitheist@reddit
I've never heard about this. Looks like Python and Haskell merged into one language.
Fats_Runyan2020@reddit (OP)
And I've never heard of haskell either lol
vegan_antitheist@reddit
It's great when you want to learn functional programming. I'm glad I learned it. But I never actually used it.
Fats_Runyan2020@reddit (OP)
Gotcha
Stock-Chemistry-351@reddit
Julia's use is very niche and small compared to Python