AlexTCH
330 subscribers
83 photos
4 videos
2 files
941 links
Что-то про программирование, что-то про Computer Science и Data Science, и немного кофе. Ну и всякая чушь вместо Твиттера. :)
Download Telegram
As a counterpoint to the kinda famous (in certain circles) Xtext Language Workbench for Java, Python folks made textX. Mainly it provides an AST and parser generation from a single declarative description. And some support for implementing scopes and name resolution, and VS Code integration.

There's a pretty detailed tutorial from Struments: https://tomassetti.me/domain-specific-languages-in-python-with-textx/
🔥2😁1
https://statmodeling.stat.columbia.edu/2024/02/06/ive-been-mistaken-for-a-chatbot/

When anonymous peer-reviewers (and an editor) think you're a ChatGPT...
😁1
https://github.com/attractivechaos/plb2

Yet Another Programming Languages Benchmarks Game. 😁

This one features a bit different set of languages (including Crystal, Nim and Mojo 🔥) and implementations (both Bun and Node, CPython and PyPy, CRuby and GraalVM Ruby). It tries to compare the same manually implemented algorithms in all languages, but doesn't seem super strict about the runtime environment and external load on the system.

The results are pretty unsurprising. Another reminder that advanced JITs like HotSpot JVM's C2 or Node's V8 for plain monomorphic C-like code produce C-like heavily optimized and very fast machine code.
😁1
— Зачем нам понадобился цветочный магазин?
— Нам нужен английский плющ!
— Это как английский сплин, только плющ?
😁1🤔1
Ink & Switch have another prototype for a dynamic document supporting some kind of user programming and some rich views:
https://www.inkandswitch.com/embark/

A LIVE'23 conference presentation: https://www.youtube.com/watch?v=6tLwmmtv6cA
Я завирусился. В плохом смысле.
😢3😁1
FORTRAN NOT DEAD

OK, we all know very well that Scientific Computing runs on FORTRAN: many high-performance math libraries like BLAS, many many-decade old simulation libraries and models in all sorts of fields — weather, oceanography, quantum chemistry, molecular biology, pharmacology and what not. Legacy stuff, right?

WRONG

Food and Agriculture Organization (FAO) of the United Nations recruited KU Leuven to rewrite an industry-standard model for crop growth in response to water (or lack thereof) from Pascal to FORTRAN:
https://github.com/KUL-RSDA/AquaCrop

Luckily some folks want to rewrite it to Julia:
https://discourse.julialang.org/t/short-term-scientific-programmer-for-crop-growth-modelling/109251
Почему кто-то вообще запомнил и записал, что Иисус Христос как-то раз взял да превратил воду в вино? Понятно, что у них там не было сети "Красное и Белое", но тем не менее... Это же не самое важное достижение в его жизни, правильно? Лечил слепых? Ерунда. Ходил по воде? Фокусы. Воду в вино превратил?! Наконец-то что-то полезное! О чём думали эти люди? Нет, реально — что происходило у них в головах, что вино оказалось в одном ряду с лечением слепых и воскрешением полумёртвых?
😁3👍2👎1
https://www.youtube.com/watch?v=RUJFd-rEa0k&list=PLP8iPy9hna6Tp3QV4akXAd23_O5Vjm_e2
Discussion:
https://discourse.julialang.org/t/does-julia-create-a-1-5-language-problem/107984

Julia famously claims to solve the "two languages problem": you use one language (Python) for high-level prototyping or configuring the actual computation graph (TensorFlow) and another language (C/C++) for low-level performant heavy lifting (NumPy). With Julia you allegedly can do both things in the same language.

Indeed, there are Julia libraries that outperform industry-standard heavily optimized decades-polished C/C++ counterparts (some ODE solvers for instance). And yep, you can program GPGPUs (both NVidia and AMD these days) without switching to special CUDA language extensions and a pipeline.

BUT. The authors point out that "friendly Julia" and "performant Julia" are very different styles even if the same language. Hence, 1.5 languages.

The observation not particularly fresh, the notion of "mechanical sympathy" floats around for quite some time. So the issue haunts pretty much any language: high-performance C or C++ is pretty different from "naive" or straightforward one. It might be even much more pronounced for Rust: "async Rust" is distinct enough for many people to avoid it altogether.

I don't know of a good solution for this discrepancy. Though every generation of languages have its try. We'll see how Mojo fairs in this regard.


Also to note: there's a Gaussian Process model evaluated on every spin of a car cylinder on a custom hardware... 🤯
👍1
https://twitter.com/SchmidhuberAI/status/1745475698737938543?t=_X-WsN5TCusvNMCRHkIxgA&s=19

Надо тоже перекатываться в AI — к 60 как раз успею подкачаться... 😁
I like https://pyre-check.org — it does a type inference and type checking for Python, and supports user-defined analysis rules for security or other potential issues (https://pyre-check.org/docs/pysa-basics/). It's implemented in OCaml following nice classic Abstract Interpretation framework and architecture explicitly abstracting away abstract domains.

And it's employed for actual high-volume production analysis at Instagram: https://instagram-engineering.com/static-analysis-at-scale-an-instagram-story-8f498ab71a0c
🤡2👍1
🤬2😁1
Registration is open for the Workshop on Homotopy Type Theory and Univalent Foundations:
https://hott-uf.github.io/2024/
Leuven, Belgium, April 2–3, 2024
Online attendance is possible but registration is required anyway,
https://www.pm.inf.ethz.ch/research/verifythis.html

Pretty famous annual VerifyThis competition will be held at ETAPS April 6th and 7th, 2024.
Participants are welcome to register and attend, (some) travel grants are available.
😁1
https://www.youtube.com/watch?v=XLtxXkugd5w

Curious. Apparently the "Wolfram Physics Project" isn't really about physics, but about a mathematical formalism capable of describing a wide spectrum of possible (or impossible) "physics". And yet it has some fundamental and generic features that lead to potentially testable consequences in our physics. 😊
🤔1
Twelve of the sixteen Federal topographic maps covering the river corridor had gross errors. Thirty-five of the ninety-three rapids were unmarked and two dangerous falls were not on the maps at all. Twelve portages were missing and six were marked in the wrong location.

as of 1995 on a single river in Canada. Leading to many drownings over the years.

I think topographic maps have improved immensely across the globe since that time...
😁1
Как называется предприниматель, который практикует недеяние?
👏1😁1