Monthly Archives: May 2013

Friday Links

I spent a good 40 minutes putting together my usual Friday Links, complete with pictures. Then I hit “Preview” and discovered WordPress had decided to delete it, sans explanation.

So in lieu of that, here’s the short version:

  • Thingiverse is an online database of downloadable 3D printer designs. You can even print a new starship in case your old one gets busted up whilst flying Into Darkness.
  • Hacking the President’s DNA isn’t possible…yet. But how far off is a future like this?
  • Speaking of the future, how about a pill that knows you’ve swallowed it?
  • Somebody mailed a package with a tiny camera inside. This three-minute video takes you inside the journey of mail.
  • Carrie Fisher confirms she’s playing Leia once more in Star Wars: Episode VII. In spite of the rampant cynicism about yet another trilogy, I think the early signs are positive. It’s too early to get excited, but it’s also too early for prophecies of doom.
  • And finally, as always, SMBC delivers.

Have a culturally enlightened weekend – or at least drink some good beer! See you Monday.

These Are a Few of My Favorite Things

It’s been a pretty serious week so far on the Buckley blog, so I thought we’d lighten the mood a little. Here’s something I wrote this morning for no particular reason.

Sing to the tune of “My Favorite Things,” from The Sound of Music.

Vulcan and Hoth, Z’ha’dum and Arrakis
Louis C.K. and Zach Galifianakis
Hitchhiker’s Guide and The Lord of the Rings
These are a few of my favorite things.

Gödel and Escher and Bach and the Beatles
Thumbing my nose at my phobia of needles
Robots that hover on bumblebee wings
These are a few of my favorite things.

C++, Anki, Mozilla, and Blizzard
Gandalf, and Turing, and all other wizards
John Stuart Mill and the Mandelbrot Set
Vincent van Gogh (and I’m not finished yet!)

Braid and the Triforce and Geno and Moogles
Trying out new applications of Google’s
Browsing on Wiki and laughing at Bing
These are a few of my favorite things!

When the news sucks
When the code breaks
When I feel like shit
I simply remember my favorite things
And then I get ohhhh…ver it!

Isomorphism and AI

In yesterday’s post I explained group isomorphism, which points out a deep symmetry between adding and multiplying. I also showed how the natural log function could be used to map between the two operations.

But the idea of isomorphism applies to lots of things beyond math. Think about language. After all, what is language but an isomorphism between concepts and words?

“The cat is black.” An AI could parse this sentence and decide there’s a noun-adjective relationship between “cat” and “black.” So instead of:

5 × 3

we have:

“cat” (noun-adjective relationship) “black”

To be meaningful, the words and their relationship must map to their corresponding concepts. So instead of:

ln(5) + ln(3)

we have:

cat (has-property relationship) black

And we also need a function to map from the words to the concepts. So instead of:

ln(5) = 1.609438

ln(3) = 1.098612

we have:

MeaningOf(“cat”) = cat

MeaningOf(“black”) = black

All very nice and neat, in this example. But of course, if language was really that easy, we’d have built a strong AI decades ago. It turns out that conceptual isomorphism can be a hell of a lot more complicated than mathematical group isomorphism. For instance…

1. Mathematical group operations (like addition and multiplication) only take two inputs (the two numbers you’re adding or multiplying). But conceptual relationships can take any number of inputs. How many adjectives could we attach to the single noun “cat”?

2. In mathematical groups, there’s a clear distinction between elements (the numbers) and operations (addition, multiplication). But with conceptual relationships, the difference gets blurry. Let’s say cat has a likes relationship with milk, and a hates relationship with bath. But we also know that likes has an is opposite relationship with hates. So now we have relationships, not only between “things,” but between other relationships.

3. In our math example, our mapping function was the natural log, ln(x). Now ln(x) is a neat, precise, clearly-defined function, which takes exactly one input and gives exactly one output. Does language work that way? Ha! Imagine trying to evaluate MeaningOf(“run”). That can mean jogging, or a home run in a baseball game, or a tear in a stocking, or “run” as in “I’ve run out of milk,” or, or, or… What’s worse, these meanings aren’t independent, but have all sorts of relationships to each other; nor are they all equally likely; and the likelihood depends on the context of the word; and the way it depends on context can change over time; and the list of possible meanings can expand or shrink; and the mechanisms by which this occurs are not fully understood…

