HNHacker News
TopNewBestAskShowJobs

derf_

2,803 karma · joined July 22, 2012

submissionscomments
derf_··on Bug or Feature? Unintentionally Intentional Behaviors
Well, one has to be careful here. In a static portion of a scene, a consistent error likely to look much better than an error that flips between being too large and too small in alternate frames, since the latter will show up as noise or flicker that was not in the original. That can be more objectionable than simply being slightly wrong. Notably none of the metrics we use for evaluating Daala have any means of measuring this.

The better approach, I think, is some form of "temporal RDO", where you spend more bits on places that will be good predictors of future frames. We discussed the idea in a Theora update in 2010 [0]. x264 implemented it even before then (under the name "mbtree" [1]). It is not yet implemented in Daala, as we do not have two-pass rate control or lookahead yet. It's possible to do one-pass, no-lookahead versions by estimating future prediction efficiency based on the past, but you want one with full lookahead to compare against to make sure those estimates are doing the right thing.

I am not sure temporal RDO would save us here, because the issues described only occur in areas of the frame that are being updated. It still might have, in this case---these things are relative---but we could construct cases where it would fail to do so.

[0] https://people.xiph.org/~xiphmont/demo/theora/demo9.html

[1] http://www.x264.nl/developers/Dark_Shikari/MBtree%20paper.pd...

derf_··on A Competing HEVC Licensing Pool
Wikipedia (6th largest website in the world) serves only unencumbered formats. Apple's Siri uses Speex. As does Flash. This stuff shows up in more places than you think, precisely because it allows innovation without asking permission.
derf_··on Bug or Feature? Unintentionally Intentional Behaviors
Well, there are other ways to tell them that this interoperability is important: https://wpdev.uservoice.com/forums/257854-internet-explorer-... (no registration required to vote).
derf_··on Bug or Feature? Unintentionally Intentional Behaviors
> I'm not sure if Opus was proposed as mandatory for the audio tag (I think it should).

https://www.w3.org/Bugs/Public/show_bug.cgi?id=18932

It was CLOSED WONTFIX.

derf_··on Bug or Feature? Unintentionally Intentional Behaviors
This is the latest in a series of posts on Daala: https://people.xiph.org/~xiphmont/demo/
derf_··on Fund Manager Ab Nicholas Has Been Beating S&P 500 for 40 Years
The way to prove someone is not a lucky coin-flipper is to identify them before they flip the coins (or, at the very least, by some attribute that was observable before they flipped the coins). For example, "took a class from Ben Graham in 1951" [1] might be such an observable criteria.

[1] http://www8.gsb.columbia.edu/rtfiles/cbs/hermes/Buffett1984....

derf_··on The sad state of browser matrix transforms
The space of invertible linear transformations is actually a Riemannian manifold, and in particular a Lie group. Because Lie groups are differentiable, you can defining a geodesic path between two points by minimizing a path integral. That would be the "canonical" [0] path to choose, but there are three problems.

The shortest path depends on your metric. There are straightforward choices for translation (uniform L2 norm) and even scaling (log) and rotation (the amount you rotate by), but when all three are combined in one matrix, units come into play, and things like skew and perspective make them more complicated.

This path is not guaranteed to be unique. Uniqueness fails exactly where two or more geodesics cross. The set of places where this happens is called the "cut locus". The example given elsewhere of a 180 degree rotation is a good illustration of a point in a cut locus.

The set of invertible linear transformations is also not connected. It is partitioned into two components: those with positive determinant and those with negative determinant, and there is no continuously differentiable path from one to the other that does not cross through a matrix with det=0 (i.e., that is not invertible). http://dbaron.org/css/test/2010/transition-negative-determin... has some examples of animations between 2D transformations where the sign of the determinant differs.

As for intent... this is the reason for the rule pornel gives in another comment: if all of your transforms use the same functions in the same order, then interpolation is done on the arguments of these functions (this also eliminates the problems with having to choose a metric described above). That gives the designer a reasonably simple way to express intent.

