HNHacker News
TopNewBestAskShowJobs

phiresky

3,459 karma · joined July 26, 2018

https://phiresky.github.io/blog/
submissionscomments
phiresky··on Fucking Color Picker
I would in fact argue that until we are at a point of diminishing return of improving hardware that it is good that software is becoming more and more "bloated", because that's the only incentive to keep researching more efficient hardware.

Phones for example have basically been unchanged for 5 years regarding performance, because while hardware has drastically improved the apps have become heavier in proportion for superficial new features. Same goes for internet connections.

As another example I'd say that the recent resurgence of deep learning has mostly come from (or at least was catalysed by) cheap, affordable GPUs, which only exist because gamers wanted better and better graphics.

phiresky··on Fucking Color Picker
Yes, this 450 line program could have been written in whatever native language you want with probably 3x the code and time spent, but why would you? Developer time has been more expensive than hardware for a decade now.

Everyone here loves to virtue signal about how horrible programs that take 0.01% of the space of a normal SSD and 1% of the RAM are, but the fact is that it does not matter at all, and you wouldn't even have noticed if you hadn't intentionally looked at the size of it.

phiresky··on Ice cold archive storage
True - which is kind of weird, because as far as I understand their respective "databases", borg would be more suited for arbitrary remote storage because it should only need a "upload file" command basically without any interactivity, except for its robustness checks and some additional flexibility (having multiple backup sources, deleting data that is no longer needed).

Restic seems more made from the ground up to utilize the existing power of a filesystem as a database, so it needs remote storage that offers quick interactivity (esp. checking existing files), i.e. it's impossible to use something like Glacier as a backend.

It's not a problem for me since I just backup to a local drive and (am planning to setup) synchronization to a remote dumb storage.

phiresky··on Ice cold archive storage
Borg Backup is mostly the same as Restic (regarding dedup / incremental backup) [1] and aggregates data into large chunks.

If you only backup from a single machine it has a local cache of already backed up data, this has the large advantage that it basically only needs to push the delta data to the remote, not do any kind of synchronization to check what is already there or not.

[1]: https://stickleback.dk/borg-or-restic/

phiresky··on When to Use TypeScript – A Detailed Guide Through Common Scenarios
You can kind of give generics names by declaring them in an interface and passing T extends Interface as the generic parameter
phiresky··on When to Use TypeScript – A Detailed Guide Through Common Scenarios
You realize that your problems with Rambda were mostly fixed in TS3.4?
phiresky··on Why GNU grep is fast (2010)
I love how you always just instantly appear outta nowhere when someone mentions a problem with ripgrep or makes a false statement about it :)
phiresky··on Article 13 gets legalized because Sweden pushed the wrong voting button
You should watch this video about how bad the voting procedures actually are: https://youtu.be/lzigiPUXNzI
phiresky··on MEPs accidentally vote wrong way on copyright law
You're really arguing that 700 representatives from 30 countries speaking in 10 different languages with live translation and voting with automatic tallying is _archaic_?

But I agree, the way the counting works and how they do not seem to care at all about accurate results seems ridiculous: https://youtu.be/lzigiPUXNzI

phiresky··on Web Scraping with Electron
Also, you can apparently connect the puppeteer client to a running chrome instance [1]. That way you can use the nice and statically typed puppeteer api and you should have pretty much zero overhead.

[1] https://github.com/GoogleChrome/puppeteer/issues/238

phiresky··on Web Scraping with Electron
It uses the devtools protocol, see here https://chromedevtools.github.io/devtools-protocol/

Looks like it's a REST protocol.

You have to connect to a tab and then call e.g.

    Runtime.evaluate {expression: "console.log('test')"}
phiresky··on Web Scraping with Electron
You can run puppeteer with any chromium binary, including non-headless mode.

You can also just start chromium with debugging active `--remote-debugging-port=9222` and then connect to that port and send any dev console commands.

phiresky··on Dear OpenAI: Please Open Source Your Language Model
That's pretty much what they are publicly saying, right?

> This decision, as well as our discussion of it, is an experiment: while we are not sure that it is the right decision today, we believe that the AI community will eventually need to tackle the issue of publication norms in a thoughtful way in certain research areas.

phiresky··on If Software Is Funded from a Public Source, Its Code Should Be Open Source
Wealth is not a zero sum game.
phiresky··on I Nearly Lost All of My Data
Looks nice, but it is not open source.
phiresky··on After GDPR, The New York Times cut off ad exchanges and kept growing ad revenue
Feel free to share some of your expert knowledge with the rest of us (instead of just complaining about comments from non-experts).
phiresky··on Windows 10 and reserved storage
I'm sure reserving 10GB of space will greatly "improve the reliability" of my Windows installation on a 60GB partition (on a 120GB dual boot SSD) with 5 GB free.
phiresky··on SQLite as an Application File Format (2014)
SQLite does not support BLOBs larger than 2GB, so in that sense it's only as good as FAT32
phiresky··on Brave taking cryptocurrency donations “for me” without my consent
That's a ridiculous complaint and you know it. Oh no, you have to wait 5 minutes for DNS propagation, what a scam!
phiresky··on Brave taking cryptocurrency donations “for me” without my consent
You really want to get spammed with "claim your 5ct in donations for signing up on our website!" every day?
phiresky··on The rise of 8D Audio on YouTube
I think the problem is more that people's ear shapes are pretty different, and the exact way that sound coming from a specific direction presents itself is different for every person - so you pretty much need a different profile (HRTF [1]) for every person to make them accurately hear sound coming from specific directions.

