Wednesday, January 31, 2007

That Was Bullshit

My faith in reality television is shattered.

Tuesday, January 30, 2007

Top Chef Pre-Show

Are you psyched for the finale?! If Ilan wins, I think I might cry. Here's my attempt at an objective assessment.

Marcel

Pros: He's creative and interesting. He has a sense of humor about himself and a remarkably professional attitude towards those who teased, taunted, and assaulted him. His colleagues at The Mansion seem to respect him, even if none of his fellow contestants did. He kicked ass last week.

Cons: He didn't make a single memorably delicious-seeming dish all season. He seems to lack some basic cooking chops and gets lost when he doesn't have access to xanthan gum or a thermal immersion circulator. He made foams at least as often as Sam made pickles. And, it must be noted, almost everybody on the show hated him.


Ilan


Pros: He seems to be a skilled cook. He has prepared several dishes through the season that look delicious and which the judges all enjoyed. He showed some leadership skills in the course of the season.

Cons: The leadership he showed was in inspiring others to hate Marcel. So, more your cold prickly Hitler-y leadership,* not your warm fuzzy FDR-y stuff. He's an asshole. Every successful dish he made (e.g., paella, fideos) could have come (did come?) from the menu of his restaurant. The things he made that weren't classic Spanish recipes (e.g., chocolate-covered liver) were often disgusting. Both Gail and Padma seemed ready to send him home last week.**

My Prediction: Marcel by a nose.***

Bonus Prediction: The final Elimination Challenge will not bring back previously eliminated contestants to work under the finalists: this set-up hurt Tiffani's chances last year (recall that all four helper chefs, including her own teammates, picked Harold to win) and it would probably be ruinous to Marcel. I could swear there was promo footage of Stephen Asprinio towards the beginning of the season... Maybe they'll bring back last year's contestants as kitchen helpers? Stephen and Marcel would make a great team...

* Hell yeah, I just went there.
** Although I am typically a very credulous reality television viewer, I must say that choosing Ilan over Sam last week seems to betray an interest in "good television" over "good food."
*** The "by a nose" bit is meaningless. The judge's always present it as if it's "by a nose," especially in the finale.

UPDATE: I meant to say, also, that it is obviously the case that neither Marcel nor Ilan can hold a candle to Harold (or even Tiffani) (and probably Lee Anne). That said, I will note that this is a cooking-themed reality television show and not an objective search for the Best Chef in the Universe. (I believe that's called The Next Food Network Star.) You gotta play them as they lay.

The Ic Factor

Note to George Bush: It's called the Democratic party, and you sound like an asshole. (What's new?) (Via les commentaires de Sausagely)

(Actual) Fun at the Post Office

After my griping of this morning, it's only fair that I report on my trip to hand H's mysterious package to a postal employee in person. Before I had even gotten in line, a man magically appeared from the back room of the post office and asked me if my package had correct postage pre-applied. I told him it did and pointed to the admonitory stickers affixed. He took the package from me and disappeared into the back room, almost before I could thank him. I was in the post office for less than two minutes.

Now I only hope we don't get it back with more stickers.

BSG 3.13: "Taking a Break from All Your Worries"

Yeah, this episode reminded me of "Cheers."

Despite its use of one of my great filmic pet peeves, the revelatory dream sequence, this was one of my favorite episodes in a long time. I have little patience for the "mythological" elements of the show (e.g., the Arrow of Apollo, the Eye of Jupiter, and the Quest for Earth) and this season has been thick with them. Consequently, there have been episodes this season (particularly 3.5, "Torn," the episode that took us inside a Cylon basestar for the first time, alongside Baltar) that bored me senseless. I think the show is strongest when it's dealing with the grim reality of its characters' situation, sucking in the bleakest realities of our modern age and remixing/re-contextualizing them in surprising and insightful ways. We got a bit of that this week, a little canon of coercive interrogation with an unexpected hint of MK-ULTRA, and the promise of more to come (does anybody think the trial of Gaius Baltar may contain a dash or two of Saddam Hussein?).

Query the First: Given that BSG has a habit of omitting key events in character's relationships until they become dramatically useful (e.g., the tryst between Apollo and Starbuck that occurred half a season before we got a hint of it) and given the odd and inappropriate snuggling between Laura Roslin and Admiral Adama in this and previous episodes (see 3.9, "Unfinished Business"), may I assume their relationship is sexual in nature?

