HNHacker News
TopNewBestAskShowJobs

njohnson41

369 karma · joined January 4, 2015

submissionscomments
njohnson41··on Mathematics of shuffling by smooshing
Even with the birthday problem, sqrt(52!) is still about 10^34, which is still huge. It's unlikely that any two (sufficiently random) shuffles in history have been the same.
njohnson41··on Good News on the California Drought
Or maybe it's just a good excuse to carry fewer cups and pitchers around?
njohnson41··on Cloud Video Intelligence API
You're right (and nitpicking nitpicks seems appropriate to me :P).

But, I'm pretty sure the assumptions of logistic regression are even stronger than just that. The inputs are assumed to be independent given the output class, and the log odds of the output vary as a linear function of each input. The first one is essentially the naive Bayes assumption, and the second one is completely unreasonable for almost any problem ever (roughly equivalent to assuming every dataset has a multivariate normal distribution). If they are both correct, though, you get a perfectly good Bayesian posterior probability of each output class.

I think the lesson is that gradient descent will build a decent function approximation out of pretty much anything powerful enough, which is why neural networks still work even when probability theory has been thrown completely out the window.

njohnson41··on Cloud Video Intelligence API
Still, in any consistent way of assigning probabilities to events, if A implies B, then P(A) <= P(B).

Neural network outputs are not probabilities. I think that's the main lesson here.

njohnson41··on What is logic?
I personally liked "Godel's Proof" by Ernest Nagel. It's pretty old, but it's to-the-point and inexpensive.
njohnson41··on A Nihilist's Guide to Meaning
Fair enough; I'll be a little more precise.

I think the correct way to state it is: "all true statements are either tautologies, or can be determined empirically (with arbitrarily high but not necessarily measure-1 probability)". This statement is itself a tautology, because tautologies are by definition true, and because "determined" implies some method of determination, which if it actually can be used to determine truth, means it can be used empricially. Determination and empiricism are secretly defined in terms of each other, basically. The reason this tautology is worth stating is that it gives a simple criterion for discarding non-questions: questions that have no method of determining whether they are true or false (with arbitrarily high probability), are always non-questions.

njohnson41··on A Nihilist's Guide to Meaning
Especially if you assume that the scientific method is always valid--that all true statements can be determined empirically--you can't make statements like "Ultimate Meaning doesn't/does exist". If Ultimate Meaning cannot be defined, it cannot be tested for or measured, so no statements about it can be true or false. The answer to meaning would not be false, but null (or maybe 42).

Just like 42, "atoms and the void" here is just a science-flavored attempt to answer a non-question.

njohnson41··on Guide to User Data Security
> ... all possible combinations of 8-16 characters with 100 character possibilities ...

