Better HN
topnewbestaskshowjobs
Log inSign up

ChrisRackauckas

3,832 karma · joined Oct 6, 2016 (10y ago) · 934 submissions

I am the developer of the SciML Scientific Machine Learning Open Source Software Organization (https://sciml.ai/), an organization for Julia, Python and R packages for integrated, composible, and fast scientific machine learning. I also have used quite a bit of MATLAB, C, and Fortran (well, at least used for numerical work), but these days. I think the purpose of discussing technical topics is the dissemination of ideas, so let's bring each other up not down!
Submissions

1.

The SciML Factory: A New Approach to Agentic Open Source Maintenance(stochasticlifestyle.com ↗)

1 points · by ChrisRackauckas · 5d ago · discuss

comment 1mo ago · link · parent

The book referred to was released in 2022, around the same month as Symbolics.jl, so it wouldn't have existed when the author was writing it.

comment 1mo ago · link · parent

That's a very one dimensional phrasing. Symbolics has a ton of things SymPy doesn't have. SymPy has some things that Symbolics doesn't have. Which one is "better" depends on which things you need to use. SymPy still has a few classic math things that Symbolics doesn't (though some aspects like prime number pieces are deliberately left out because it's covered by other existing Julia packages, and IMO shouldn't be a part of SymPy in the first place), and Symbolics has plenty of things that SymPy doesn't have around optimized codegen and parallelized Groebner basis algorithms.

That said, Symbolics was released in 2022. The thread you posted was from 2022. In 2026, it does support limits (https://github.com/SciML/SymbolicLimits.jl), integrals, (https://docs.sciml.ai/SymbolicIntegration/dev/) etc., and in fact that symbolic integration is much more advanced than SymPy, except on symbolic integration of ODEs (surprisingly, though that has been pretty deliberate since that domain almost never has an analytical solution so it's not the most useful to real practitioners and is more of a teaching tool)

comment 2mo ago · link · parent

They are green too, which means they were just made today. That's a pretty nice HN feature! It shows that there's literally 5 adversarial green sock puppet accounts that were made just to comment in this thread, so almost certainly one person with a grudge who is afraid to make a non-anonymous argument on the merits.

5.

GPT-5.6 vs. Claude Fable 5 for Physical AI, which performs best?(juliahub.com ↗)

1 points · by ChrisRackauckas · 4mo ago · discuss

comment 9mo ago · link · parent

Are you using Polyester.jl? Large numbers of threads are not optimized with Base threads usage due to GC interactions + the hierarchical threading adds overhead vs "unsafe" thread techniques which don't support the worksharing. Polyester is thus required to get very low overhead threading matching performance of non-worksharing scenarios.

7.

Dyad 2.0: What Agentic AI Means for the Future of Computer Languages(juliahub.com ↗)

3 points · by ChrisRackauckas · 9mo ago · discuss

comment 1y ago · link · parent

The caveat to mention here is that this is with the standard IO interface. If you use Core.println instead of println you get something substantially smaller. A limitation of v1.12 is that the handling of IO is not that great, and this is something that IIUC is being addressed in the v1.13 updates.

comment 1y ago · link · parent

No it only uses the same LLVM compiler passes and you enable certain optimizations locally via macros if you want to allow reordering in a given expression.

10.

Agentic AI for Model-Based Engineering: How Dyad Ensures Correctness(juliahub.com ↗)

3 points · by ChrisRackauckas · 1y ago · discuss

comment 1y ago · link · parent

v1.13 already has a good number of improvements to trim in the cases which are less analyzable, but even then I think the best thing for the package ecosystem is to start to become really good for trim, JETLS, etc. through statically checking things.

comment 1y ago · link · parent

We use it for binary deployments via building simulations into the FMI standard (i.e. building FMUs) https://fmi-standard.org/. We still need to get libraries updated for getting the smallest possible trim when using the more computationally difficult implicit methods, but at least the stack is matured for simple methods like explicit RK and Rosenbrock-type solvers already. For folks interested in --trim on SciML, the PR to watch is https://github.com/SciML/NonlinearSolve.jl/pull/665 which is currently held up by https://github.com/SciML/SciMLBase.jl/pull/1074 which is the last remaining nugget to get the vast majority of the SciML solver set trimming well. So hopefully very soon for anyone interested in this part of the world. Note that does not include inverse problems in the binary as part of small trim.

But all of this is more about maturing the ecosystem to be more amenable to static compilation and analysis. The whole SciML stack had an initiative starting at the beginning of this summer to add JET.jl testing for type inference everywhere and enforcing this to pass as part of standard unit tests, and using AllocCheck.jl for static allocation-free testing of inner solver loops. With this we have been growing the surface of tools that have static and real-time guarantees. Not done yet, some had to be marked as `@test_broken` for having some branch that can allocate if condition number hits a numerical fallback and such, but generally it's getting locked down. Think of it as "prototype in Julia, deploy in Rust", except instead of re-writing into Rust we're just locking down the behavior with incrementally enforcing the package internals to satisfy more and more static guarantees.

comment 1y ago · link · parent

Julia v1.12, the unreleased version which is currently in release candidate stage (and has had a longer RC stage than expected but should be done at least by the end of the year) has the ability to fully ahead of time compile and generate binaries, like you would expect from a language like C. It also trims these binaries so that they are a reasonable size given the elements of the runtime that are used. Thus for good type-stable code you get callable binaries without JIT overhead, and this leads to a much better CLI experience. It will take a bit of time so that there's more package tooling and support built around this feature, but this is the path a lot of the ecosystem CLI tooling is now going and that will be a pretty dramatic shift in the usability for these kinds of use cases which Julia had traditionally ignored.

comment 1y ago · link · parent

This has nothing to do with floating point error accumulation or numerical stability in the floating point sense. You can do this with arbitrary sized floating point values and you will still get the same non-convergence result.

comment 1y ago · link · parent

This tool already exists in Python and R. See https://cran.r-project.org/web/packages/diffeqr/index.html and https://anaconda.org/conda-forge/diffeqpy. Julia has language bindings that make it simple enough to bind to other high level languages that these projects are maintained by the core team and supports lots of the library, including forms of automatic differentiation and GPU kernel generation. See for example the bindings that allow for usage within PyTorch https://github.com/SciML/juliatorch and the Python-based Collab notebooks showing the GPU usage https://colab.research.google.com/drive/1bnQMdNvg0AL-LyPcXBi....

With Julia v1.12's small binary generation, we plan to release forms via binaries with C ABIs over the next year as well.

Are those sufficient or should we consider supporting other deployments?

comment 1y ago · link · parent

Interesting to see this here! This example is one of the ones mentioned in the appendix of https://arxiv.org/abs/2406.09699, specifically "4.1.2.4 When AD is algorithmically correct but numerically wrong".

If people want a tl;dr, the main idea is you can construct an ODE where the forward pass is trivial, i.e. the ODE solution going forwards is exact, but its derivative is "hard". An easy way to do this is to make it so you have for example `x' = x - y, y' = y - x`, with initial conditions x(0)=y(0). If you start with things being the same value, then the solution to the ODE is constant since `x' = y' = 0`. But the derivative of the ODE solution with respect to its initial condition is very non-zero: a small change away from equality and boom the solution explodes. You write out the expression for dy(t)/dy(0) and what you get is a non-trivial ODE that has to be solved.

What happens in this case though is that automatic differentiation "runs the same code as the primal case". I.e., automatic differentiation has the property that it walks through your code and differentiates the steps of your code, and so the control flow always matches the control flow of the non-differentiated code, slapping the derivative parts on each step. But here the primal case is trivial, so the ODE solver goes "this is easy, let's make dt as big as possible and step through this easily". But this means that `dt` is not error controlled in the derivative (the derivative, being a non-trivial ODE, needs to have a smaller dt and take small steps in order to get an accurate answer), so the derivative then gets error due to this large dt (or small number of steps). Via this construction you can make automatic differentiation give as much error as you want just by tweaking the parameters around.

Thus by this construction, automatic differentiation has no bound to the error it can give, and no this isn't floating point errors this is strictly building a function that does not converge to the correct derivative. It just goes to show that automatic differentiation of a function that computes a nice error controlled answer does not necessarily give a derivative that also has any sense of error control, that is a property that has to be proved and is not true in general. This of course is a bit of a contrived example to show the point that the error is unbounded, but then it points to real issues that can show up in user code (in fact, this example was found because a user opened an issue with a related model).

Then one thing that's noted in here too is that the Julia differential equation solvers hook into the AD system to explicitly "not do forward-mode AD correctly", incorporating the derivative terms into the time stepping adaptivity calculation, so that it is error controlled. The property that you get is that for these solvers you get more steps to the ODE when running it in AD mode than outside of AD mode, and that is a requirement if you want to ensure that the user's tolerance is respected. But that's explicitly "not correct" in terms of what forward-mode AD is, so calling forward-mode AD on the solver doesn't quite do forward mode AD of the solver's code "correctly" in order to give a more precise solution. That of course is a choice, you could instead choose to follow standard AD rules in such a code. The trade-off is between accuracy and complexity.

comment 1y ago · link · parent

B-S is just a (bad) explicit Runge-Kutta method. You can see this formally since if you take any order of the B-S method, you can write out its computation as a Runge-Kutta tableau. If you do this, you'll see it ends up being an explict RK method that has much higher f evaluations to achieve the leading truncation error coefficients and order that the leading RK methods get. For example, 9th order B-S uses IIRC about 2-3 times as many f evaluations as Vern9, while Vern9 gets like 3 orders of magnitude less error (on average w.r.t. LTE measurements). If you're curious about details of optimizing RK methods, check out https://www.youtube.com/watch?v=s_t6dIKjUUc.

That isn't to say B-S methods aren't worth anything. The interesting thing is that they are a way to generate arbitrary order RK methods (even if no specific order is efficient, it gives a general scheme) and these RK methods have a lot of parallelism that can be exploited. We really worked through this a few years ago building parallelized implementations. The results are here: https://ieeexplore.ieee.org/abstract/document/9926357/ (free version https://arxiv.org/abs/2207.08135) and are part of the DifferentialEquations.jl library. The results are a bit mixed though, which is why they aren't used as the defaults. For non-stiff equations, even with parallelism it's hard to ever get them to match the best explicit RK methods, they just aren't efficient enough.

For stiff equations, if you are in the regime where BLAS does not multithread yet (basically <256 ODEs, so 256x256 LU factorizations but this is BLAS/CPU-dependent), then you can use parallelization in the form of the implicit extrapolation methods in order to factorize different matrices at the same time. Because you're doing more work than something like an optimized Rosenbrock method, you don't get strictly better, but using this to get a high order method that exploits parallelism where other methods end up being serial, you can get a good 2x-4x if you tune the initial order and everything well. This is really nice because 4 ODEs - 200 ODEs, where this ends up being the fastest method for stiff ODEs that we know of right now according to the SciMLBenchmarks https://docs.sciml.ai/SciMLBenchmarksOutput/stable/, and this ends up being a sweet spot where "most" user code online tends to be. However, since it does require tuning a bit to your system, setting threads properly, having your laptop plugged in, using more memory, and possibly upping the initial order manually, it's not the most user-friendly method. Therefore it doesn't make a great default since you're putting a lot more dependencies into the user's mind for a 2x-4x... but it's a great option to have for the person really trying to optimize. This also shows different directions that would be more fruitful and beat this algorithm pretty handedly though... but that research is in progress.

comment 1y ago · link · parent

The whole point of the article is that "methods are considered more robust and practical if they have larger stability regions" isn't (or at least shouldn't be) necessarily true :-/.

comment 1y ago · link · parent

Yeah, that's a separate post https://scicomp.stackexchange.com/questions/29149/what-does-.... I wanted to keep this post as simple as possible. If you could show cases where explicit Runge-Kutta methods outperform (by some metrics) implicit Runge-Kutta methods, then it leads to a whole understanding of "what matters is what you're trying to measure". And then yes, symplectic integrators are for long time integrations (explicit RK methods will how lower error for shorter time, so its specifically longer time integrations on symplectic manifolds, though there are implicit RK methods which are symplectic but ... tradeoff tradeoff)

20.

Why No Ode Solver Is Best(stochasticlifestyle.com ↗)

2 points · by ChrisRackauckas · 1y ago · discuss

comment 1y ago · link · parent

I mean this for simple devops tasks, like if you need it to write you a Bash script that will clean out some empty caches or something it will one shot it most of the time. And for figuring out standard tasks like setting up deploy keys for some new doc system or updating the make files to handle some new build dependency. I still have devops engineers for anything difficult, but they get pestered with a lot less things they would find trivial that the rest of the teams would have asked them for help on before.

comment 1y ago · link · parent

The part that made it much more feasible is that WASM's "new" GC ended up working nicely with Julia's GC, so WebAssemblyCompiler.jl was able to hook into it. With that, a lot more codes suddenly work because array allocations are fine. It means that in this state if someone took it seriously I think a pretty good version could be had in like 6 months, but it would take a real effort to make that something actually part of the "normal" maintained compiler stack.

comment 1y ago · link · parent

Yeah the WebAssemblyCompiler.jl works on things that are StaticCompiler-able https://tshort.github.io/WebAssemblyCompiler.jl/stable/examp..., plus a little bit more since it supports the GC. It's not an "official" compiler and it has some things that mean it's on the "not really maintained list", but it shows it's not too difficult. You can also just retarget LLVM yourself to WASM (it's just a backend of LLVM) without too much difficulty if you're using a limited part of the Julia runtime. So... with a bit of effort a good chunk of the language could do this, we just haven't had much of the effort since most of it has been going towards AOT binary building.

comment 1y ago · link · parent

I'm sure there's lots of slop being generated by this stuff, but at least for my work it's mostly solving the simple issues. Maybe it's the slop of "hey can you find out why my code isn't working?" and "closed issue 268 because it works on the latest versions, and we made your code into an MWE for the future". If you check any open source project that gets traction, there's tens of thousands of issues to handle. A good thousand of them are just "unit conversion would be good here", "this docstring is missing this option", etc. Those little PRs are the slop of Github that someone has to do, and I'd prefer not telling my interns to do that because otherwise they'd just quit. Good thing Claude doesn't quit, he's a good boy.

comment 1y ago · link · parent

Notice that the examples I show are very minimal changes. If you prompt it to solve the right problems which involves minimal code, then the diffs are easy to manage. There are lots of problems like this. Leave the hard ones for yourself. The only big diff it should ever make is for a refactor.

comment 1y ago · link · parent

The same $200/month Max plan as anyone else. It just gets rate limited sometimes but who cares, you just go back to the fun part of doing your own coding until it's back.

comment 1y ago · link · parent

> I really think there needs to be a different term for professional solution engineering using LLMs (like "prompt engineering" but for coding) to differentiate from casual prototyping or simple web UI hacking by non-devs that uses "vibe" coding.

Yeah, maybe it needs another name because yes when you say you're vibe coding everyone imagines some 20 year old kid with sunglasses spitting out Javascript and calling it Python. While the tools are the same, the understanding and the discipline is very different.

I think "tech lead managing offshore development" is an excellent analogy.

comment 1y ago · link · parent

> If you don’t mind the engineering skills atrophy then go ahead and vibe code. But know this. You will lose the skills.

I don't see why it's an either or. As explained in the article, I'm still coding all day. Just some trivial PRs are getting done and tidied up while I'm doing so. You still have to do all of the code review, and you still have to solve all of the hard problems, you just do less of the refactoring by hand.

comment 1y ago · link · parent

> More worryingly, something I don't see discussed enough is "review fatigue". It's far more fatiguing reviewing the output of an LLM than writing the code yourself a lot of the times. Early on in your career, this might lead to the tendency to just say "eh, looks alright enough".

I am definitely worried about that. I got into a mode of doing morning code review every morning due to having a bunch of active open source repos, so over time as they grow in activity I learned to adapt my schedule, mind set, and everything around how to do the right amount of code review (when to finish the PR yourself, when to give pointers to train a new contributor, when it's not worth your time yet to say more than "tests fail", etc.). I started for years pulling every piece of code locally, running it, figuring out why someone would make a change like that, etc. and then it took like 5 years before I could actually start to do code review well just by reading a git diff. I needed to know the domain, the language, the problem space, and how people tend to work, all well enough to make that simple enough to have a mental model.

Then, I tend to see some junior programmers put up LLM stuff and I go "oh just handle the extra memory allocations and it's good to go" and they go "wait handle what where?". If you can't eyeball that in under a minute of scrolling through the code... then you shouldn't be doing code review by scrolling through it yet. But if they keep doing it like this, they will never build that skill.

That's why I think the right LLM usage is really for those who have already built that code review skill. It's not to gate the usage of LLMs, but people will never learn if they aren't strongly engaging with the code at some level.

comment 1y ago · link · parent

Hey, definitely agree in many respects! I have been programming for over a decade because I love to. And the worst part the job has always been giving feedback to a student/engineer who clearly just doesn't care and makes the same mistake again, like why should I keep reading your code instead of working on the fun hard problem I've been wanting to?

But, what I found over time is that as my role grew, the amount of work that could be done grew exponentially. In grad school I had one project to work on, by postdoc there was 10 papers that could be juggled, now there's so many different projects/collaborations/contracts/etc. that I could be a part of that it's all just a matter of "do I have time for that?". Then the team sizes start to grow: having one student turns into 5, into a lab, into a team at one company, then a growing team at another, and an open source organization. In one decade life changed from "wake up, figure out what to program, make it" to "wake up, see the deluge of issues and PRs, start code review, try to get that done so I can start 'my' day", and I think most people in programming tend to have a trajectory like that. The role changes from "build something" to "find out where others are getting stuck and unblock them", plus 200+ issues files about trivial shit. The goal here is to to have the LLMs handle the trivial shit, I unblock someone, and then finally the glory hour of me getting to build something is back!

But I think this is why there are lots of very smart people who have decided they wanted to be individual contributors in Silicon Valley instead. And they are really well-respected, and you want them in your squad! If that's the direction you want to go, then you probably also are of the kind that avoids LLMs a bit (and are thus a good person to have on a team, balancing velocity people with precision people). But if you want to start driving bigger projects, sooner or later teams grow as that's the only way to put out the bigger grander idea.

But I do think that if Anthropic made a Claude stuffed animal with a very punchable face it would be a very hot selling add-on as while this can accelerate the day, sometimes it makes the stupidest decisions and you really have to think "okay it doesn't hate me, it's not trying to spite me, it doesn't even know me, but damn it tried to hide that it commented out the one most crucial test!"

12345
32