I played around with those a while ago since it makes a pretty large difference in the realism of positional audio (both for surround video and for games). For me especially for differentiating between sound coming from in front of and from behind me. But I never really got it to work globally. [2] has a list of 50 different HRTFs. Only ~5 of them manage to make the sound come from in front of me correctly.

[1] https://en.wikipedia.org/wiki/Head-related_transfer_function

[2] https://www.reddit.com/r/linux_gaming/comments/2ot5ov/enable...

phiresky··on Copying objects in JavaScript
> - Roundtrip-able (reversible?)

You mean injective

phiresky··on Sweden's cashless society is no longer a utopia
> The same applied to every supermarket but one near my hotel.

I've been able to pay everywhere I've been to in the Netherlands with a normal European debit card with chip + pin (Maestro I think)

phiresky··on Show HN: TabNine, an autocompleter for all languages
Nice. I had the same idea a while ago [1], but I didn't make it very far. Good to see that the concept of applying ML to intellisense can actually be useful.

[1]: https://github.com/phiresky/deep-intellisense Video https://www.reddit.com/r/programmerhumor/comments/8xrwr5/_/

phiresky··on Bitcoin can push global warming above 2 C in a couple decades
Actual source since this is almost impossible to find from the link above:

https://www.nature.com/articles/s41558-018-0321-8

https://github.com/moracamilo/Bitcoin/

Edit: The study seems to have a major flaw in that it ignores the effect of the block subsidy in its calculations: Though it mentions the block reward halvenings, it ignores them in the CO2e calculations. They basically calculate the CO2e emissions per transaction in 2017, then multiply that by a predicted number of transactions that will be made in future years [1]. Currently, transaction fees only account for 1-2% of the miner reward - (in 2017 on average 17% of profit was the fees, in 2018 6% and in the past 6 months only 1.5% [2] )

The study makes predictions in a very long term (15+ years) - but they ignore that what is currently 95+% of the reward (and thus 95% of the energy used) automatically halves every four years. This ratio will forcibly change over time - in 20 years bitcoin is either dead or fees will account for almost all of the reward - which means you have to divide the predicted emissions in the paper by at least 5.

In the long term the amount of energy one BTC transaction burns is pretty much the same as the fee paid for that transaction times the cheapest electricity in the world.

[1] "The CO2e emissions of projected Bitcoin usage were estimated using the CO2e emissions for Bitcoin transactions in 2017 as a reference. We randomly sampled blocks mined in 2017 until their total number of transactions were equal to the projected number of transactions, then we added the CO2e emissions from computing such randomly selected blocks. The approach was repeated 1,000 times."

[2]: https://gist.github.com/phiresky/a6755c650b3bbb340c4d641f89f...

phiresky··on 310 Bitcoin challenge has been solved
The actual amount of energy consumed by one bitcoin transaction is actually pretty exactly the amount of money you pay as a fee times the cheapest you can get electricity in the world.

So if you pay $0.2 in fees, you will burn around $0.2 / ($0.1/kWh) = 2kWh of electricity. Note that this is an upper limit since it ignores miner profit (but that will tend towards zero over time).

This is ignoring the block subsidy, but that is independent of the number of transactions will forcibly solve itself over time.

phiresky··on Show HN: WebRTC signalling data using QR codes
Similar project of mine that connects a phone to a PC browser using a WebRTC QR code so you can use a pen / touch on the phone to create drawings on the desktop:

https://www.youtube.com/watch?v=Gvsm84xL9Sk (https://github.com/phiresky/webrtc-remote-touch-pen-input)

Sadly it needs a (tiny) server component to exchange the initial connection information - using a QR code in both directions is smart, but also pretty annoying for the user.

phiresky··on Javascript: call functions without using parentheses
The template strings feature is not a just "shorthand syntax", it allows you to do things that were not possible before (see [1])

[1] https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe...

phiresky··on Why We Need Web 3.0
> (inability to just type in the URL)

You could still put all domains of an alternate domain system behind a X.web3.org that loads the whole system client side, and then connects to peers via WebRTC to load the domain X via webtorrents or ipfs or zeronet or whatever. That way it's (mostly) backwards compatible to normal websites and you can remove the "root domain" trust point later.

phiresky··on Plastic Pollution
I'd love to hear reasons why Germany is so horrible in this statistic. Why do we have 2.5x as much plastic waste per capita as France?
← PreviousPage 6 of 7Next →