Sunday, January 27, 2013

New Web Site

I haven't been posting much on this blog, though I did start up a tech blog over at www.williamqliu.com.

Let's see, for the holidays I visited California to see family and friends.  I started out in Davis to see two of my cousins, one of whom just graduated college and started her first job as a mathematics teacher for the Teach for America program.  I always knew that being a teacher was difficult, but I finally got to glimpse how rough it really is.  She would leave at 6am and get back from work at 9pm.

My younger brother also happened to be there and I got to spend a lot of time with him.  He flew in from Nebraska and our flights arrived within an hour of each other.  We ended up leaving Davis and driving down to Reedley together.  During our talks, I sometimes forget how different my brothers and I are.  My younger brother is the ambitious, extraverted, and smart one (though somehow not really technically inclined).  My older brother is very technical, introverted, and conservative.  I'm simply the wildcard.

Reedley was the same as I always remembered it.  For a week, I felt like I was in high school all over again.  I even went to hang out with the same friends since high school.  I think the only thing that was different was that for this vacation, I got my family to do nightly P90X workout sessions in the living room.  We didn't get far past the warmup sessions, but they were still fun group events.

For the last few days a friend and I went up to San Francisco to visit another friend.  We all knew each other since high school and again, it felt like no time passed since then.

My next trip will be to go somewhere new, but this 'catch up' vacation was long overdue.

Tuesday, October 23, 2012

October 2012


October's been a fun and busy month.

I ran my first half marathon.  I signed up and ran with coworkers in Central Park last week.  This was my first long run and I tried it using a new pair of minimalist shoes.  We were all pretty casual about the whole thing; we chatted during the run and I even had to stop to pee.  All in all, we did pretty well and I averaged 10:01 minutes per mile.





A friend and I went to the NYC Comic Con.  It wasn't as big as the San Diego Comic Con, but it was just as much fun.  I love seeing how creative people can get.  You can tell people's passion through the level of detail in costumes.  For example, here's a Ghostbusters costume with blinking LEDs.











I also applied to graduate school.  It's a long shot, especially since I only applied to one school.  I figured if I don't get into the program I want, I shouldn't settle for a second choice.  That said, the new program is for a Masters of Science in Business Analytics at NYU Stern School of Business.  It'll be an inaugural class that'll be limited to 60 students.  (Big thanks to Sherry Patheal and Marshall Ellis for the recommendations)  Fingers crossed!

Even if I don't get into graduate school, I've been getting the itch to experiment with more data projects.  I've been attending a lot of data meetups and it's neat to see how data analytics is changing.  It's funny seeing articles that mention data being the next big thing as if no one's ever mined or used data to influence business decisions.  People have done this for years.

As an analyst, it is interesting to see that we're capturing so much more information, but it's also interesting that the technical infrastructure is changing.
  • I'm so used to data being structured into a relational database management system (i.e. this table holds these fields in these columns).  This has the advantages of linking tables/fields, but it requires so much data cleaning and doesn't scale well for large amounts of data.  If you're trying to store big data (think petabytes, as in 1 million gigabytes) with varying data sets, this system is outdated.
  • With technology catching up we have new noSQL systems like Apache Hadoop and MongoDB that allow horizontal scaling for more clusters, which means more data storage (as opposed to vertical scaling, say having a more powerful single server).  We also have Amazon's EC2 service (that allows for more computing power) and S3 service (that allows for more storage), both of which scales for as little or as much as you could possibly need.  To sort information (since there's no relational tables), there's tags /non-visible metadata (data that tells you about the data).
Anyways, it'll be neat to see what people do with these new tools and how it affects current systems.

Wednesday, September 12, 2012

At Google

One of the things that I love about New York City is that you can really find your niche.  With a population density of over 27,000 people per square mile, you're bound to find others who share your interests.

Tonight, I went to an Android meetup hosted at the Google office above Chelsea Market.  It's not my first meetup there, but it was interesting because the guest speaker was Mark Murphy.  I read his Android development books a year ago and was quite impressed.  When you purchase his books, you have access to an updated online version for a year after purchase.  Plus his Four-To-Free Guarantee business model was neat (after four years or 4,000 published copies, a book edition is released under the Creative Commons license for free non-commercial distribution)

Anyways, the topic covered was "App Integration Strategies and Tactics".  It could be summed up as this:
  1. What does your app really do?
  2. What permissions does your app ask for? (e.g. is it reading my contact list, is it accessing the Internet)
  3. Do you really need those permissions to accomplish what your app does?
  4. If it isn't absolutely critical, then make the additional features as a plugin (and request permissions from the plugin)
  5. If you're using other programs to do something, then call implicit intents instead of explicit intents; this gives users a choice and is more reliable (e.g. a program might arbitrarily change their intent from com.williamqliu.mystuff to com.williamqliu.stuff causing the explicit intent to fail)
  6. If you're using other programs, use official APIs to integrate with your program
  7. Don't build your own class loader; it's too much work.  Someone out there will do code injections and then use your permissions to do things that were not intended