So, yeah. It gets complicated. But then, that’s why it’s so much fun.

Now we know how conceptual isomorphism (in AI) is like group isomorphism (in math). We’ve even established – dare I say it? – an isomorphism between the two isomorphisms. And now I’m going to stop saying “isomorphism” for a while.

Questions?

Let’s Talk About Group Isomorphism

“Let’s talk about group isomorphism!” Said no one ever.

Group isomorphism is obscure, complicated, and technical. It’s also one of the coolest ideas I’ve ever encountered, one of those real wow! moments that changed the way I think about math, the universe and everything. And, I believe, it’s very relevant to AI.

So here’s the deal: I’ll do my best to lead you through the swamp, and in return, you’ll get a new perspective on mathematics – and maybe even the nature of intelligence. Agreed?

We’ll start with something simple. Or rather, two somethings: addition and multiplication, + and ×. Our old arithmetic friends. Can’t get much simpler than these guys, right?

6 + 8 = 14

3 × 7 = 21

Have you ever thought about how similar addition and multiplication are? Both of them take two numbers, do something mathy to them, and spit out another number.

In fact, the similarities don’t stop there. Both groups are also associative, meaning we can throw in parenthesis and it doesn’t change the answer:

(1 + 2) + 3 = 1 + (2 + 3) = 6

(2 × 3) × 5 = 2 × (3 × 5) = 30

That may not seem like much, but it’s a property subtraction doesn’t have.

Addition and multiplication also both have an identity element. For addition it’s zero, for multiplication it’s one. Either way, it doesn’t change the identity of whatever you pair it with.

5 + 0 = 5

7 × 1 = 7

What’s more, addition and multiplication both have the idea of an inverse. For any number, you can pair it with its inverse, and get the identity element.

18 + (-18) = 0

37 × (1/37) = 1

Addition and multiplication really are a lot alike, aren’t they? So much alike, in fact, that you almost get the feeling that at some deeper level, they’re doing the same thing, just with different symbols. Like they’re two different languages, and all we need is a translator…

In fact, you can translate (or “map”) between multiplication and addition. The key is the natural log function, ln(x).

For those who aren’t familiar with it, the natural log function is a button on any scientific calculator, and a function in Excel too (just type “=LN(5)” for example). If you want more details about what it actually means, Google is your friend. For now, what we care about is that it will translate between multiplication and addition.

What do I mean by that? Let’s see an example.

3 × 5 = 15

Well, ln(3) = 1.098612, and ln(5) = 1.609438, and ln(15) = 2.70805. These numbers may look like random garbage, but they have a remarkable property:

1.098612 + 1.609438 = 2.70805

(Ignoring rounding errors, of course.)

In other words:

ln(3) + ln(5) = ln(15)

There’s our translation.

Say we wanted to calculate 6 × 7, but we’re allergic to multiplication. We just can’t do it, for whatever reason. But we can do addition, and that’s all we need.

All I have to do is “translate” our multiplication problem into the language of addition, using the natural log function:

ln(6) = 1.791759

ln(7) = 1.94591

Now we’re in the world of addition, and I can do addition!

1.791759 + 1.94591 = 3.737669

We’ve got our answer! We just need to “translate” it back into multiplication world.

We know that ln(answer) = 3.737669. What we need is the ln function in reverse, a sort of un-natural-log, to go back to multiplication world. In mathematical terms, we’re looking for the inverse function, the function that will undo ln(x). As it happens, the inverse function for ln(x) is e^x, so we take e^3.737669 and get…

(drum roll please)

42, the answer to our original multiplication problem, 6 × 7.

Roughly speaking, addition and multiplication are known as groups in the mathematical sense. And because they are fundamentally the same, they are called isomorphic (“iso” means same, “morph” means form). Group isomorphism.

To me, it’s fascinating that addition and multiplication – which seem totally different on the surface – are somehow the exact same thing “under the covers.” Any result you derive for one operation can be “translated” to the other. Our world hides deeper symmetries than we suspect.

Tomorrow, I’ll show how some of those deeper symmetries apply to AI.

Questions?

Two-thirds

I’m sick today, so here’s a poem I wrote in college.

