News for hackers. Stuff that matters.

rogue7

Re:Focus on Saturday July 11, 2026 @02:05PM (#48874211)
what are you talking about ?
Re:A Road to Lisp: Why Lisp on Thursday July 09, 2026 @01:09PM (#48849135)
Kind of agree, but in my view preventing the programmer to make mistakes is futile. I have seen awful stuff in languages made to prevent errors.

It's much better to give all the power to the programmer, to allow him to fix his mistakes rather than fantasising about preventing them.

IMHO surveillance is a problem when it is asymmetric ; which is obviously the case here. Governments for example are watching everyone inside and outside, but the people that are being monitored simply cannot really watch the people watching them. Don't you agree ?

In this view, maybe an ultra radical solution to privacy issues is : no privacy at all, for no-one. Complete and total transparency of everyone to everyone. Now the question is how to implement that ? That's obviously impossible, because someone in power will always have something to hide. So maybe if true democracy where everyone holds exactly the same amount of power that could work ? Same issue, because it is impossible to implement too. Oh well.

Re:People Do Not Yearn for Automation on Thursday April 23, 2026 @03:27PM (#47880447)
Agreed for cheaper prices and more flexibility. At least this is what we think we want. But do we actually want it ? A computer 40 years ago was way more expensive than now. How did people do it ? They managed. How do we do it now ? We manage, similarly.

Was there an improvement in things ? Obviously, computers are more powerful for example. But with less powerful computers, people could also be happy I believe.

I remember 15 years ago, tech has obviously evolved a lot since then, and I have learned to use more and more tech tools. But am I more efficient than then ? Happier than back then ? More skilled than back then ?

- More efficient for some things, less efficient for others. - Happier ? no. Not sadder either, similar. If anything, it's not related. - More Skilled ? No. Skilled at other things. For example my handwriting is still ok but I believe I won't be able to write so much or so quickly or so well as I used to (I should try though).

Am I saying that progress is not real ? No, of course not. Progress happens. But is it what "people" want or need ? Taking my own perspective : if it happens (and it does), I adapt - no problem. If it does not happen somehow - then I would adapt too. That's what we do.

Re:People Do Not Yearn for Automation on Thursday April 23, 2026 @03:11PM (#47880218)
Personally, it depends. If I could automate taking the trash out, I would do probably want to do it (not sure though). But what remains when everything is automated ?

Well, so far we have been automating many things, and we are still busy working and living as always. It's of course impossible to automate everything - we always have things to do, by necessity by also by choice ; do we really want to be idle and contribute nothing to society ? I don't, and I am sure nobody does. Being useful is an essential need.

Is it pointless then, to automate more and more ? No. It's a way to move forward, and not necessarily a "bad" way. Just not the only way.

Re:Windows 9x Subsystem for Linux on Wednesday April 22, 2026 @10:48AM (#47864450)
Never heard of this joke, very funny !

Show HN: Understand Mortgage Cash Flows

https://linemo.horaceg.xyz

A while ago, I was wondering if I should buy a home. Then I tried to understand how mortgage loan work, and what the interest rate represents.A few hours later, this (static) web app was born. It's a glorified calculator that allows you to answer two questions:- how much interest will I pay in addition to the principal (the amount being borrowed).- Whether I should buy my home or keep renting.

( Read More... | 2 comments | 3 points | on HN )
Re:A love letter to the CSV format (2024) on Thursday September 11, 2025 @03:52AM (#45209001)
For this I use gron [0]. It's very convenient.

[0]: https://github.com/tomnomnom/gron

Re:PHP 8.5 Adds Pipe Operator: What it means on Tuesday August 05, 2025 @05:17AM (#44795914)
This looks neat. However since I read about Koka's dot selection [0], I keep thinking that this is an even neater syntax:

fun showit( s : string )

  s.encode(3).count.println
However, this is of course impossible to implement in most languages as the dot is already meaningful for something else.

[0] https://koka-lang.github.io/koka/doc/book.html#sec-dot

Re:A straight line teaches machines to learn on Thursday May 08, 2025 @11:26AM (#43927040)
I built a small static web app [0] (with svelte and tensorflow js) that shows gradient descent. It has two kind of problems: wave (the default) and linear. In the first case, the algorithm learns y = ax + b ; in the second, y = cos(ax + b). The training data is generated from these functions with some noise.

I spent some time making it work with interpolation so that the transitions are smooth.

Then I expanded to another version, including a small neural network (nn) [1].

And finally, for the two functions that have a 2d parameter space, I included a viz of the loss [2]. You can click on the 2d space and get a new initial point for the descent, and see the trajectory.

Never really finished it, though I wrote a blog post about it [3]

[0] https://gradfront.pages.dev/

[1] https://f36dfeb7.gradfront.pages.dev/

[2] https://deploy-preview-1--gradient-descent.netlify.app/

[3] https://blog.horaceg.xyz/posts/need-for-speed/

Vaping is way less harmful than smoking.

See e.g. the study [0] conducted by Public Health England that concludes vaping is at least 95% (!) less harmful than smoking.

See also this video [1] that shows graphically the different impact it has on the lungs.

[0] https://www.gov.uk/government/news/e-cigarettes-around-95-le...

[1] https://youtu.be/0Pwj6BuS8Ds

> 5. Many of my current projects take the form of "big data pipeline, followed by intermittent job to rebuild a static site and push it live"; astro fits very nicely in this role

You may be interested in Observable Framework [0]

[0] https://observablehq.com/framework/

Re:FireDucks: Pandas but 100x Faster on Wednesday November 20, 2024 @11:20AM (#42195423)
In this case `d` is the entire dataframe. It's just a way of "piping" the object without having to rename it.

You are probably thinking about `df.apply(lambda row: ..., axis=1)` which operates on each row at a time and is indeed very slow since it's not vectorized. Here this is different and vectorized.

Re:FireDucks: Pandas but 100x Faster on Wednesday November 20, 2024 @11:18AM (#42195401)
Agreed 100%. I am using this method-chaining style all the time and it works like a charm.
Re:Apache Zeppelin on Thursday September 05, 2024 @10:28PM (#41462337)
This is possible to do with ipywidgets [0] and all the ipy[stuff] packages.

bqplot [1] for example is great for 2D dataviz, very responsive and updates real-time. Based on D3 I believe. Usually I can do what I want with base widgets and bqplot and the result is pretty.

ipyleaflet is another popular library for maps.

I especially enjoy using them with voila [2] to create an app, or voici [3] for a pure-frontend (wasm) version.

If you want to develop a widget, the new-ish anywidget library can reveal handy [4].

For an example, see this demo [5] I made with bqplot and voici, that visualizes a log-normal distribution.

[0] https://ipywidgets.readthedocs.io/en/stable/

[1] https://github.com/bqplot/bqplot

[2] https://voila.readthedocs.io/en/stable/

[3] https://voici.readthedocs.io/en/latest/

[4] https://anywidget.dev/

[5] https://horaceg.github.io/long-tail/voici/render/long_tail.h...

Re:Ask HN: Best static site generator for non-designer? on Friday August 30, 2024 @08:09AM (#41399899)
I'm using Quarto [0], pretty happy with my blog [1].

Before it was made with Zola [2], which is also nice.

[0] https://quarto.org/

[1] https://blog.horaceg.xyz/

[2] https://www.getzola.org/

I built a gradient descent visualizer in js with Svelte and TensorflowJS [0].

Also wrote about it in my blog [1].

[0] https://gradfront.pages.dev/

[1] https://blog.horaceg.xyz/posts/need-for-speed/

Re:They Live on Monday May 06, 2024 @12:30AM (#40271148)
Same here. _I already am eating from the trash can all the time_

https://youtu.be/oBcFLmu_tlc

Re:Wonnx real-time webcam image classication using WebGPU on Monday March 04, 2024 @08:30AM (#39590221)
So I'm a ping-pong ball, good to know
Re:Vega-Altair: Declarative Visualization in Python on Tuesday February 27, 2024 @06:35AM (#39522854)
I love Vega(-lite) / Altair, the grammar of graphics plotting system is really great to build any kind of chart even when it wasn't thought through by the authors of the library. There are other wrappers for languages that lack viz libraries, such as Elixir / Livebook [0]

However, when I used it a couples years back it struggled with large vizs, I think due to Vega(-lite)'s way of embedding the data in the viz artifact.

Also, interactive is nice but often I just need a quick static plot, and matplotlib is more convenient for this, you can easily see the png in any environment etc.

These days I'm eager to see an Observable Plot [1] wrapper for Python ! See [2] for a comparison to vega-lite

[0] https://github.com/livebook-dev/vega_lite

[1] https://github.com/observablehq/plot

[2] https://observablehq.com/@observablehq/plot-vega-lite

Re:Uv: Python packaging in Rust on Thursday February 15, 2024 @03:36PM (#39388406)
For conda there is mamba [0], a drop-in replacement that's really fast.

By the way, the creator of mamba started his own company at https://prefix.dev/

They want to essentially leverage the conda(-forge) infrastructure to build a new cross-platform, cross-language, cargo-like package manager: pixi

[0] https://github.com/mamba-org/mamba

Re:Observable 2.0, a static site generator for data apps on Thursday February 15, 2024 @12:16PM (#39385336)
Interesting pivot from the Observable team.

I loved observable and wrote a couple of notebooks, it worked great ! I'm gonna try Framework asap !

Looks cool !

Makes me think of Voila [0], in my opinion one of the most powerful solutions to build interactive app with python. It requires Jupyter notebook, IPywidgets and e.g. BQPlot.

[0] https://voila.readthedocs.io/en/stable/

Re:Show HN: htmldocs - Typeset and Generate PDFs with HTML/CSS on Wednesday January 17, 2024 @11:37AM (#39030022)
I used the same [0], however wkhtmltopdf stopped working correctly at some point, so I am stuck printing the pdf manually with chrome at the moment. Probably an update that broke some stuff.

[0] https://blog.horaceg.xyz/posts/resume/

Re:An Introduction to Probabilistic Programming on Tuesday January 16, 2024 @12:02PM (#39015634)
You need to wait a bit because there is a fair bit of precomputing in the browser when you open the page.

I will reduce the number of coin tosses to improve the UX

Re:An Introduction to Probabilistic Programming on Friday January 12, 2024 @02:57AM (#38965325)
A small interactive introduction to bayesian inference on Observable.

Older ยป