I think that a language for specifying M(t) that is expressive enough to cover all the bases would be very complicated to define, and probably not of much more practical utility than just defining a large number of matrices and doing short transitions between them, which you can do today.

P.S., I work for Mozilla and gave advice to people in the CSS WG when 3D animations were being discussed.

[0] The definition of canonical being, if you locked 10 mathematicians in a room and asked them a question, it's the answer 9 of them would give you.

derf_··on High quality GIF with FFmpeg
> However, Wu's method needs lookup tables for the whole color (hyper)cube,

You're talking about the 1991 method. The 1992 paper I cited explicitly claims as one of its advantages that it does not require lookup tables (and thus avoids the usual step of pre-quantizing down to 5 bit color to get a reasonably-sized table).

Your two big wins sound an awful lot like "K-means". I'd believe they are responsible for the bulk of the improvement (they're also the bulk of the computation), but they mean you don't have axis-aligned partitioning anymore, which was my point.

The problem is that K-means is notoriously sensitive to the initial clustering. For unsupervised learning, I'd want to do as good a job there as possible, and applying PCA means you are picking the split direction that exactly minimizes variance in the orthogonal directions. Random restarts are also a nice way to escape local minima, but are even more expensive computationally.

derf_··on High quality GIF with FFmpeg
Yes, what kind of crazy designer would do that: https://news.ycombinator.com/item?id=4531088
derf_··on High quality GIF with FFmpeg
Any method that makes axis-aligned subdivisions (which includes both standard median cut and octree), even in a space like HSV, is going to be pretty suboptimal. There's probably been more sophisticated things done since I looked at this in the 1990's, but Xiaolin Wu's 1992 approach [1] works quite a bit better than both (including the 1991 Wu v2 implementation of an octree method linked elsewhere in this thread). It's based on recursive PCA, dynamic programming to assign colors along the principal axis, and K-means refinement in CIE L* u* v* coordinates. Not the fastest algorithm, but the topic is "high quality".

And you can still dither the image without completely destroying compression. You just have to use an ordered dither [2].

[1] Xiaolin Wu, "Color Quantization by Dynamic Programming and Principal Analysis", ACM Transactions on Graphics 11(4): 348-372, 1992. https://dl.acm.org/citation.cfm?id=146475

[2] https://xiphmont.livejournal.com/35634.html

derf_··on The time has come to stand up for the GPL
I don't think that's true at all. Anyone who's spent any time at all in open source has a pretty good idea what their obligations under the GPL are. There may be corner cases debated on the internet by geeks who ANAL, but if those actually matter to your business, simply asking someone at the SFC or SFLC will quickly clear them up [0].

I'll quote LWN's summary [1] from the talk Bob Young of Red Hat gave at LCA this January:

He has long been a staunch advocate of the GPL, he said, but not because he has detailed opinions of the differences between it and other, similar licenses. Rather, he said, he learned early on that customers do not care about the details of free-software licenses, and that diving into an explanation of them was the fastest way to send a potential customer running toward the competition. ...

With the GPL, everyone knows what the rules are, more or less, so the debate is over quickly. They might not actually know the rules, he added, but they think they do, which amounts to the same thing. As a "business guy," he said, he is always trying to simplify the "pitch" - the GPL tells everyone "what we're about," so it has the greatest impact.

[0] We did this when we wanted to publish a royalty-free patent license tied to certain code, and wanted to be sure it would not keep people from using that code in GPLv3 projects. We were reasonably sure of our interpretation of the terms, but it's always nice to double-check.

[1] https://lwn.net/Articles/629413/

derf_··on Berkshire Hathaway 2014 Annual Report [pdf]
Well, he's often said the only reasons he will sell is if a business's competitive advantage disappears, he's lost faith in management, or he needs the cash.