Yes, but this doesn't even come close to describing the typical users' password, which is most likely a 6-letter English word with a capital letter and a 1! appended to the end. Your calculation here isn't really relevant, because it's all about the worst or common case. (You also assume that people are using a GPU for a compute-bound problem, when much faster FPGAs are also available, but either way it's moot.)

Security through obscurity, which is what you're proposing with the shuffled salt idea, is also not normally considered the right way to go. If you wanted to use a similar but much simpler and straightforward method, you could just encrypt the salted hashes before storing them in the database.

njohnson41··on CS 281B: Statistical Learning Theory (2014)
This should be marked (2004), not (2014).
njohnson41··on Boys who live with books ‘earn more as adults’
There could also be a simpler causal link: books and lucrative jobs could both caused by higher family socio-economic status.
njohnson41··on Academics Make Theoretical Breakthrough in Random Number Generation
Kolmogorov complexity is definitely meaningful, but it's not (Shannon) entropy, just conceptually similar. Many people think of something like Kolmogorov-complex sequences when they think of "random" sequences, which is (IMO) why they have trouble thinking of entropy as being about a probability distribution.

The one case where they coincide (sort of) is if you believe your random sequence is generated by a randomly chosen Turing machine, which I've only really seen in philosophical settings.

A uniformly chosen 64-bit integer still has exactly 64 bits of entropy, regardless of how much Kolmogorov complexity the actual bits you generate have.

njohnson41··on Academics Make Theoretical Breakthrough in Random Number Generation
Right, the amount of entropy per bit of sequence is always between 0 (deterministic) and 1 (every bit is independent and 50/50) (... or between 0 and log2(k) in general if the element varies over a set of k things). These "weak" sources just have low entropy per bit. They could be biased (more 0s than 1s) or correlated (long runs of 0s/1s or periodicity), or just have some other pattern that sometimes holds.

A deterministic PRNG's sequence has exactly the entropy of it's seed, actually, but it has 0 bits of entropy per symbol, because its sequence is infinite.

The thing most people get confused about with entropy is in thinking that entropy is a property of some single object, like a bit string. Really, entropy is always a measurement about a probability distribution, just like mean or variance is. In the usual case with random streams, the distribution is P(x_i | x_i-1 ... x_0) for bits x_i in the stream, i.e. the distribution remaining for the current bit even if we know all previous bits. For a deterministic PRNG, once we can extract the key from the history (given unlimited compute power) that distribution becomes deterministic, so the entropy is 0.

njohnson41··on Academics Make Theoretical Breakthrough in Random Number Generation
That's because this result is not about combining weak deterministic PRNGs, it's about combining entropy sources (like two hardware random number generators).

This has always been possible, but it sounds like they've lowered the minimum entropy needed in the source streams to produce a high-quality output.

njohnson41··on Intel Xeon E5 v4 Review: Testing Broadwell-EP With Demanding Server Workloads
Interestingly, that may be the new ordering if the disks are SSDs, but the typical seek latency on a spinning disk (~5 ms) is definitely higher than the latency to read data from another machine's memory across ethernet (a few hundred us), and even the bandwidths are comparable (~150 MB/s).

So, now it has jumped from (disk -> network -> memory -> ...) to (network -> disk -> memory -> ...), which is a big change.

njohnson41··on Lave: eval in reverse
Sounds a lot like python's "pickle" module (which is super-useful for prototyping), but with the same achilles' heel: all of your serialized objects can now run arbitrary code when you deserialize them!
njohnson41··on Engineers of Jihad: Connection between Violent Extremism and Education
Of course, knowing that extremists are usually engineers only helps you if you have a known extremist and want to guess his profession. Extremists are a pretty small group, and engineers a much larger one, so I'd have to assume that extremism is still very rare among engineers, meaning knowing whether someone is an engineer or not is completely useless for predicting if they're an extremist.

But hopefully, you've got a STEM degree, and can figure that fact out out yourself ;)

njohnson41··on We Should All Have Something to Hide (2013)
I think one of the common terms for this is a "motte and bailey doctrine", where people define their terms one way during an argument to make their statements super-defensible, but later redefine them to mean whatever crazy thing they actually meant. People seem to use this intentionally and unintentionally a lot.

http://slatestarcodex.com/2014/11/03/all-in-all-another-bric...

njohnson41··on Bayes's Theorem: What's the Big Deal?
Good article.

I'm only a bit disappointed that the author seems not to realize that Bayes' theorem is just a simple consequence of probability theory, and should be attractive not because "maybe the brain is Bayesian", but because it is based on sound set-theoretic and analytic principles. If Bayes' theorem is false, so is probability theory, and so is nearly everything we know about probability.

Edit: Here is a good explanation of the theorem that makes it visually clear how only set theory is involved in deriving it: https://oscarbonilla.com/2009/05/visualizing-bayes-theorem/

njohnson41··on Possible biochemical mechanism underlying long-term memories identified
There are already multiple known molecular mechanisms for long-term memories though.

One of the simplest is spike-timing-dependent plasticity [1], which is caused by the behavior of NMDA receptors shortly before and after depolarization. (This is why ethanol, an NMDA antagonist, can produce a "blackout" in high doses, where no memories are formed.)

In general, neurons have a lot of mutable long-term state. The graph of how neurons are connected can change, the strength of those connections can change, the internal chemistry of the neurons can change through gene expression factors, and, apparently, levels of long-lived prions can change.

This is not to say that the whole mechanism of long-term memory is understood, but that this discovery is just one of a class of mechanisms that may all be working in parallel or even independently.

[1] https://en.wikipedia.org/wiki/Spike-timing-dependent_plastic...

njohnson41··on Summit rules out ban on gene editing embryos destined to become people
Not if we genetically engineer them to like it first!
njohnson41··on How to act less stupid, according to psychologists
I suspect that's an important part of why confident ignorance is seen as the "stupidest" trait. Being confident has social advantages, so without a significant risk of looking stupid for overlooking something, everyone would try to be confident all the time, and confidence would have a very low signal-to-noise ratio for determining who to trust.
njohnson41··on Hand-Coded Assembly Beats Intrinsics in Speed and Simplicity
You can convey some of that information to the compiler by using __builtin_unreachable(), e.g.:

  #define ASSUME(x) if(!(x))__builtin_unreachable()
This is compiler-specific, of course, and introduces undefined behavior if the assumption is violated. There's also no guarantee that the compiler will use the information well. But, it's almost guaranteed to not generate any extra code based on it.
njohnson41··on On the Value of Not Knowing Everything
"If, after all, Nagel is proven wrong—that is, if subjectivity is in fact reducible to an identifiable network of neural synapses—what is the point of investigating the human condition through a humanistic lens? If what it is like to be human, much less a bat, turns out to be empirically situated in the dense switchboard of the brain, what happens to Shakespeare, Swift, Woolf, or Wittgenstein when it comes to explaining ourselves to ourselves?"

Nothing, of course. Thinking that believing reductionism will somehow transform human minds into mathematics is like thinking that believing evolution will transform humans into chimps. And whether or not you believe in reductionism, the reality of humanity won't change. The only thing that changes is that the non-reductionist philosophers lose and the neurobiologists, cognitive scientists, and AI researchers win. Which seems to be happening, in any case.

njohnson41··on Cryptographic Right Answers
Cryptographic constructions using block ciphers generally rely on the block cipher never having the same input twice with the same key in order to satisfy security models.

If you're feeding effectively random data into the block cipher (like if you're using CBC), then because of the birthday paradox, you get at most about 2^32 blocks (far fewer in practice at a good security level) per key if you have 64-bit blocks. This is low enough to be annoying for designers or problematic for suites that don't rekey correctly.

