I decided to add captions to my YouTube video for FMCaltrain. It was pretty easy. I logged into YouTube, selected My Videos, and then found the video and selected Insight -> Captions and Subtitles. From there, I found a machine generated caption file (really just a text file with time codes). I downloaded the caption file and edited it to correct some voice recognition mistakes. After that I re-uploaded it to YouTube and now my video is accessible to people who need captions. Check it out at http://youtu.be/gIk6BgKofHk.
First impressions of Samsung Galaxy Tab 10.1
So I am celebrating my birthday this year at Google I/O 2011. It now seems to be a tradition that Google gives us attendees free stuff and this year is no different. Today we got a Samsung Galaxy Tab 10.1 that runs Android. Here are some of my first impressions from first use:
- The device is physically light, lighter than my first gen iPad.
- After power on, I have to configure it and the default locale was English (UK), not US. A little weird. Makes you feel like you got something smuggled in from abroad.
- As far as I know this tablet is WiFi only, but it prompted me to set time and time zone automatically from the network. I figured why not. Big mistake! After completing set up I noticed that I was still in the GMT timezone (look its the UK again) and when I went into Settings->Date and Time, all the options for time zone were grayed out. I was stuck. I tried to search on the web for how to fix this, but I couldn’t find it. Ultimately I gave up and did a factory reset of the device. That sucks!
- Setting up a Gmail account was easy and painless. Just like I would expect. The Gmail app is easy to use and performs reasonably well.
- I tried to setup a Microsoft Exchange account. I was hoping I could just type in my e-mail address and password and the client would use some sort of auto-discover to determine the server and other settings. No such luck and since I can’t remember the settings, I can’t setup the account until I contact the administrator of the Exchange server. That sucks!
- I tried to setup a VPN. Now I know I use a Cisco VPN and I know the server address and my username and password, but for the life of me I couldn’t figure out which VPN type to pick in settings. Is it PPTP? (probably not), L2TP, IPSEC with PSK, IPSEC with CRT? I have no idea. Oh well, no easy VPN setup. That sucks!
- The browser does seem to work well, like a good WebKit browser should.
So I know that is pretty rough, but again these are just first impressions. On other mobile platforms, like webOS and iOS, setting up basic things like date/time, Exchange email, and VPN were pretty easy. Most of the time the system just guessed or figured out my settings. This is certainly an area that either Google or the Android licensees could improve.
I’ll be at Google I/O 2011
7 Days of the Vegan
For the last 7 days I have eaten nothing but vegan food. That means no meat, no eggs, no dairy, no honey, nothing but vegetables, fruits, nuts, tofu, and something called seitan. Going vegan probably won’t kill you, but I am glad to be returning to carnivore land tomorrow morning.
It all started with Groupon. My wife suggested I signup and lo and behold the first coupon was from this company called Gobble Green for a Vegan Starter Kit. The kit promised 7 full days of breakfast, lunch, snack pack, dinner, and dessert. Now anyone who knows me, knows that I love meat. And I am not just one of those modern carnivores who eats nicely packaged meat from the grocery store but can’t stomach the idea of killing his own. I’m no Ted Nugent, but I’ve blasted a few flying Donalds in my day and grilled them up to my satisfaction. So suffice to say, this would be a personal challenge and an opportunity to live life on the other side.
The kit arrived last Thursday morning around 11am, and as I opened the box and stared at items like Seitan, Falafels, spaghetti and “meatballs”, “sausage” and “cheese”, rice pilaf, I started to think I had made a mistake. How does anybody live on this stuff? And what’s up with all this fake “meat” and “cheese” made out of God knows what? But I’m not a wimp, so I can hack it. I can eat anything for 7 days.
The first few days were terrible. I was literally fantasizing about meat every hour. Even the smell of meat put me in a foul mood. I would have done anything for a piece of bacon, even just a bacon bit. To make things more fun, I decided to take pictures of everything I ate and post it to Facebook so all of my friends could see what I was doing. It is amazing how many comments these photos generated. People have some pretty strong opinions about going vegan and about vegan food. Most of them were not positive on the idea and many people offered to come and save me. Don’t worry, I survived and I am not brainwashed!
By day five, the physical cravings for meat and eggs had gone away. I still mentally wanted them, but I wasn’t dying for them. I think the human body can adapt to eating just about anything. I truly believe we were meant to be omnivores and eat whatever we could to survive. Only in modern times, when we have abundance, can we be so picky about what we eat and turn down perfectly good food in order to adhere to some arbitrary diet. That goes for any restrictive diet : vegan, low carb, kosher, low fat, whatever.
Thinking back over the 7 days of food, most of it was bland and some of it was terrible. Fake “meat” is a horrible idea. It will not convert a carnivore into a vegan. On the other hand, the simple things like a Chickpea salad were quite tasty and the basics like rice and mixed vegetables are always good. A benefit of doing this 7 day diet was finding a few new things that I like and reminding me that there are many good tasting foods out there that don’t come from an animal.
At the end of this week, I can’t really say that I feel any different. I don’t have any more or less energy and there hasn’t been any change in my regularity. I don’t have any crazy idea of voting for the Green Party or joining PETA either. I’ll certainly look to improve my diet in the future by including more vegetables, fruits, and nuts, but I don’t want anything to do with seitan, it’s just wrong. Tomorrow morning I am going to have a bacon, cheese, and avocado omelette and I will appreciate it more than I ever have!
Headline : President Obama announces new “Children’s Stimulus”
The most recent stimulus campaigns have failed to completely revive the American economy, so President Obama is announcing an innovative “Children’s Stimulus”. In this new program, President Obama will give 10-13 year olds $500 to buy new jeans, high tops, video games, and candy. The president said:
“By putting this money in the hands of the nation’s 10-13 year olds, we will stimulate the economy on multiple levels. First, parents will have to drive their children to these stores to make the purchases. That will inevitably lead to more tire changes, oil changes, and windshield wiper replacement at our nation’s service stations. Secondly, the stores will have to hire new clerks and salespeople to handle all of the incoming customers. Thirdly, children tend to get hungry, which means increased visits to the Food Court. You see, it really works. By giving $500 to the nation’s children we will be putting so many American adults back to work.”
Skeptics immediately questioned how the government would know that the children had spent the money on jeans, high tops, video games, or candy and not on other “un-stimulating” things like food, medicine, and school books. President Obama has a plan for that and announced the creation of a new federal program, the Children’s Recovery Accountability Program or CRAP for short. President Obama said:
“Under this new CRAP, the federal government will require the 10-13 year olds to submit a stimulus spending report with receipts detailing their purchases. Employees of CRAP will then examine the receipts to make sure that the youngsters spent their stimulus money as they were instructed (on jeans, high tops, video games, and candy). If a CRAP employee determines that a child spent the money inappropriately, he will be authorized to fine the child $1000 per offense or sentence the child to 1 year in prison.”
What do children and their parents think about this program? We asked little Charlie Miller of Davenport, Iowa and he told us:
“Sounds great! I can’t wait to buy a new pair of Levi’s, Nike Air Force sneakers, Super Mario Brothers, Call of Duty, and a 100 pound bag of M&Ms. It is also cool to know that I am patriot!”
Charlie’s dad, William, 35 unemployed, said he has plenty of free time to take Charlie to the mall anytime he wants to do his stimulus spending. William is proud to see his son becoming a man and hopes that some day his son will do some grown-up stimulus spending on a house or a car. “You gotta start ‘em young”, William said.
Will this new program work? Only time will tell, but so far the prospects look great!
Does anybody still print?
It has occurred to me recently that I really don’t print that much anymore. I mean almost never. I don’t print documents to read. I rarely print envelopes to mail. Heck, I rarely snail mail anything. I don’t print checks unless I have to. I hate checks! I don’t print spreadsheets. I don’t print out manuals. The most frequent thing I printed until recently, were PDF files from ChinesePod.com for learning Chinese. Printing them out served two purposes : 1) to read the lesson material and vocabulary and 2) to have something to write on with my Chinese tutor. However, now with my iPad, I don’t even need to do that. I can easily read the PDF file on the iPad and bring a single sheet of paper for my Chinese tutor to write on.
Thinking about work at Sliced Simple, we were able to avoid buying a printer and scanner for almost two whole months at the beginning of the company in the fall of 2009. However, during the incorporation process we were invariably told by our lawyers that we had to print out and sign things to follow the most conservative and best practices for a new company. So we bought a multifunction printer / scanner and a single ream of paper. It is now summer of 2010 and we are still on the same ream of paper. Without much effort, we have avoided doing a lot of printing. For run of the mill contracts like NDAs and consulting agreements, we just use DocuSign, a very simple electronic signature service that is more than good enough for everyday contracts.
I have to be a bit weird though. As I mentioned, I recently got an iPad and now really have very little use for printing. But, when I read the reviews of the iPad, I seem to constantly come across some reviewer pointing out how there is no native printing capability. People write into Walt Mossberg’s column just to ask about printing. I really don’t get it. Why would you buy an iPad and then want to print from it? You can read Word files and PDF files right on the iPad and if someone else needs a copy, e-mail it to them! I think if you look at the iPad and the first thing you say is “Now how do I print from this thing”, you probably should not be buying an iPad.
So I want to know, do you still print? What do you print? Why do you print? Do you think you will ever stop printing?
Donating my birthday : DonorsChoose.org
I decided to do the whole donate your birthday thing with DonorsChoose.org. So pick a project and fund it!
RoR : Much faster way to get url for Paperclip attachment
Background
PaperClip is a useful file attachment library for ActiveRecord that allows you to attach files (in our case photos) to an ActiveRecord object. It abstracts a way a good deal of complexity and tedious code and is particularly great for uploading files to Amazon S3.
Problem
Like many Ruby on Rails apps, we have a method for searching this particular set of ActiveRecords and returning a set of results that include URLs for the attached photos. As part of constructing the result set we were calling the url method on the photo attachment. For some reason, calling this url method about three times per record was taking forever (like say upwards of 20 ms per record). Returning just 25 records or so was really introducing a lot of delay.
Solution
In our case, the urls for the photos don’t change after they are set and can be easily computed in constant time. So to really speed things up, we stopped using the url method on the PaperClip attachment and simply built the url string manually. As you can imagine the speed up has been awesome as the time to produce these new URL strings is almost nothing. On the above mentioned search, we shaved off about half a second in the controller, which makes the search feel more “instant”.
Up and running on linode
I decided to move my sites and blog to linode. I wanted more flexibility than a standard web host would provide.
In case you have to move a WordPress blog, here is roughly what I did:
- Created a backup of old installation on old webhost (this directory had index.php and the wordpress subdirectory)
- In wordpress/wp-config.php you can find your database information (see DB_NAME, DB_USER, DB_PASSWORD, etc.)
- Make a backup of your wordpress database as a .sql or .dmp file (basically a text file with all the SQL to re-create your wordpress tables
- On the new server, create the database, user, password, etc. that is specified in the wp-config.php file.
- On the new server, if necessary, update wp-config.php/DB_HOST to point to your new db server (could just be localhost)
- On the new server, expand the backup into a directory you have picked out to hold your new blog
- On the new server, update your web server settings to point to this new directory for your blog
That should be about it. I definitely recommend googling how to do this as my information may have limited use depending on the complexity of your setup.
FMCaltrain for Palm webOS
I put out an app for the Palm webOS called FMCaltrain. If you live in the Bay Area and take Caltrain from time to time, this should help you out. FMCaltrain is available in the Palm App Catalog. Check out the YouTube video below.