Two-thirds
Of a knight
Sits unmoving under burnished steel;
His sword, or someone’s, extends vertically
From a nearby shadow, pitted brick-red,
Similarly lifeless.
There are others –
Just as, on first sighting two leaves in the forest
So too are there “others.”
But the leaves, early fallen
From a blood-red autumn,
Are scarcely discernible through the surge of crows
Ebbing and roiling, black on black on black
In the lengthening twilight.

The vision dims halfway to reality.
The prophet is yet new;
Her eyes, still white with shock,
Have not yet faded into numbness
From a hundred such visions.
Presently she looks forward,
Sees again the eager boy – the soldier,
Registers his repeated question:
“Will we have victory today?”
– Victory. She does not immediately know this word,
This “victory.”
Which portion of the massacre
Corresponds to his query?
– But eventually, dutifully,
She picks out the banner
That has not yet been trampled by horse hooves
And compares with the boy’s insignia
To see if they match.

Friday Links

Trailer for the Ender’s Game movie! W00t!

Not sure what I think yet…could be good, but I’m not 100% sold. We’ll see.

robobee

Harvard’s created a flying robot, modeled loosely on insect anatomy, no larger than a quarter. Extremely light, highly mobile, potentially very cheap. Details and video!

yay text

A short essay proposing dead children as a unit of currency. The thesis is deliberately shocking, but he’s making a real (and kind-hearted) point about charity and opportunity costs. This is actually fairly close to the way I think about things, and it gets to the heart of my post on Monday, The Perils of Virtue.

quadrotor

xkcd proposes an alternate use for quadrotors.

dark hanners

And Questionable Content turns to the Dark Side. Uh, briefly.

That’s that, Hypothetical Reader. You may be a construct of my solipsistic hallucinations, but I like you all the same. This weekend, go forth and be excellent, and we’ll meet again three days hence!

Brian Buys a Unicycle

For a long time, I’ve thought it would be cool to know how to unicycle. Probably for the same reason I learned how to juggle: chicks dig it. (NOTE. This is not accurate.)

Last week, I was at the park (outside!) with a group of friends, and one of them brought a unicycle. He rode it around a little, and the rest of us tried to. To get an idea of our success rate, imagine a herd of antelope learning to touch-type, and that should get you pretty close. Still, I had fun, and was fascinated by this one-wheeled monstrosity.

I had to have one.

After doing a little research, I ordered this bad boy…and then waited. Yesterday, it arrived.

Not pictured: my neighbors pointing at me and saying "Why the hell is he photographing a cardboard box?"

Not pictured: my neighbors pointing at me, saying “Why the hell is he photographing a cardboard box?”

Bubbly as a can of Faygo, I carted my prize to the back of the house to assemble it.

Carrot-flavored, my favorite.

Carrot-flavored, my favorite.

The instructions said it could be assembled in 15 minutes. Knowing my own technical expertise, I mentally adjusted this to “four days,” but in the end I was surprisingly successful. Using a couple of wrenches from my wife’s toolbox, and making a quick run to the local Speedway to inflate the tire, I got it together in about an hour.

And here she is:

Shown in the vertical position. In my experience, the horizontal orientation is more frequent.

Shown in the vertical orientation. In my experience, horizontal is more realistic.

If the seat seems pretty high up, it’s because I am freakishly tall.

Sadly I don’t have any pictures (yet) of me trying to ride it. Betsy was away at the time, and the list of Ways To Make Unicycle-Riding Easier does not include Trying To Take a Picture of Yourself While Doing It. But my method’s pretty simple: find something to lean against for stability (like a tree, or a bench) and get on the seat, pushing down on one pedal to steady yourself. Then put your other foot on the other pedal, find your balance, release your support, and go.

Experiments thus far have shown the “and go” step to be significantly more difficult than the others. I do in fact go, but the direction is mostly earthward.

It’s pretty clear, when you’re sitting on a unicycle, that this is not something God intended humans to ride. A little-known fact about unicycles is that they only have one wheel. When you’re watching someone else unicycling, it looks cool; when you’re trying to do it yourself, you wonder if you might be mildly retarded.

My friend said he never got hurt learning to unicycle. You fall a lot, he said, but since your instinct is to put out your feet, you generally don’t fall down.