Query the Second: In this season, we have: Helo sabotaging a plan that could have ended the human/Cylon war forever (3.7, "A Measure of Salvation"); Helo "delivering" Sharon to the Cylons, to whom she may have provided sensitive intelligence (3.11, "Rapture); and Gaeta stabbing a high-value detainee in the neck. Again, I ask: is there anything a person can do to get court-martialled on this ship?

Query the Third: Is it "court-martialled" or "court-martialed"? Google is inconclusive. Blogger doesn't like me verbing "martial".

Fun at the Post Office

The post office has some odd rules that seem crudely designed to discourage people from mailing bombs or anthrax. For instance, you probably know that a return address is now required for all mail, lest if be delayed as "suspicious." A related rule is that a package may not display any "advertisements" (i.e., names or logos) for any company that is not the sender. It is not enough to scribble out a logo with a marker; one must cover it with brown paper-backed packing tape. Postal employees make compliance with this rule especially pleasant by being both inconsistent and snide about it.

A rule which is new to me is, I think, as follows: if a package weighs more than a pound and the postage is affixed in the form of stamps, then the package must be presented in person to a post office employee. This means: don't put it in the automated service kiosk and don't hand it to the guy in your office mail room. H tried to send a package to her cousin last week and decided to use some very old stamps I've had since five first-class postage rates ago (they were very nice "collectible" stamps that were given to me as a gift and I want to "ruin" them by using them for postage... because I'm a friggin' idiot). The package was actually delivered back to us, with several bright green stickers explaining why a piece of mail with adequate postage would not be forwarded to its recipient. (One nice thing is that they didn't cancel the postage.)

The box is now sitting in the living room, waiting for one of us to face the living death that is standing in line at the post office. Be warned.

UPDATE: That's weird. I just had my all-time least aggravating trip to the post office.

Saturday, January 27, 2007

Linux Wireless: Almost There

I finally gave up on ever getting my old Broadcom BCM4401 wireless card to work under Linux, so I went out and bought an Intel 3945ABG card (which is actually one of the cards Dell ships with my laptop model, just not the one I happened to get (through no fault of my own)). Out-of-the-box support from the stock ipw3945 driver. Plays nice with the Network Manager and the proprietary nVidia driver. Suspend works. Sweet.

Having taken a moment to appreciate this vast improvement in my computing situation, I will now proceed to bitch. Every now and then---say every 3rd or 4th time I suspend---the wireless card doesn't come on after I resume. All I have to do is "rmmod ipw3945; modprobe ipw3945" and it comes back fine (which is better than manually fussing with the ESSID, which I have often had to do in the past).

I filed a bug on this and one of the maintainers suggested I add the module to the "suspend blacklist". I politely asked both the maintainer and Google what and where the "suspend blacklist" is, but I've gotten no answers. There's a bunch of scripts in /etc/acpi that seem relevant, but from what I can tell, they should already being doing what I want to hack them to do. Which might mean they're not even being used anywhere anyway...

At less frequent intervals---say every 9th or 10th time I suspend---the module is "busy" when I try the unload/reload step and I have to reboot to get things back in order. I can't figure out how to find out which process has a lock on the module either...

Bah!

Wednesday, January 24, 2007

The Penultimate Chef

Wow, I thought Sam was going to take it. Marcel really stepped up and cooked this week. And Elia took a nose dive, from sweet and talented to just another bully to clawing desperately on her way out. What is wrong with her? And what is wrong with Ilan? Which do you think is more debilitating: Ilan's inability to sac up and just pretend Marcel doesn't exist, or Ilan's inability to cook anything that doesn't contain saffron?

P.S. There goes the prevailing Internet theory that the timeline manipulation (and ex post Elia-cropping) in the last episode was meant to whitewash Elia's involvement in the whole affair because she was the winner... What's the deal, Bravo? Because, if Ilan wins, none of your editing did anything to make him look any less like a quivering sack of shit... And it's got all the Internets confused and paranoid...

Sunday, January 21, 2007

Presidential Cohorts

