Readit News logoReadit News
randomtoast commented on Python Workers redux: fast cold starts, packages, and a uv-first workflow   blog.cloudflare.com/pytho... · Posted by u/dom96
TudorAndrei · 3 days ago
Are you comparing the startup time of an interpreted language with the startup time of a compiled language? or you mean that `time python hello.py` > `( time gcc -O2 -o hello hello.c ) && ( time ./hello )` ?
randomtoast · 3 days ago
I'm referring to the startup time as benchmarked in the following manner: https://github.com/bdrung/startup-time
randomtoast commented on Python Workers redux: fast cold starts, packages, and a uv-first workflow   blog.cloudflare.com/pytho... · Posted by u/dom96
nickjj · 3 days ago
> The startup time of a simple .py script can easily be in the 100 to 300 ms range

I can't say I've ever experienced this. Are you sure it's not related to other things in the script?

I wrote a single file Python script, it's a few thousand lines long. It can process a 10,000 line CSV file and do a lot of calculations to the point where I wrote an entire CLI income / expense tracker with it[0].

The end to end time of the command takes 100ms to process those 10k lines, that's using `time` to measure it. That's on hardware from 2014 using Python 3.13 too. It takes ~550ms to fully process 100k lines as well. I spent zero time optimizing the script but did try to avoid common pitfalls (drastically nested loops, etc.).

[0]: https://github.com/nickjj/plutus

randomtoast · 3 days ago
Here is a benchmark https://github.com/bdrung/startup-time

This benchmark is a little bit outdated but the problem remains the same.

Interpreter initialization: Python builds and initializes its entire virtual machine and built-in object structures at startup. Native programs already have their machine code ready and need very little runtime scaffolding.

Dynamic import system: Python’s module import machinery dynamically locates, loads, parses, compiles, and executes modules at runtime. A compiled binary has already linked its dependencies.

Heavy standard library usage: Many Python programs import large parts of the standard library or third-party packages at startup, each of which runs top-level initialization code.

This is especially noticeable if you do not run on an M1 Ultra, but on some slower hardware. From the results on Rasperberry PI 3:

C: 2.19 ms

Go: 4.10 ms

Python3: 197.79 ms

This is about 200ms startup latency for a print("Hello World!") in Python3.

randomtoast commented on Python Workers redux: fast cold starts, packages, and a uv-first workflow   blog.cloudflare.com/pytho... · Posted by u/dom96
randomtoast · 3 days ago
One of my biggest points of criticism of Python is its slow cold start time. I especially notice this when I use it as a scripting language for CLIs. The startup time of a simple .py script can easily be in the 100 to 300 ms range, whereas a C, Rust, or Go program with the same functionality can start in under 10 ms. This becomes even more frustrating when piping several scripts together, because the accumulated startup latency adds up quickly.
randomtoast commented on Show HN: Gemini Pro 3 imagines the HN front page 10 years from now   dosaygo-studio.github.io/... · Posted by u/keepamovin
navane · 4 days ago
It so very weird to see this called "hallucinate", as we all have more or less used it for "made up erroneously".

Is this a push to override the meaning and erase the hallucination critique?

randomtoast · 4 days ago
At some point, no matter how something is mentioned, someone will offer criticism. I guess that in roughly 20% of all HN front page posts, at least one person comments on the terminology used. I do not see this as an argument against using accurate terminology, but rather as a reminder that it is impossible to meet everyone's expectations.

There are other terms that are similarly controversial, such as "thinking models". When you describe an LLM as "thinking", it often triggers debate because people interpret the term differently and bring their own expectations and assumptions into the discussion.

randomtoast commented on AI should only run as fast as we can catch up   higashi.blog/2025/12/07/a... · Posted by u/yuedongze
manmal · 6 days ago
Well structured monoliths are modularized just like microservices. No need to give each module its own REST API in order to keep it clean.
randomtoast · 5 days ago
One problem is that the idea of being "well-structured" has gone overboard at some point over the past 20 years in many companies. As a result, many companies now operate highly convoluted monolithic systems that are extremely difficult to replace.

In contrast, a poorly designed microservice can be replaced much more easily. You can identify the worst-performing and most problematic microservices and replace them selectively.

randomtoast commented on Touching the Elephant – TPUs   considerthebulldog.com/tt... · Posted by u/giuliomagnifico
randomtoast · 7 days ago
I don't think Moore's Law is dead.

Starting point: In 1965, the most advanced chips contained roughly 50 to 100 transistors (e.g., early integrated logic).

Lets take 1965 -> 2025, which is 60 years.

Number of doubling intervals: 60 years / 2 years per doubling = 30 doublings

So the theoretical prediction is:

Transistors in 2025 (predicted) = 100 × 2^30 ≈ 107 billion transistors

The Apple M1 Ultra has 114 billion transistors.

randomtoast commented on Gastronorm   en.wikipedia.org/wiki/Gas... · Posted by u/niek_pas
j4cobgarby · 11 days ago
For what purpose? Baking? Storing things in the fridge?
randomtoast · 11 days ago
Food prep for the week, storing chopped vegetables, marinating small cuts of meat, storing baking ingredients like nuts, holding leftovers, portioning snacks, storing coffee beans or tea, ...

You should also buy the sealing lids with silicone gaskets.

randomtoast commented on “Captain Gains” on Capitol Hill   nber.org/papers/w34524... · Posted by u/mhb
a4isms · 11 days ago
It is not illegal for them to trade on their inside information. It is illegal for you to trade on their inside information. So they can send you their stock picks list and gloat about their ROI, but if you invest on the basis of the newsletter, you go to jail.

Wilhoit was right about everything: America is in-groups who are protected by the law, but not bound by it. Alongside out-groups who are bound by the law, but not protected by it.

You and I? An out-group. And it although we make a lot of jokes about leopards ripping faces off, MAGA know they're an out-group too, it's just that as long as somebody else is getting it worse, they're fine with that.

randomtoast · 11 days ago
> It is not illegal for them to trade on their inside information. It is illegal for you to trade on their inside information. So they can send you their stock picks list and gloat about their ROI, but if you invest on the basis of the newsletter, you go to jail.

All the Congress member trades are public. There are even ETFs now that track the Congress member trades. So you can just buy such an ETF and have a one-to-one replication of the Congress member portfolio.

randomtoast commented on Gastronorm   en.wikipedia.org/wiki/Gas... · Posted by u/niek_pas
randomtoast · 11 days ago
I can recommend the smaller ones such as 1/9 and 1/6 for personal use. Very durable, last decades.
randomtoast commented on Windows GUI – Good, Bad and Pretty Ugly (2023)   creolened.com/windows-gui... · Posted by u/phendrenad2
randomtoast · 18 days ago
Just invert this ranking and then it should fit.

u/randomtoast

KarmaCake day350April 18, 2024View Original