I thought it was neat.  I think that great programming is just as much an art form as painting or sculpting.  If you ever read someone else's code, you understand just how different someone can write the same program both in efficiency and style.  That said, I'm glad I'm not a programmer as my day job.

Thursday, September 6, 2012

The Egg


I just read this and thought it was really beautiful.

The Egg
By: Andy Weir

You were on your way home when you died.
It was a car accident. Nothing particularly remarkable, but fatal nonetheless. You left behind a wife and two children. It was a painless death. The EMTs tried their best to save you, but to no avail. Your body was so utterly shattered you were better off, trust me.
And that’s when you met me.
“What… what happened?” You asked. “Where am I?”
“You died,” I said, matter-of-factly. No point in mincing words.
“There was a… a truck and it was skidding…”
“Yup,” I said.
“I… I died?”
“Yup. But don’t feel bad about it. Everyone dies,” I said.
You looked around. There was nothingness. Just you and me. “What is this place?” You asked. “Is this the afterlife?”
“More or less,” I said.
“Are you god?” You asked.
“Yup,” I replied. “I’m God.”
“My kids… my wife,” you said.
“What about them?”
“Will they be all right?”
“That’s what I like to see,” I said. “You just died and your main concern is for your family. That’s good stuff right there.”
You looked at me with fascination. To you, I didn’t look like God. I just looked like some man. Or possibly a woman. Some vague authority figure, maybe. More of a grammar school teacher than the almighty.
“Don’t worry,” I said. “They’ll be fine. Your kids will remember you as perfect in every way. They didn’t have time to grow contempt for you. Your wife will cry on the outside, but will be secretly relieved. To be fair, your marriage was falling apart. If it’s any consolation, she’ll feel very guilty for feeling relieved.”
“Oh,” you said. “So what happens now? Do I go to heaven or hell or something?”
“Neither,” I said. “You’ll be reincarnated.”
“Ah,” you said. “So the Hindus were right,”
“All religions are right in their own way,” I said. “Walk with me.”
You followed along as we strode through the void. “Where are we going?”
“Nowhere in particular,” I said. “It’s just nice to walk while we talk.”
“So what’s the point, then?” You asked. “When I get reborn, I’ll just be a blank slate, right? A baby. So all my experiences and everything I did in this life won’t matter.”
“Not so!” I said. “You have within you all the knowledge and experiences of all your past lives. You just don’t remember them right now.”
I stopped walking and took you by the shoulders. “Your soul is more magnificent, beautiful, and gigantic than you can possibly imagine. A human mind can only contain a tiny fraction of what you are. It’s like sticking your finger in a glass of water to see if it’s hot or cold. You put a tiny part of yourself into the vessel, and when you bring it back out, you’ve gained all the experiences it had.
“You’ve been in a human for the last 48 years, so you haven’t stretched out yet and felt the rest of your immense consciousness. If we hung out here for long enough, you’d start remembering everything. But there’s no point to doing that between each life.”
“How many times have I been reincarnated, then?”
“Oh lots. Lots and lots. An in to lots of different lives.” I said. “This time around, you’ll be a Chinese peasant girl in 540 AD.”
“Wait, what?” You stammered. “You’re sending me back in time?”
“Well, I guess technically. Time, as you know it, only exists in your universe. Things are different where I come from.”
“Where you come from?” You said.
“Oh sure,” I explained “I come from somewhere. Somewhere else. And there are others like me. I know you’ll want to know what it’s like there, but honestly you wouldn’t understand.”
“Oh,” you said, a little let down. “But wait. If I get reincarnated to other places in time, I could have interacted with myself at some point.”
“Sure. Happens all the time. And with both lives only aware of their own lifespan you don’t even know it’s happening.”
“So what’s the point of it all?”
“Seriously?” I asked. “Seriously? You’re asking me for the meaning of life? Isn’t that a little stereotypical?”
“Well it’s a reasonable question,” you persisted.
I looked you in the eye. “The meaning of life, the reason I made this whole universe, is for you to mature.”
“You mean mankind? You want us to mature?”
“No, just you. I made this whole universe for you. With each new life you grow and mature and become a larger and greater intellect.”
“Just me? What about everyone else?”
“There is no one else,” I said. “In this universe, there’s just you and me.”
You stared blankly at me. “But all the people on earth…”
“All you. Different incarnations of you.”
“Wait. I’m everyone!?”
“Now you’re getting it,” I said, with a congratulatory slap on the back.
“I’m every human being who ever lived?”
“Or who will ever live, yes.”
“I’m Abraham Lincoln?”
“And you’re John Wilkes Booth, too,” I added.
“I’m Hitler?” You said, appalled.
“And you’re the millions he killed.”
“I’m Jesus?”
“And you’re everyone who followed him.”
You fell silent.
“Every time you victimized someone,” I said, “you were victimizing yourself. Every act of kindness you’ve done, you’ve done to yourself. Every happy and sad moment ever experienced by any human was, or will be, experienced by you.”
You thought for a long time.
“Why?” You asked me. “Why do all this?”
“Because someday, you will become like me. Because that’s what you are. You’re one of my kind. You’re my child.”
“Whoa,” you said, incredulous. “You mean I’m a god?”
“No. Not yet. You’re a fetus. You’re still growing. Once you’ve lived every human life throughout all time, you will have grown enough to be born.”
“So the whole universe,” you said, “it’s just…”
“An egg.” I answered. “Now it’s time for you to move on to your next life.”
And I sent you on your way.