This was, of course, a transparent lie. I had my first legit fall after about two dozen tries:

unicycle fail

I admit this is not a very badass scratch. But give it time.

I love it anyway. Can’t wait to try it again tonight!

On Saying Goodbye

The snow has not yet fallen. Our intertwined
fingers find needful solace
in the tightness of affection;
and delaying the kiss
that will end it, I perceive
that love is like sleeping.
My dreams glide into yours
and meet in the halo of our intertwined
vision – I am sleeping,
and though I know that December
apart is livable (for I have breathed
the icy air before, and found it
non-toxic) – though I know this, I delay,
clinging to the melting moments of our intertwined
whispers – for, like any sleeper,
what I fear is not consciousness, but
waking.

(I wrote this November 29, 2006.)

The Largest Living Thing in the World

My About Page claims: “I have personally seen the largest living thing in the world.”

Here’s the proof:

Click to enlarge.

Click to enlarge. Not that it needs to get any bigger.

I took this photo of the General Sherman Tree in Sequoia National Park, California, on June 17, 2005. It was part of a two-week road trip out west with two of my best friends, both of whom are probably reading this right now.

Sherman’s status as the largest living thing is debatable, but all other claimants to the throne are superorganisms of some kind – at least from what I’ve seen. If anyone knows a specific organism that’s bigger, I’d be interested to hear about it.

Even if there is something bigger, it’d be tough to look much more impressive.

The Perils of Virtue

What does it mean to be a good person?

Years ago, I read one of John Steinbeck’s lesser-known books, a thin novel called The Short Reign of Pippin IV. I stumbled across this passage, which struck me so keenly that I copied it down right then, and have never forgotten it:

“It is a trap,” said Sister Hyacinthe, “like all other virtue – it is a trap. Where virtue is involved it is very difficult to tell oneself the truth, M’sieur. There are two kinds of virtue. One is passionate ambition and the other simply a desire for the peace which comes from not giving anyone any trouble.”

There are, indeed, two kinds of virtue: passive and active.

Passive virtue is what Steinbeck calls not giving anyone any trouble. More recently, Wil Wheaton formulated this as Wheaton’s Law: “Don’t be a dick.” Passive virtue says you can be good merely by not being bad.

Active virtue, however – Steinbeck’s passionate ambition – is very different. For active virtue, it isn’t enough to sit back, smile, and say “I’m not hurting anyone.” Active virtue demands that we go into the world and make it better.

Our society and our laws say that passive virtue is good enough. Active virtue is optional. This makes sense – for law and society. You can’t require passionate ambition, after all.

But suppose we care about more than just following the law and doing what society expects. Suppose we hope to be something like that most mythical of creatures: the Good Person. Is passive virtue really enough?

Imagine you’re leading a caravan through the Sahara Desert. You find some poor man dying of thirst, begging you for water. You have plenty to spare. But you say “I believe in Passive Virtue. I’m not required to help. I merely avoid starting any trouble.” You move on.

Is that okay?

Of course not. In Wil Wheaton’s terms, you are Being A Dick, even though you’ve technically satisfied passive virtue. That much seems obvious.

But be careful. Because once you admit to yourself that you have a requirement – a moral obligation – to help others, the world becomes a very different place.

Before, as a follower of Passive Virtue, you could spend twenty dollars on a couple of movie tickets and popcorn. You’re not hurting anyone, so it’s okay. But Active Virtue imposes a much heavier burden. Active Virtue insists the world is full of people dying of thirst, metaphorically and literally. It says that spending twenty dollars on entertainment is like pouring out water on the sand of the Sahara.

If giving twenty dollars to Doctors Without Borders, or the aid workers in Syrian refugee camps, or [insert your charity here], could save someone’s life, and I spend it on movies anyway, what does that mean? It sounds absurd to say that buying entertainment is ethically wrong, but what other conclusion can we draw?

How can we escape the obligation to spend all our money, all our time, all our resources, on helping others? And why should we want to?

We want our lives to be easy. That’s human nature. But being a good person means active virtue; and active virtue is very, very hard.

I’m as guilty as anyone. I won’t pretend otherwise. I buy all sorts of things I don’t need.

But in quieter moments, I can hear what virtue sounds like – and it sounds awfully distant to me.

What do you think?