2010-04-30

Spirit Sol 471

It's a commonplace among engineers that you do your best work in the shower. Your mind and body are relaxed, and you see solutions that you just don't see under other circumstances.

That's not to say you always like the answers you get. While I'm getting ready in the morning, I realize we completely screwed up the huge MI mosaic of Keystone. It's the largest MI mosaic of a single object ever; it took about three hours for the IDD to do the work; and I single-handedly managed to get nearly all of the images out of focus. I've got my eyes closed, I'm putting on the shampoo, and suddenly I visualize the relationship between the rock face and the motion of the IDD as it moves the MI across the surface, and it becomes blindingly clear that the angle is completely wrong for the majority of the surface.

See, the MI has a very shallow field of view. You can think of it as being like a small square sheet of paper, held about 4.6cm (call it two inches) in front of the lens. The "piece of paper" is maybe 3cm on a side and 3mm thick -- maybe instead of a single sheet of paper, you should think of it as a pad of just a few Post-It notes. Anything not within that volume will be either invisible or unfocused. If you look at a surface at too oblique an angle, most of the "notepad" will be either above or below that surface. A small amount of the image will be in focus, but most won't.

We held the paper at the wrong angle.

Some small fraction of the MIs will be in focus, but most won't. We basically just blew two or three sols, four or five hours of IDD actuator life, and hundreds of megabits of downlink. And it's all my fault.

I get to JPL a little early, anxious to know how bad the situation is. Nobody says anything in particular to me, which is usually a bad sign. I fire up mphoto (the image browser application I wrote during solar conjunction), bring up the MI thumbnails, and click on one of them. It happens to be one of the in-focus images, and looks pretty good. Then I click on another one. It's in focus, too. I click on a few more. They're all in focus.

Um. Evidently, I was mistaken. Happily, it would seem that I do better IDD work in the sequencing room than in the shower after all.

And I realize I'm now the holder of another record (not that any of us holds these individually, of course; it's always a team effort). Not only am I the single-sol distance-record holder on both sides of Mars, I've now also done the most MIs of a single object ever.

And they're even in focus!

Sadly, the MI sky flats don't work out again -- there's no time to do them in the weekend plan. When they officially sink the idea, I hit the mike and say, "Screw you guys, I'm doing it anyway!" Which provokes a laugh, and Ken says, "Go, Scott!" But he's philosophical about the lost chance: "I waited 400 sols, I can wait a little longer."

I did make one mistake in the MI sequence. We were performing the MI mosaic in six columns of four stacks apiece, covering the broad rectangular face of Keystone. Now, normally, we take an image of the IDD each time we place an instrument, taking higher-quality images when we place the MI to give us data points for calibrating the HAZCAMs. (When the MI is down, the MB is up, right where the cameras can see it, and its shiny contact ring is easy to pick out in the images.) But we didn't want to spend time or downlink volume taking those images for every stack, since there were so many. Instead, we want to image the IDD only once per column.

So I came up with a clever way to do that. When we're driving, we sometimes use the OK-to-IDD flag as a simple marker -- for instance, if we get to a certain point in the drive, we drop the OK-to-IDD flag. Then later on, the sequence checks if it's OK to IDD; if not, we know we got that far in the sequence and can do something special for that case. So I figured, why not turn that around? In the backbone sequence, we'll drop the OK-to-drive flag as we start each column, then make four calls to the helper sequence (each call to the helper sequence performs one stack and moves to set up for the next stack). The helper sequence will check whether it's OK to drive and, if not, will take the IDD image and then re-raise the flag so that the next call to the helper sequence won't take the image. That way, we'll take the image for only the first stack in each quartet.

Like so many solutions, this one is simple, elegant, and wrong. What I stupidly forgot was that when the IDD is unstowed, we're never OK to drive. So instead of imaging the IDD placement on every fourth call to the helper, we imaged it on every call -- sixteen IDD placement images, not four. And we reused that code when we completed the mosaic, so we're going to repeat the mistake. Oops.

So we got a whole bunch of images of the IDD moving across the surface. High-quality images. Hey ... on a whim, I make a simple animation and project it on the shared screen in the sequencing room. It's awesome -- not only do you see the IDD doing its thing, you even see the rover's own shadow marching away as the sun passes overhead. Steve sees the movie and loves it. "Maybe we should do more things like this," he remarks.

"Yeah, if only all our mistakes turned out this well," I reply.

Brenda Franklin also pipes up. "When life gives you lemons, make lemonade. This is lemonade. This is lemonade with whiskey!"

"Hey, you know what you should do?" Steve says. "You should send this to Guy Webster!" (That's JPL's main press dude for MER.) "When we release the MI mosaic, we can release this movie to go along with it."

Which is a great idea, and displays Steve's flair for outreach. So I put together a version of the movie for release -- actually, two versions, one from each eye -- and email the press people about it. We'll see what happens.[1]

I finish up the sequencing and hand over to Chris, then hang out to work on some other stuff. A little later, Steve comes on the teleconference line again. This time he's raving about the MIs. You can practically hear him jumping up and down with excitement. "Those MIs just look great!" he exclaims. "This is gonna be one of the premier data sets of the mission. I just talked to Ken, and they're going crazy in Flagstaff!" (This is not some strange expression; Flagstaff -- the University of Arizona -- is where Ken and his team are.)

I couldn't be happier, especially since this is the exact diametrical polar opposite of what I expected to hear when I came in today. I tell Steve I'll pass his message along to Chris and Ashitey, and I do.

Steve's got one more thing to mention. He was unable to cover the SOWG meeting this morning because he was teaching a class -- "Astrophysics 102 -- 300 students. At the start of every class, I give them a five-minute update on what's going on on Mars. It's the only part they pay attention for."

[Next post: sol 476, May 5.]





Courtesy NASA/JPL-Caltech. An accidental animation of the first sol's work on Keystone: best mistake ever. Follow the link for a full-sized version.


Courtesy NASA/JPL-Caltech. The mosaic of MI images on Keystone. Again, follow the link to get a full-sized version.




[1] As always, Steve's instincts were spot on. They loved it. They released the animation at the same time as the Keystone press release, and it's shown up more places than I can count since then. Best mistake ever.

5 comments:

jhjessup said...

Very nice!

Why is "Image Addition" date on Nasa's page show May 24, 2005?

(http://photojournal.jpl.nasa.gov/catalog/PIA07982)

Anonymous said...

Very cool! Saved!

Scott Maxwell said...

@jhjessup I might misunderstand your question, but since this has confused people before: this blog is, deliberately, five years behind the times. Though they were written in the moment (so to speak), I started posting them five years after the events they describe.

Anonymous said...

You should add the matching Earth date to each entry's title, to reduce that confusion.

AySz88 said...

I was lucky enough to be in one of Squyres's classes (ASTRO 280, Space Exploration), where he did the same thing for us. (Actually, if you happen to be in Ithaca, I think you can just stop by and listen in even if you're not in the class, as long as you're subtle about it.) Incredible experience, getting an inside peek at what's going on with the rovers every day.

You're pretty much doing the same thing for a broader audience with this blog here (even if 5 years delayed). :)