Friday, June 22, 2012

Toilet Seat

Yesterday I had a discussion about whether guys should leave the toilet seat down after use.  Coincidentally I happened to watch a South Park episode that mentioned the same dilemma.  Neither situations had a solution so I decided to write a blog post.  We'll start off by listing all possible scenarios (since they're pretty limited).
  1. Assuming no adjustments to toilet seat after use:
    • For Women:
      • Best Pee scenario: 0 adjustments (toilet seat is down = no change)
      • Worst Pee scenario: 1 adjustment (toilet seat from up to down)
      • Best Poo scenario: 0 adjustments (toilet seat is down = no change)
      • Worst Poo scenario: 1 adjustment (toilet seat from up to down)
        Total Number of adjustments for scenarios: 2
    • For Men:
      • Best Pee scenario: 0 adjustments (toilet seat is up = no change)
      • Worst Pee scenario: 1 adjustment (toilet seat from down to up)
      • Best Poo scenario: 0 adjustment (toilet seat is down = no change)
      • Worst Poo scenario: 1 adjustment (toilet seat from up to down)
        Total Number of adjustments for scenarios: 2
  2. Assuming men put the toilet seat down after each use:
      • For Women:
        • Best Pee scenario: 0 adjustments (toilet seat is down = no change)
        • Worst Pee scenario: 0 adjustment (toilet seat is down = no change)
        • Best Poo scenario: 0 adjustments (toilet seat is down = no change)
        • Worst Poo scenario: 0 adjustment (toilet seat is down = no change)
        • Total Number of adjustments for scenarios: 0
      • For Men:
        • Best Pee scenario: 3 adjustments (toilet seat from down to up and back down)
        • Worst Pee scenario: 3 adjustment (toilet seat from down to up and back down)
        • Best Poo scenario: 0 adjustment (toilet seat is down = no change)
        • Worst Poo scenario: 0 adjustment (toilet seat is down = no change)
        • Total Number of adjustments for scenarios: 6
    • Therefore, the only way to be fair (and consequently the most inefficient method) is to have the entire lid closed after each use regardless of gender:

      • For Women:
        • Best Pee scenario: 2 adjustments (open lid, close lid)
        • Worst Pee scenario: 2 adjustment (open lid, close lid)
        • Best Poo scenario: 2 adjustments (open lid, close lid)
        • Worst Poo scenario: 2 adjustment (open lid, close lid)
        • Total Number of adjustments for scenarios: 8
      • For Men:
        • Best Pee scenario: 2 adjustments (open lid, close lid)
        • Worst Pee scenario: 2 adjustment (open lid, close lid)
        • Best Poo scenario: 2 adjustment (open lid, close lid)
        • Worst Poo scenario: 2 adjustment (open lid, close lid)
        • Total Number of adjustments for scenarios: 8


        Note: None of these methods take into account frequency of use (i.e. more peeing than pooping).  If given say a 2:1 ratio of peeing to pooping, then the most energy saving seating would be with toilet seat down (although not necessarily fairer).

    Monday, April 16, 2012

    :)

    I love listening to music and programming at night.  Sometimes I feel like I don't need to sleep.

    Tuesday, February 28, 2012

    Budgeting Life

    It doesn't matter how much you make, you can just as easily spend it; this statement is especially true living in NYC.  Lately, if there's been anything I wanted (food, event, clothing, or stuff in general) I just buy it without thinking twice.

    I don't like this feeling.  I feel like I'm living in a perpetual state of consumption.  It doesn't matter what I consume, I'm just not satisfied and I'm immediately ready for the next thing.  For example, I'll have a bite of some rich Belgian chocolate and yet it won't taste half as good as the Reese's peanut butter cups I had in Ha'apai.

    I'm learning that budgeting a checkbook is easy.  Budgeting life so you can still appreciate the small things, now that's difficult.