frontpage.
newsnewestaskshowjobs

Open Source @Github

fp.

Show HN: Simple algorithm and color space to generate diverse skin tones

https://toneyalexander.github.io/inclusive-color-space/
240•automatoney•2h ago•59 comments

All of Winona Police Department's Flock cameras cut down and stolen

https://www.valleynewslive.com/2026/08/04/every-flock-camera-winona-minnesota-cut-down-stolen-coo...
37•NDlurker•1h ago•8 comments

Dataset: Dead mental health startups, 2000-2026, coded on 18 fields

https://mentalium.me/en/research/mental-health-startup-graveyard-dataset/
10•trubetskov•44m ago•0 comments

DeepSeek V4 Flash on a Single AMD MI300X

https://github.com/ryanzhou/deepseek-v4-flash-mi300x
302•zhoutong•8h ago•66 comments

Vlt 1.0 and Hosted Package Registries

https://www.vlt.io/blog/1-0
13•patrikcsak•31m ago•0 comments

Hop.earth – OpenStreetMap based car racing game

https://hop.earth/?server=lkhr7&route=fQ5nuu9R
5•faebi•20m ago•5 comments

Keyv and friends compromised in active Shai-Hulud supply chain attack

https://www.aikido.dev/blog/keyv-and-friends-compromised-in-npm-supply-chain-attack
171•cimi_•7h ago•86 comments

The Warp Agent CLI

https://www.warp.dev/blog/introducing-the-warp-agent-cli-coding-agent
11•emschwartz•1h ago•0 comments

Truemetrics (YC S23) Is Hiring in Berlin – GTM Lead

https://www.ycombinator.com/companies/truemetrics/jobs/bIQQ7tP-founding-gtm-lead
1•truemetricsIngo•1h ago

Show HN: cMCP, deny an AI agent's tool call and get a signed receipt

https://github.com/agentrust-io/cmcp
3•mosiddi•9m ago•0 comments

The Judgment Reservoir

https://shannph.com/writing/the-judgment-reservoir/
3•shampaynee•9m ago•0 comments

Online ad giant Adform was hacked, proving once again why ad blockers are needed

https://this.weekinsecurity.com/online-advertising-giant-adform-was-hacked-proving-once-again-why...
138•speckx•3h ago•43 comments

Buckminster Fuller: everything I know (1975)

https://www.bfi.org/about-fuller/everything-i-know/
103•simonebrunozzi•6h ago•30 comments

Harness Engineering for Self-Improvement

https://lilianweng.github.io/posts/2026-07-04-harness/
241•tosh•11h ago•52 comments

Dates That Don't Exist (2015)

https://blog.yossarian.net/2015/06/09/Dates-That-Dont-Exist
79•EndXA•3d ago•51 comments

It's not a fear of "AI communism"; it's a fear of competitive market capitalism

http://observationalepidemiology.blogspot.com/2026/07/its-not-fear-of-ai-communism-its-fear.html
26•speckx•4h ago•13 comments

Xbox goes down. You can't play games you own on disc

https://birchtree.me/blog/xbox-goes-down-you-cant-play-games-you-own-on-disc/
425•surprisetalk•6h ago•493 comments

Haters

https://www.paulgraham.com/fh.html
9•vikrum•10m ago•1 comments

Apple says more ex-employees may have taken confidential data to OpenAI

https://techcrunch.com/2026/08/04/apple-says-more-ex-employees-may-have-taken-confidential-data-t...
151•thewebguyd•2h ago•113 comments

Why Large Language Models Fail at Tabular Prediction

https://arxiv.org/abs/2608.02412
85•sbulaev•8h ago•30 comments

Germany Records Historic 12B KWh Solar Feed-In in July 2026

https://solarquarter.com/2026/08/03/germany-records-historic-12-billion-kwh-solar-feed-in-in-july...
113•johnbarron•4h ago•131 comments

Looking inside a 1970s PROM chip that stores data in microscopic fuses (2019)

https://www.righto.com/2019/07/looking-inside-1970s-prom-chip-that.html
28•Jimmc414•3d ago•5 comments

Show HN: Fine-tune an 8B model on a 4 GB laptop GPU

https://github.com/MakazhanAlpamys/Soup
99•MakazhanAlpamys•6h ago•16 comments

Why etymologies matter: How tracing words can illuminate history (2024)

https://resobscura.substack.com/p/why-i-love-etymologies
82•benbreen•3d ago•16 comments

Show HN: Run an 80B Qwen in 4.3 GB of RAM on a Mac, and a 35B on an iPhone

https://github.com/leonickson1/Swiftlet
287•leonickson•1d ago•131 comments

RCade: The Arcade Cabinet with CI/CD Deployment, Custom Graphics Card for CRT [video]

https://www.youtube.com/watch?v=W-OpIbLUOU0
30•evakhoury•5d ago•7 comments

LLMs reward expertise

https://www.seangoedecke.com/llms-reward-expertise/
1277•MaxMussio•21h ago•524 comments

Rebuilding and analysing 4 years of Wordle stats from WhatsApp chat logs

https://blog.omgmog.net/post/rebuilding-wordle-stats-from-whatsapp/
17•surprisetalk•1d ago•4 comments

AI Data Centers Are Driving Up Power Bills – This Map Shows Where

https://www.gadgetreview.com/ai-data-centers-are-driving-up-power-bills-this-map-shows-where
6•01-_-•18m ago•0 comments

Homebench – Benchmark local LLMs for speed, memory, and quality

https://github.com/david-g-3654/homebench
53•davai-g•8h ago•5 comments
Open in hackernews

Comparing floating-point numbers (2012)

https://randomascii.wordpress.com/2012/02/25/comparing-floating-point-numbers-2012-edition/
26•sph•1y ago

Comments

LegionMammal978•1y ago
I'd argue that any equality comparison of floating-point numbers is asking for trouble, unless you're specifically working with small dyadic fractions (using exact comparison) or testing a purely heuristic 'closeness' condition (using fuzzy comparison).

Of course, inequalities show up in a lot more places, but are similarly fraught with difficulty, since mathematical statements may fail to translate to floating-point inequalities. E.g., in computational geometry, people have written entire papers about optimizing correct orientation predicates [0], since the naive method can easily break at small angles. This sort of thing is what often shows up as tiny seams in 3D video-game geometry.

[0] https://www.cs.cmu.edu/~quake/robust.html

mtklein•1y ago
My preferred way to compare floats as being interchangeably equivalent in unit tests is

    bool equiv(float x, float y) {
        return (x <= y && y <= x)
            || (x != x && y != y);
    }
This handles things like ±0 and NaNs (while NaNs can't be IEEE-754-equal per se, they're almost always interchangeable), and convinces -Wfloat-equal you kinda know what you're doing. Also everything visually lines up real neat and tidy, which I find makes it easy to remember.

Outside unit tests... I haven't really encountered many places where float equality is actually what I want to test. It's usually some < or <= condition instead.

sph•1y ago
I have built a production Javascript library with decent amounts of users that incorporates the following hack to deal with float error (avert your eyes if you're sensitive):

  // 1.2 - 1.0 === 0.19999999999999996
  // fixFloatError(1.2 - 1.0) === 0.2
  var fixFloatError = function (n) {
    return parseFloat(n.toPrecision(12));
  };
It felt correct at the time, but after reading the article, I cringe at how fundamentally broken it is. I got away with it because the library is used to convert betting odds, which are mostly small floating point numbers, so the error is often < 10^-12.