However, because CTR (or GCM) mode uses sequential inputs to the cipher, I think that a 64-bit block size would not be a problem there. At that point, the reason not to use 64-bit block ciphers is because they're all older, weaker, and less-supported than AES-128.

njohnson41··on Stop overanalyzing and become the best version of yourself
A "right answer between competing answers" just sounds like a high-entropy belief state over the correct action to take. This doesn't mean you're overanalyzing, it means you don't have enough information to be sure of your decision. If that's the case, you won't get anywhere by analyzing more (although more research may help); "feeling" will just let you be overconfident in whatever you come up with, because you won't understand or question how you came up with it.
njohnson41··on BPF – In-kernel virtual machine [pdf]
If BPF can be used to modify packets, can a filter be used to send packets through loopback that then come back through the same filter? Sounds like a way to bootstrap a loop.
njohnson41··on Cheese from the same proteins as milk, but from genetically modified yeast
Correlation, sure. But even as a non-vegetarian, I can understand the argument for not raising animals directly or indirectly for food, due to inefficiency. Vegans who believe that but don't really care about food being "natural" would still want this stuff; not all vegans are motivated to be vegan by the same things.
njohnson41··on Hacker's guide to Neural Networks
I also like how the backpropagation section starts out by immediately talking about how it is really just chain rule application.

The backwards-moving pattern of "backpropagation" is really just a side-effect of the derivative chain rule application order, but a lot of intro materials treat backprop as if it is some fancy thing specially-designed for neural nets. I suppose "compute the gradient of this function using basic vector calculus" just isn't sexy enough. I complain mostly because it took me a while to figure out whether backprop was exactly the same as gradient descent, or if there were subtle differences.

njohnson41··on The Ugliest Sign in America
LEDs at 4 V DC are probably much easier to control with "microchips", which operate at a similar voltage, than neon at 2-15 KV AC. I agree he worded it badly, but the conclusion still makes sense for a loose reading of "essentially".
njohnson41··on Could Wearable Computer Radiation Be Harmful?
From a physics standpoint, this is a pretty silly idea. Here's why.

Whether we're talking about radiation caused by wireless communication (e.g. wifi at 2.4/5 GHz) or high-frequency oscillations in a microprocessor, it's pretty safe to say that all of the significant electromagnetic radiation coming off of a wearable computer is under 10 GHz.

Damage to proteins, DNA, etc. due to radiation is either caused by that radiation stripping electrons / breaking covalent bonds, or through heating.

The sort of electromagnetic radiation that strips electrons and breaks covalent bonds is called ionizing radiation; ionizing radiation only occurs above a certain frequency threshold (depending on the material being ionized). This fact is, in fact, the reason Einstein got his Nobel in physics. Anyway, its pretty safe to say that, say, red visible light (400 THz) does not ionize important human molecules. Ultraviolet is usually considered to be the low end of the ionizing radiation range.

Therefore, because 400 THz > 10 GHz, radiation coming from wearable computers could not possibly cause molecular damage to humans through ionization. The light coming from the screen is significantly more dangerous in this respect than anything coming from the other electronics.

How about heating? Consider that a typical wearable computing device only consumes a few watts. If this power were distributed diffusely, it is harmless, and if it were focused, it would cause obvious and painful burns, which we know doesn't happen.

Page 1 of 2Next →