The presidents from JFK to Bush I (1960-1992) were all born between 1908 and 1924. That is to say, over 32 years the presidency was held by an age cohort (the World War II generation) of just 16 years. Both Clinton and George W. Bush were born in 1946, a gap of 22 years from the next-youngest presidents (Carter and George H.W. Bush). The only failed major-party nominees who fall into this gap are: Walter Mondale (b. 1928), Michael Dukakis (b. 1933), and John Kerry (b. 1943). Nobody born between 1924 and 1943 has even come close to being the president. I don't have the time to look up all the 12 million people who are running in 2008, but I'm sure John McCain is the oldest and he was born in 1936. If he is elected (and he won't be, knock wood), he would be the first (and almost certainly the only) president born in the 1930s. What's the deal? Were all the children born of the depression jerks or what?

Now that I look at it, there's a similar gap from Eisenhower (born 1890) to Johnson (born 1908). Since there's only one or two presidents a decade, on average, it sort of makes sense that the birth distribution would be uneven. But still, isn't it strange that an entire generation didn't bring forth one worthy man? Who's the all time best Washington politician born 1924-1946? Bernie Sanders? Daniel Patrick Moynihan? Dick Cheney?

The BSG is Back

A pretty strong start to the second half of the season, but... I'm losing track of which Cylons are which. And tell me: is there anything Helo could possibly do to get charged with treason? Anything at all?

P.S. If there's anyone in the world who actually checked out Battlestar Galactica this season on my recommendation, I apologize. I mean, did you understand a single word?

Printing on Index Cards*

Fun! Preferably, the document in question will already be in a 3x5 layout. I recommend Adobe Acrobat Reader and not one of your light-weight and/or free alternatives. Now, just because you have a printer preset called "Index Cards" doesn't mean you can just go hitting Ctrl-P and expect things to work. Go to "File -> Print Settings" and choose "Index Cards" in there. Now hit Ctrl-P and maybe "Index Cards" is already chosen or maybe you should choose it now. Cross your fingers and go for it.

* This post assumes that you already set up your index card presets a year ago and have merely forgotten how to use them. I.e., that you are me. Good luck to everybody else.

Top Chef Rashomon

I wasn't going to blog about this week's Top Chef---partly because Tom Colicchio already said pretty much exactly what I was thinking---but I'm doing some late-night web surfing while I wait for some evening coffee to wear off and I come across this stunning little factoid: the footage was edited in a way that tends to cast the participants in the "prank" in a more positive light (WTF?): they were yucking it up and shaving their heads after Cliff assaulted Marcel and, according to Marcel, the assault didn't end when he broke free and left the room. (Via Reality Blurred and Java Junkie.) From there, things get way out of hand... We have people analyzing the lighting and video quality in the footage and digging up new conspiracies.

And here's an interview---conducted before this episode aired, but months after the events depicted---with Sam, Ilan, and Cliff being totally unrepentant (which you might also guess from Ilan's---possibly fake---MySpace page). Way to class it up, boys.

P.S. Besides being a passive-aggressive jack-off, I couldn't believe Sam's whole wuss-bag, "I'll do it if you do. No, not really. You guys are crazy!" attitude about the head shaving. It's "crazy" to cut your hair really short? Even for a man? (And how long was Ilan's hair, anyway? About two inches?) Maybe it's "crazy" when your lustrous, flowing tresses got you voted New York's Sexiest Chef...?

Thursday, January 18, 2007

Why It's OK to Agree with Hippies

LizardBreath makes the case for carrying puppets:


My knee-jerk reaction to "hippies", any sort of silly, embarrassing leftists, is that while I don't want to be seen with them, I probably agree with them about most things. Even if their politics are reflexive and not well thought out, they're using basically the right rules of thumb, and on any issue that I haven't thought out thoroughly myself, I'm more likely than not to come down on the same side as they do. Where I haven't figured out an opinion that I can solidly back up yet, and usually where I have, I'm lining up with the people dressed as sea turtles...

You can't successfully get anything right by trying to avoid agreeing with silly people. There are too many silly people, and they're all over the map -- no matter how sane, or well reasoned, or intelligent some position is, some absolute ninny out there agrees with it. The best thing to do is not to let prejudice affect your decision-making. But if you're going to be swayed by prejudice, and we all are, trying to avoid idiots is going to lead you astray -- better you should align yourself with the gang of idiots who you think have the best track record generally.


Follow those liberal idiots!

Wednesday, January 17, 2007

Wiki Spam II

The preceding flurry of posts was brought on by the imminent demise of my Columbia student account, my inability to get the PHP-based PmWiki working on the NYU servers, and my realization that all of the code supporting community editing of this stuff was a waste of bits. Whereas this blog is the most parsimonious use of bits imaginable. Have a nice day.

Printing LNCS format PDFs