Johnson & Johnson would be one recent (2012) example where I think neither the first nor the third conditions applied (though he only said they'd "obviously messed up in a lot of ways in the last few years" in an interview, and didn't discuss it in the shareholder's letter at all).

derf_··on Berkshire Hathaway 2014 Annual Report [pdf]
> Also, does anyone have color on went wrong with Tesco?

One of Buffett's claimed keys to success is being able to evaluate management talent^. Since he can't manage all of these business himself, it's important for him to have talented managers running each show. He has specifically built Berkshire to be attractive to this kind of person. E.g., when he makes an acquisition, the old management is left in place and continues to run the business, making it a great way for someone who has built a business from scratch to cash out and yet be sure their baby won't be dismantled, unlike a normal M&A that tends to fire all of upper management and gut half the staff.

So when he says he's lost faith in management, that is quite a serious condemnation. My guess (with no data backing it up) is when Tesco ran into trouble, they tried to feed him a load of crap about it, and he knew it.

^If you have not heard the story of Mrs. Blumkin of Nebraska Furniture Mart, it is well worth it: http://www.focusinvestor.com/Blumkin.pdf

derf_··on What’s really going on in a salary negotiation
If your old employer does lie, you have documentation to back up your statement (W-2's in the US, tax returns, etc.). And your old employer knows this.
derf_··on Fuck It, I'm Going Back to Firefox
Why would you use and contribute to one of them instead of Firefox?
derf_··on The “Web Application” Myth
> I'm not sure why so much ink is spilled on it other than it's easy to form opinions around.

Because people read it. And people read it because social cues are important.

When you're going to commit hundreds (or thousands) of man hours to building a system you may have to maintain for years based on very, very partial knowledge, you want to know what other people think about the tools you plan to use.

derf_··on YouTube now defaults to HTML5 video
Well, certainly in developing countries where bandwidth is limited, you're going to be watching a small resolution, and any amount of CPU is fine so long as you can cut the bitrate.

There are a lot of people in places like that.

Also, Allwinner, Intel, Mediatek, and Rockchip all have SoCs announced with hardware VP9 decode: http://wiki.webmproject.org/hardware/socs (not sure how many of those are already shipping).

derf_··on CVE-2015-0235 – GHOST: glibc gethostbyname buffer overflow
Well, Ulrich Drepper has been trying to get people to stop using it since 2007: https://udrepper.livejournal.com/16116.html

And not just because of IPv6.

derf_··on Kim Dotcom launches end-to-end encrypted audio and video chat service
https://news.ycombinator.com/item?id=8683593
derf_··on Why not DANE in browsers
Something about which I'm glad to be wrong.
derf_··on Collision Detection, Part 2
Quite old now, but to me the go-to reference is still Brian Mirtich's Ph.D. thesis, "Impulse-based Dynamic Simulation of Rigid Body Systems": https://xkanim.googlecode.com/svn/trunk/mirtichThesis.pdf
derf_··on Why not DANE in browsers
In that case, DNSSEC probably isn't doing much for you (besides the systemic effects of discouraging providers from returning false DNS results in the first place), but sadly not everything on the internet is so well-designed as ssh. Being unable to specify a port in MX records, leaving SMTP on port 25 with only STARTTLS for encryption being one good example.
derf_··on Why not DANE in browsers
That depends on what your trust model is. Somebody is resolving the DNS query, and then the result gets transmitted to you. If all you're worried about the result being MITM'd during transit, then encryption is sufficient. You can set up DNSCrypt to deal with this today [1].

But often the provider resolving the query is itself untrustworthy. Most providers these days (including OpenDNS) redirect invalid queries to their own landing pages (which poisons caches and has other bad effects). Providers may "censor" certain domains. Or be subverted by state-level actors (see: Belgacom). In DNSSEC, the root of trust is the administrator of the DNS root zone (e.g., Verisign, whom you're probably already trusting anyway).

[1] But encryption is not a panacea. As soon as you visit the address(es) returned, someone will get a pretty good idea what you looked up.

derf_··on Ex-Googler: 'Tons of Engineers' Want to Leave Google
I don't think they mean an annual subscription. I assume they mean taking a larger share of the purchase price of apps, in-app purchases, and maybe even ad revenue. In the 12 months prior to June, developers earned $5bln for these things (Apple paid out north of $7.5bln in the same period) [1].

Google used to give developers 70% of app purchase revenue, give carriers 25%, and keep only 5% for themselves. A year or so ago they moved to keeping almost all of the non-developer pie. That pie is closer to $2bln than $38mln. But if they're going to take more, the only place left to take it from is developers. I can't believe that's going to go over well for them, but I already can't believe carriers rolled over so easily despite giving Google things it really needed, like carrier billing for app purchases.

[1] http://www.beyonddevic.es/2014/06/25/what-we-learned-about-g...

derf_··on How GCHQ Spies Hacked Belgium’s Largest Telco
To me, by far the most interesting bit is this:

GCHQ developed a system called NOCTURNAL SURGE to search for particular engineers and system administrators by finding their IP addresses...

The confirmation came in the form of Google, Yahoo, and LinkedIn “cookies,” tiny unique files that are automatically placed on computers to identify and sometimes track people browsing the Internet, often for advertising purposes. GCHQ maintains a huge repository named MUTANT BROTH that stores billions of these intercepted cookies, which it uses to correlate with IP addresses to determine the identity of a person.

Hope you aren't sending cookies to an http site. Ever.

derf_··on That Whole Thing with Sound in In-Browser Emulation
IE doesn't support Web Audio either. The project I linked above does contain a Flash shim for IE, which you may find helpful.

Any proper realtime audio stack (which ogv.js is not: it targets moderate latency streaming) is going to require a jitter buffer to deal with network/processing latency variation. Writing one is a non-trivial exercise (though not impossibly so).

In any case, I'd recommend using Opus (the audio codec used by WebRTC) over Speex.

derf_··on That Whole Thing with Sound in In-Browser Emulation
You might be interested in looking at what https://github.com/brion/ogv.js does.

Just curious, if your goal is realtime, why aren't you using WebRTC?

derf_··on That Whole Thing with Sound in In-Browser Emulation
That's what Mozilla's proposed MediaStream Processing API was: https://dvcs.w3.org/hg/audio/raw-file/tip/streams/StreamProc...

But Google was able to put more engineering effort behind the Web Audio API and get a lot of web sites to use it, so that's what won. The fact that Web Audio's ScriptProcessorNodes run on the main thread instead of in workers is basically a travesty, brought about because they were tacked on as an afterthought to claim "feature parity" with the MediaStream Processing API. Until that's fixed [1], real-time audio generation in JavaScript will always be a joke that only works under ideal conditions where people open just one, well-tuned webpage in their browsers at a time and GC pauses don't exist.

(full disclosure: I work for Mozilla and am not bitter at all)

[1] https://developer.mozilla.org/en-US/docs/Web/API/Web_Audio_A... is the proposal to fix it, only three years late to the party

derf_··on Why Bitcoin Core 0.10's release notes say “…libsecp256k1 is better than…OpenSSL”
Right, one of the weaknesses of tools that rely on coverage analysis... and highlights the importance of using more than one approach to testing. No single tool can do everything.
derf_··on Why Bitcoin Core 0.10's release notes say “…libsecp256k1 is better than…OpenSSL”
He isn't using black box testing, he's using white box testing (knowing Greg, either KLEE [1] or AFL [2]... probably both... and probably also black box testing). The test does incorporate a great deal of knowledge of the algorithms (in fact, complete knowledge), but the point is that it's the machine that does the analysis of the implementation, not a human.

[1] https://klee.github.io/

[2] http://lcamtuf.coredump.cx/afl/

← PreviousPage 14 of 17Next →