Rules systems for play and progress. When you choose, do you divide the infinite?
mercredi 11 novembre 2020
Sensation Firewall
mercredi 28 octobre 2020
A Recipe for Overtaking the Number Two
samedi 24 octobre 2020
Is Your Brain a Matrix?
If all that - a giant matrix as a brain - seems too simple to be possible, keep in mind that this kind of matrix represents an interacting network. There's a math proof that a matrix can approximate any process, meaning any natural or computational process as far as we understand the word "process," and it's very closely related to the way you can break any sound down into a spectrum of frequencies. The proof actually depends on the same idea.
The "deep" in "deep learning" just means using a bigger matrix. Often that means using fancier hardware to run the learning faster, but not necessarily. This is very similar to cameras and screens with higher and higher resolutions. A newer phone should have a faster chip to keep up with a higher pixel count in camera and screen. But it doesn't technically need a faster chip. It would just slow down otherwise. Images didn't get more complicated, only bigger.
But for that ability to sculpt a matrix into any process to really work, the matrix needs to be broken up into individual vectors, and those are run against the input - the vector representing senses - one at a time, with each result - a work-in-progress vector - put on a curve a bit like a grading curve. This curved result is then sent to interact with the next vector that was broken off the matrix. Rinse and repeat!
Eventually that work-in-progress vector is done, at which point it represents the thoughts/actions that are the output. Think of each number in the vector as the strength of each dimension of possible response, the probability of hitting each note on a piano, or how much to move each muscle, etc. So to put the last paragraph in different words, a "deep learning" matrix, aka neural network, is no more than a bunch of multiplications in the form of dot products between pairs of vectors, with a little filter/curve after each one.
Incidentally, each one of those vectors broken off the matrix can be visualized as a line or edge. You can imagine that you could draw any picture, even a 3D one, even a 5005D one, with enough lines or edges. You can make it as clean and accurate as you want by adding more lines. We know that intuitively, because that's how sketching works. Deep learning is not unlike sketching very fast. Similarly, you can draw a very smooth circle, as smooth as you want, with enough little square pixels. See it? Now we can do that with concepts.
But those are details. Students who think matrix math is boring will typically hear about AI from me, haha. And they do tend to find it interesting.
The curve, or conditioning, after each step is what makes this different from just multiplying a giant vector by a giant matrix to get another giant vector. That would be too simple, and it's kind of the lie I told at the start. Instead, information flows step by step through the layers of the matrix much like energy filtering up through the layers of an ecosystem, towards apex predators and decomposers. And there's that curve/filter between each level. I suppose it's a bit like a goat eating grass which is converted into goat; something changes in the middle. It isn't grass to grass, it's grass to goat, so there's a left turn in there somewhere. That bend is critical but not complicated at all, though why it's critical is more difficult and I don't fully understand why. That filter doesn't even have to be a curve, it can just mean putting a kink in each line - just a bend in each vector, like a knee or elbow. It almost doesn't matter what the bend is, just that it's there. That's surprisingly essential to the universality of neural networks, so apparently it adds a lot for very little. I don't have a good analogy for why that's true, except that the world isn't actually made up of a bunch of straight lines. It's more like a bunch of curves and surfaces and volumes and energy and particles and static and other noise and signals between interconnected systems, and this step, putting kinks in the lines, allows the processing to break out into a much larger possibility space.
Theoretically, the old possibility space (without bends) was the stuff that you could accomplish with the "transformations" you learned in geometry - stretches, rotations, reflections, glides. The new space is all possibility space - or any "before/after" that can be measured and processed as a measurement. Artificially aging your neighbor's cat, painting today's sunset from weather data... If there's any logical connection between input and output, between before and after if there's time involved - even if that connection is just the laws of physics - or even if it's just a random association to memorize, like didn't you know volcanoes and lemons are connected because I said so - that connection can be represented by a big enough matrix.
So instead of pixels, it's lines, and instead of lines, it's bends. Think of bends as moments of change. Maybe this is a little like adding 3D glasses and color to a greyscale picture without altering the resolution. But... the effect of the curving/filtering/bending I've been talking about would be far more shocking than the image upgrade if you could directly experience the difference, given that we get the potential of learning and mimicking every known process. Maybe we do directly experience that difference as a key component of being alive. It's more like adding motion to that image, and an understanding of where the motion comes from and where it's going. Or to rephrase, the greyscale picture with our "kinks" update is now more like a mind than a photo - which, after all, is a simpler kind of matrix, one that is not a network.
The other simplification I made is that the big matrix is actually broken down into multiple matrices first, before those are broken down into individual vectors, each of which is roughly equivalent to a single neuron. What I described was a single-file chain of neurons, but there can be many neurons next to each other. Each layer of neurons in a neural network is its own matrix. Each neuron is its own vector. But I'd say that aspect of the layers is the least important detail here, other than realizing you can see each row of a matrix as a brain cell, which is neat. And you can very roughly imagine each brain cell as knowing how to draw one line-with-bend through concept space and give its vote on that basis.
We have 6 layers of neurons in the cerebral cortex, for reference, so at a gross simplification that would be 6 big matrices in a chain, with the rows of each matrix representing individual neurons.
samedi 19 septembre 2020
How to Unroll Convolutions
A More Normal Formula
Take ex...
Square the x, and the function is now positive on the left side.
You get an extremely narrow parabola variant. Here's a parabola in green for comparison. (The next two images are just for illustration, not part of the process.)
(Technically, it's the exponential of a parabola. It's ex2 instead of x2. If you ask me, that counts as a parabola variant. But it grows much faster.)
Now negate the exponent.
Voila.
That's the rule. It's an upside-down parabola for an exponent.
The rest of the famed formula is tweaking—specifying the unit size via the mean (\(\mu\)) and the standard deviation (\(\sigma\)). It looks complicated, but this is a lot like describing a parabola with \( (y-k) = 4p(x-h)^2 \) instead of just \(x^2\). The second gives you the foundational idea, while the first incorporates adjustments.
\[\frac{1}{\sigma \sqrt{2\pi}} e^{-\frac{1}{2}(\frac{x-\mu}{\sigma})^2}\]
Great to have on hand as a reference, but we already have the essential bell curve just from two modifications to basic exponential growth. We square the exponent and then negate the exponent.
\[e^x \rightarrow e^{-x^2} \] Oh, and if the e is confusing, we could have started with any example of exponential growth. For example, we could use a base of 2. (A base multiplier of 2 sets a slightly slower growth rate than with e.) The picture would look much the same.\[2^x \rightarrow 2^{-x^2} \]
This time I'll leave out the two graphs comparing with a basic parabola, because they weren't really part of the process anyway, and they look the same. And remember, there's nothing very special about 2 or e here. Any real number can be turned into a bell curve by exponentiating, squaring the exponent, and negating the exponent.\[2 \rightarrow 2^x \rightarrow 2^{x^2} \rightarrow 2^{-x^2} \]
\[3 \rightarrow 3^x \rightarrow 3^{x^2} \rightarrow 3^{-x^2} \]
\[5.8316 \rightarrow 5.8316^x \rightarrow 5.8316^{x^2} \rightarrow 5.8316^{-x^2} \]
\[\pi \rightarrow \pi^x \rightarrow \pi^{x^2} \rightarrow \pi^{-x^2} \]
Below is with a base of 2.mardi 15 septembre 2020
The First Rule of Presumptuousness
I've always felt that "know thy audience" becomes a form of stereotyping. Certainly, in this or that design you'll get to know, and meanwhile learn to incorporate, facts and measurements of a special group of people. An ATM should really work for everyone who might have a bank account. But there's a big difference between "usability" and "targeting an audience." Usability doesn't pander, it just makes accessible and comfortable. Audiences, though, are too often pandered to.
samedi 15 août 2020
How to Step Back to Go Forward
Debate is a game. It's something most people don't quite understand, or don't apply.
If you're in a disagreement and you don't want it to turn into a fight, you both need to move towards treating the discussion as a debate, which is a game. That can be difficult, especially for a big issue, but if you can't, it's best to put the discussion aside for now.
Let me bring in a pretty typical definition of game. A game is a finite contest with rules, an experience you can win or lose, but the consequences are negotiable.
Russian Roulette has rules: put one bullet in a revolver, spin the thing, point the gun at your head, and pull the trigger. If it was a live chamber, you're probably instantly dead, and you've lost. If it was a blissfully empty chamber, you've won. But see, the consequences are not negotiable: either you're dead or you're alive at the end. So while Russian Roulette resembles a game, it is not.
Debate, on the other hand, is a game.
Many people very understandably don't want a discussion to be just hot air—they want to get something done with it—and by driving at that purpose too hard, they lose the value of discussion.
The value of discussion is that it's virtual. The words are only words. Your debate is a little virtual world of words, where you're trying to follow the rules of logic and evidence—you want the debate to have bearing on actual life. Yet the consequences of the debate are very much negotiable. What does it mean to win or lose a debate? Maybe nothing. Maybe something. That's all TBD by the participants afterwards. Nothing is set in stone. And, as I said, that is the actual value of debate. If you had to move all the bricks physically into different arrangements while debating architectural choices, civilization would still be in the stone age today.
The virtuality of conversation, and debate, is its greatest strength. And then people go and forget that, or never quite understand it and its implications.
Some people understand debate is a game, whether they would use that word or not. And they are usually much more pleasant and engaging to discuss controversial topics with. This doesn't mean they have no beliefs or don't consider the topics important, or even critical. It's just that debate is a game. You don't solve global poverty in your chit-chat with your housemate over dinner. So stop acting like you do, and if you have a particularly good round of debate, you might actually be somewhere at the end that you weren't at the beginning.
That's how it works, and it really truly does work.
* Note: just because it's a game doesn't mean you have to be goofy, though that's often a very useful approach. Taking the pressure off allows people to speak more freely and think more creatively together. But you can also be very serious. Debate that's a game can still get heated, but it never gets personal. The feminist "everyone's perspective is valid" approach is also a great way to make a debate a game. Goofy, spirited but not personal, listening while perspective-taking—all of these are ways to make debate do its job, and they share the same principle. To the extent they would ever get a little intense or combative, everyone understands that this is sparring, and nothing to do with liking or disliking each other. May the best idea win.
** The definition of game and the Russian Roulette example I'm pretty sure both come from the book Half-Real. My copy went to a good friend 6 years ago before I went into a big surgery I thought I might not survive (statistically, there was a 1% chance I wouldn't, which makes a very big and relatively safe revolver for Russian Roulette, but that's a smaller revolver than for most surgeries, and it was a 5 hour procedure that left me with 55 staples and now a 13-inch scar, so maybe I wasn't being that dramatic). I hadn't finished reading it, but it has the best definition of game I've ever seen anywhere, by a long shot. Most books on game studies start out defining game (yawn). This one, though, makes that triply worth your while to read.