(Non-academics: just scratch your head and walk away...)

[UPDATE 4/15/2008] I've created a shell script that simplifies the process described below: it takes an LNCS-formatted PDF or Postscript file and generates a 2-up Postscript using acroread (for PDF inputs) and pstops. Download here. Note: The script will probably have to be tweaked for system-specific pstops settings, as below.

[UPDATE 3/12/2007] The right parameters for this turn out to be a constantly moving target. Here's the command that currently works best for me on Ubuntu Gutsy:

pstops '2:0L@.8(8.5in,-.25in)+1L@.8(8.5in,4.5in)' lncsdoc.ps lncsdoc.2up.ps


So you can make up your own mind whether I'm crazy for giving this any though at all, here's a comparison on a paper I just happen to be reading today.

Standard LNCS format (2 pages):

Those are (approximately) 2 inch margins and a 12+ point font. (The copyright notice eats into the bottom margin a bit at left, but it's not present past page one.)

Using GNOME/Evince standard "Pages per side: 2" print option:

Look at that gutter! The bottom margin is more than 3 inches.

Using acroread -toPostScript and the above pstops command:

Better...

It's totally not worth it, is it?
[/UPDATE]

[Editor's Note] This is old material imported from my now-defunct Wiki

LNCS format papers from SpringerLink have always been a frustration to me. They are an odd digest size (not letter, A4, or A3, AFAIK) with wide margins. Printing them 1-to-1 on letter paper is a waste---the font blows up to almost 14 points with 2 inch margines. Printing them naively 2-to-1 landscape letter makes the font too small and the margins too big (especially down the middle).

I just spent a few minutes hacking up a solution with pstops (part of psutils). Here it is:

acroread -toPostScript -size letter \
lncsdoc.pdf
pstops '2:0L@.7(8in,0)+1L@.7(8in,5in)' \
lncsdoc.ps lncsdoc.2up.ps
ps2pdf lncsdoc.2up.ps lncsdoc.2up.pdf

I've tested this on a few papers and it seems to work.

Caveats: It might generate sub-optimal or even broken Postscript (Acrobat Reader seems less happy with the final PDF than it is with the original, maybe just because there's twice as much PS data on each page). The file lncsDoc.2up.ps doesn't have the right size and orientation parameters in GhostView. The parameters to pstops may be installation-specific.

For the pstops-curious, the second command does the following:

2: - groups the input pages by twos
0L - takes the first page of each pair and rotates it left
@.7 - then scales it down by 0.7
(8in,0) - then moves it 8 inches down (the point of rotation seems to be the lower left corner, meaning without translation, the rotated (logical) page is no longer on the (physical) page)
+1L - takes the second page of each pair and rotates it left
@.7 - then scales it down by 0.7
(8in,5in) - then moves it 8 inches down and 5 inches across (I guess the left/right pages start from the same point!)

Modifications to the scaling factor and translation are all that should be necessary for personal taste/local compatibility.

Alternative One-liner

cat lncsdoc.pdf | \
acroread -toPostScript -size letter | \
pstops '2:0L@.7(8in,0)+1@.7L(8in,5in)' \
> lncsdoc.2up.ps

Caveats: The generated PS file doesn't work with ps2pdf, for some reason. It also didn't print the last page, when I used lpr on it. It looks like somehow the PS file doesn't get properly closed off. Suggestions are welcome.

Alternative Non-Adobe Solution

The following works, but produces awful screen output. I guess pdf2ps doesn't get the right fonts or something. It also has the wrong orientation in both GhostView and Acrobat Reader.

pdf2ps lncsdoc.pdf lncsdoc.ps
pstops \
'2:0L@.85(7.75in,0.5in)+1L@.85(7.75in,5.5in)' \
lncsdoc.ps lncsdoc.2up.ps
ps2pdf lncsdoc.2up.ps lncsdoc.2up.pdf

I'm not sure if pdf2ps is a standard utility or just some random thing I downloaded (from here for example). It boils down to the following:

gs -q -dNOPAUSE -dBATCH -dSAFER -sDEVICE=pswrite \
-sOutputFile=lncsdoc.ps -c save pop \
-f lncsdoc.pdf

Where gs is your friendly local GhostScript install.

NOTE: This may be applicable to other Springer formats, but I'm not familiar with them.

Windows XP to A4 paper

pstops '2:0L@.85(9.5in,-.5in)+1L@.85(9.5in,5in)' \
lncsdoc.ps lncsdoc.2up.ps

Or is it better to just scale up with pstops and let psnup do the rest?

pstops \
'2:0@1.3(-22mm,-58mm),1@1.3(-48mm,-58mm)' \
lncsdoc.ps | psnup -2 > lncsdoc.2up.ps

The former file is a little smaller. And they both look bad in GSview.

Restaurants In Japan

[Editor's Note] This is old material imported from my now-defunct Wiki

Here's the first thing you need to know about Japan: you're not going to find anything if you don't have a map, preferably a map with the thing you're trying to find clearly marked on it. If you buy a guidebook, it will warn you that things are hard to find. This is a lie. Things are impossible to find. Very few streets have names, very few buildings are numbered, and very few numbers go in order. Outside of Tokyo, and even in the less touristy parts of Tokyo, very few businesses have Roman script on their signs---an establishment's name written in kanji is an essential item for finding anything.

The second thing you have to know: if your Tokyo guidebook is more than a year out of date, it will be almost completely worthless for restaurant recommendations. Said worthlessness will be disguised for a time by the difficulty of finding anything, but eventually you will figure out that the restuarant you are looking for is not just very hard to find, but non-existent. In fairness, the guidebooks will suggest that calling ahead is a good idea. In fact, if you have your heart set on eating at a particular restaurant, calling ahead is absolutely required, or else your heart might very well get broken.

The good news is, if you're willing to eat almost nothing but noodles and rice, you can get a decent meal at almost any ramen, udon, or soba shop you pass. Tasty, filling, and usually pretty cheap.

I spent my honeymoon in Japan in June 2005 with the guidance of Time Out Tokyo (3rd edition 2003) and Lonely Planet Japan (8th edition 2003). Here are some addenda for travellers of the future.

Time Out Tokyo

Time Out does not give the kanji for anything. Outside of the central city, this can be a problem.

Edogin

(p. 125) Couldn't find it. Ended up at a perfectly wonderful, seemingly quite popular place in the same area near the fish market. (BTW, the guide books aren't kidding when they say to arrive early for the fish market. We got there around 11 AM and it was like a ghost town---no signs of commercial activity whatsoever.)

Ikebukuro Gyoza Stadium

(p. 128) This exists and is in fact quite easy to find. Time Out errs in not making it clear how strange and interesting this theme park dedicated to steamed and fried dumplings is to the Western visitor. Definitely check this out.

Bangkok

(p. 128) Couldn't find it. In addition, Roppongi is overrated. Like Bourbon Street mixed with Times Square. (Every neighborhood in central Tokyo is like something mixed with Times Square.) We ended up at Freshness Burger, which wasn't too bad, if a little stingy with the meat.

Pumpkin Cook Katsura

(p. 148) We scoured the neighborhood looking for this restaurant and I'm pretty confident in saying it doesn't exist. Kiddy Land, around the corner from where this restuarant used to be on Omotesando, is a great place to stop for Japanese toys.

Senba

(p. 149) We were pretty tired of searching for restaurants when we came looking for this one, but I'm pretty sure it's not there.

Lonely Planet Japan (Tokyo)

Lonely Planet gives the kanji for all the restaurants (and other sites) that appear on the neighborhood maps. Location on a map + kanji = good stuff.

Keika Kumamoto Ramen

(p. 194) No English sign; kind of a surprisingly dumpy little place. But the ramen was quite good. The salad comes with corn flakes.

Junikagetsu

(p. 196) No longer exists. This was kind of mind-bending, because this was kind of a "food mall" that occupied a whole block. We thought we might be losing our minds when we couldn't find it. But the waiter at the (very tasty) okinamaya restaurant on the 4th or 5th floor across the street confirmed that the building had been torn down and replaced with a mall full of clothing stores.

Lonely Planet Japan (Kyoto)

Tagoto Honten

(p. 366) Don't be fooled by the description of this restauarant as "one of Kyoto's oldest" soba restaurants: it is located in a shopping arcade and looks brand new. We walked past this several times before we realized it was the place. There is no English sign, as I recall.

Morita-ya

(p. 367) We found this one, though not with the help of an English sign. It is quite good, though fairly expensive and has a very pleasant deck on the river.

Omen

(p. 369) Found this one with no problem, just a few blocks off the Philosopher's Walk.

Harajuku Girls

Not a restaurant, but none of the guide books make it clear that the infamous fashionistas of Harajuku show up in full force on Sunday afternoon, in the square just South of the JR station. You will see the odd Gothic Lolita on other days of the week, but Sunday is the day to see them on parade in Harajuku.

Development Tools on Mac OS X

[Editor's Note] This is old material imported from my now-defunct Wiki

I've been using Mac OS X 10.3 (Panther) since it was released. I regularly use Unix tools like make, gcc, latex, etc. I recently had a catastrophic hard disk failure and just got around to re-installing my development environment. The hard disk came from the shop loaded with the OS, but no Developer Tools. I put in my XCode Tools install disc and installed all of the Apple Developer Tools. Afterwards, I got the following error trying to run gcc on anything:

  % gcc t.c
ld: can't locate file for: -lcrt1.o

Thanks to Dan Smith on MacInTouch I discovered my re-install routine wasn't sufficient. The repair shop probably installed the OS off a backup disk that didn't include development libraries; the XCode disc isn't careful about checking library dependencies.

If you're installing development tools on a fresh hard disk (or even a brand new Mac, probably), you need to make sure you have the following files in /usr/lib: bundle1.o, crt1.o, dylib1.o and gcrt1.o. If they're not there, either: (1) do a fresh install off the OS discs, or (2) download and run the full XCode 1.1 or 1.2 installer from the Apple Developer Site (Log In (free registration) -> Downloads -> Mac OS X -> XCode Tools).

Problems with Ghostview

After installing Fink 0.7.2 and using it to install Ghostview 3.6.1-4, I got the following error trying to run gv:

  % gv
Warning: Representation size 4 must match superclass's to override highlightedBackground
Warning: Unsupported shape style for Command widget "toggleCurrent"
Warning: Unsupported shape style for Command widget "toggleEven"
Warning: Unsupported shape style for Command widget "toggleOdd"
Warning: Unsupported shape style for Command widget "unmarkAll"
Warning: Unsupported shape style for Command widget "autoResize"
Warning: Representation size 2 must match superclass's to override internalWidth
Bus error

This is apparently a problem with the Fink binary distro of gv. If you rebuild from source (i.e., fink rebuild gv) it should work fine (assuming that all of your X11 dev libraries are set up right---don't let Fink install XFree86 over your Apple X11 install! (Unless, of course, you know what you are doing)), .

Links

MacInTouch has an incredibly large collection of tips for Panther users, as well as for all kinds of other Mac-related subjects.

LaTeX

[Editor's Note] This is old material imported from my now-defunct Wiki

Here's where things about LaTeX get discussed. I'll have you know that WikiWords kind of drive me nuts and the title of this page should give you a hint why.

The single best hint I can give anyone using LaTeX is to bookmark /usr/share/texmf/doc/index.html. (This is assuming a standard teTeX installation (including the package tetex-doc) on Red Hat Linux or Ubuntu. On Mac OS X, fink installs the docs in /sw/share/texmf-dist/doc.) For some reason, it took me several years to discover this documentation and it has almost totally replaced the Lamport and Goossens books for everyday reference. One problem with the books (especially the graphics book) is that they are out of date and some of the key packages documented have changed. The online documentation is also out of date, but not quite so much. The documentation is mostly in DVI format, so you will have to have a working DVI viewer (e.g., xdvi) or convert them to PS/PDF.

UPDATE: I recently acquired the 2nd edition of the companion book and it is really great. It answers a lot of the questions I wanted to cover on this page, particularly about fonts!

pdfLaTeX and letter paper

On many systems, pdfLaTeX defaults to A4 output, even with the letterpaper option to the article class. The simplest solution: add \usepackage{hyperref} to your preamble. hyperref sets the right paper size for PDF output (as if by magic). Thanks for this tip goes to Oliver Haynold at Northwestern University.

NOTE: The tip works, but I'd like more info on root causes.

Future Work

Some things I'd like to put here:

  • A definitive discussion of Type 1 fonts, etc. What is the difference between "\usepackage[T1]{fontenc}" and "\usepackage{times}" (and the like)? What is the purpose of "dvips -P cmz" or "dvips -P pdf"?
  • How to fix the braces in alltt without breaking math mode.
  • Tips for dealing with pstricks, .eps files, and positioning graphics.
  • Paper sizes... or, why can't letter and A4 get along?
  • Prosper, HA-Prosper, slideware, ugh...

Hillary/Obama/Edwards Three-Way

Michelle Cottle at The Plank speculates on the Democratic primary race:


The safe-money bet is that we'll hear this minority v. chick storyline approximately 7,500 times if both senators [Clinton and Obama] indeed make a play for the White House, which has me wondering: What will this mean for the oh-so-white guy currently rounding out the Democratic triumvirate of top-tier candidates, Johnny Reid Edwards?

Will Edwards suffer from not being included in the media frenzy certain to rise up around Hillary v. Obama--all those inspirational stories about American social progress and the chance to remove the asterisk from the assertion that "anyone can grow up to be president"? Will some people come to resent Edwards as another entitled white guy trying to spoil the party?

Alternatively, will all the talk about race and gender and trailblazers and cultural barriers ultimately turn people off or make them question the qualifications (or, god forbid, the electability) of the two aspiring "firsts"? In the end, will Edwards benefit from being the candidate utterly without novelty appeal in this race?


John Edwards, here's your winning campaign slogan... You can have it for free. "John Edwards: He's a man. And white."

P.S. This is the exception that proves the rule: I have no opinion about the 2008 presidential race. I don't plan to have one until Q1 2008 (at least).

Tuesday, January 16, 2007

Hey You Kids, Get Off My Lawn

So I'm standing on the R platform at Atlantic Ave and there's a group of awkward pre-teen boys running in circles, chasing one another, shoving, tackling, and wrestling and just generally being stupid and irresponsible (not to say annoying) and, basically, I'm standing there devising plans for how I'm going to live with myself when one of these kids falls down onto the tracks and gets run over when the slightly older, completely unamused lady standing next to me walks over and gives them a talking to. Where do you grow the balls to do something like that? To yell at some kids you've never met when they'll probably just laugh at you and ignore you and make faces behind your back?

They didn't laugh at her---though they seemed terribly pleased with their own raffishness---and they did knock it off---though there was some backsliding as the interminable wait for the train wore on. Could I do that? Could I bend obnoxious children to my will?

Thursday, January 11, 2007

Wednesday, January 10, 2007

JPEGs in Subversion

If you've got a JPEG under Subversion and it looks like this

when it should look like this
,
maybe Subversion thinks it's a text file. Try

svn propdel svn:eol-style MY.jpg
svn propset svn:mime-type image/jpeg MY.jpg

Brought to you courtesy of this guy

Bonus fact: if you're accessing Subversion via svn+ssh and it asks for your password more than once, fret not. Subversion and SSH are just really dumb. See here.

Person of the Year Update

Twenty-four hours later my comment still hasn't shown up. (And, no, it didn't include any slander, profanity, or links to pornography.) Despite the fact this post is lighting up the left-of-center blogosphere like a Christmas tree, it has only 16 comments so far. Nice participating in your community, Time.com...

Tuesday, January 09, 2007

Joe Klein, Turd Blossom

I formulated a response to this Joe Klein drivel which has been shit-canned to the Time.com moderator queue for the last four hours*. In the meantime, BooMan has published the definitive take-down:


Friends do not let friends drive drunk. In the case of George W. Bush and the neo-conservatives, they not only are insisting on driving intoxicated, they won't let us out of the car and they respond to all requests to slow down by stomping on the accelerator. In this situation the only rational thing to do is to wait for them to come to a halt at a stop sign (if they are sober enough to avoid running it) and smack them in the head with a sock full of pennies. We need to take away the car keys, Mr. Klein.

You can call me an "illiberal leftist and reactionary progressive", you can say my "naivete on national security--and the left wing tendency to assume every U.S. military action abroad is criminal--just aren't very helpful electorally." You can talk all the shit you want. But you are still letting your friends drive drunk and criticizing anyone that wants to do something about it.


* I will take this opportunity to say that moderating blog comments is clueless and completely beside the point. Wake up, people! I am the Time Magazine Person of the Year! Why won't you publish my brilliant writing?

Saturday, January 06, 2007

The Unix Shell: Argh

Suppose you're trying to write a simple shell script. And suppose you very badly want to put a command into a shell variable before you execute it. And suppose that command very badly needs to accept double-quoted strings as arguments. Oh, the layers of indirection! How will the shell tokenize such a thing?

Let the command in question be the following homely shell script.

string-arg.sh:
#! /bin/sh
# Usage: string-arg.sh [-s STRING]*
while test ${1+set}; do
case $1 in
"-s")
if ! test ${2+set}; then
echo "no string after -s"
exit 1
else
echo "string arg=\"$2\""
shift 2
continue
fi
esac
echo "bad arg: $1"
exit 1
done

Let's see what happens.
% ./string-arg.sh -s "quoted arg"
string arg="quoted arg"
% cmd="./string-arg.sh -s \"quoted arg\""
% echo $cmd
./string-arg.sh -s "quoted arg"
% $cmd
string arg=""quoted"
bad arg: arg"
% eval $cmd
string arg="quoted arg"


AND REMEMBER, KIDS: echo `foo` gives you the output of foo and { foo; echo $? } gives you its exit value.
if foo 
then bar
fi
executes bar if foo succeeds (conventionally), which is equivalent to
foo && bar
in the short-circuiting parlance.
if ! foo 
then bar
fi
executes bar if foo fails (conventionally), which is equivalent to
foo || bar
in the short-circuiting parlance.
if `foo`
then bar
fi
executes bar if the command output by foo exists and returns exit value 0 (if it doesn't exist, it will just exit).
if test `foo`
then bar
fi
executes bar if foo doesn't produce any output.

[UPDATE] One more thing. Setting shell variables.
% CMD=cmd arg
bash: arg: command not found
% CMD= cmd arg
bash: cmd: command not found
% CMD= "cmd arg"
bash: cmd arg: command not found
% CMD="cmd arg"
% echo $CMD
cmd arg

This often trips me up, because make is much more forgiving and I hack more Makefiles than shell scripts.

[UPDATE 1/8/2007] I got the if-then stuff wrong the first time. Which goes to show you how desperately I need this tutorial. In shell-world exit code 0 is "true" and exit code not-0 is "false". This is sort of the opposite of the C convention, with the caveat that exit values and arithmetic values shouldn't be conflated.

Another trip-up from C to the shell is that whitespace makes a bigger difference. if ! foo; then bar; fi is not the same as if !foo; then bar; fi.
if foo
then bar
fi
is not the same as if foo then bar fi. {foo; bar;} is not the same as { foo; bar;}. And so on, world without end.

Friday, January 05, 2007

The Top Chef Says: Nobody Likes You!

I'm trying to avoid too much basic cable blogging, but I feel moved to comment on the horror of this week's Top Chef. Sam, Ilan, and Betty's "nobody likes you, Marcel, and we're going to prove it" act was straight out of my junior-high nightmares. Isn't it strange that last year's "villain," Tiffany, earned everone's loathing because she wasn't a team player and picked on Dave and Miguel, whereas this year's "villain," Marcel, is visibly trying to be cooperative and is being picked on by everybody else?

I think the key fact here is that the contestants take what is said at the Judge's Table very personally. Despite the fact that those in the "bottom three" are forced to opine on "who should go home"---and despite the fact that it's generally good strategy not to choose oneself---naming names gets you in trouble. Tiffany did herself in by being excessively cut-throat at the Judge's Table (and also the lying). The last straw with Marcel was probably when he failed to credit Sam with last week's win (never mind that standing by and letting others take credit for success is hardly the path to victory).

I didn't like Marcel to start, but his sense of humor in the face of everyone's hostility has really won me over. He's pretentious and arrogant (but, come on, he's not Stephen "You will never succeed, and you will fail horribly" Asprinio (who also won me over in the end, now that I think about it)), he easily descends into self-parody (asked why his turkey roulade was dry, he responded that he didn't have access to a thermal immersion circulator (or, um, butter)), and he probably doesn't have the skill to win the competition. But at least he's not a total dick!

I always hated Betty and I'm glad to see her go. Her excessive cheerfulness seemed to be tautly and thinly stretched over a chasm of extreme bitchiness. Up till this episode, I liked Sam and Ilan and had them figured as top contenders. I'll be rooting against them from now on. And for Elia and Marcel.

P.S. To Ilan: Marcel will stop making foams when make something other than paella.

What's Better-Than Armond White?

Finally, his whole critical style distilled to one infographic. Unfortunately, Steven Spielberg didn't release a movie this year... we'll have to wait until 2008 to find out why Indiana Jones IV is better than the entire oeuvre of Jim Jarmusch. (Via The House Next Door)

This reminds me: several weeks ago John Podhoretz of the National Review called Manohla Dargis' review of Inland Empire "the most pretentious piece of writing in all of recorded history." These can only be the words of a man who has never read Armond White.