Thursday, July 24, 2008

PolyGroovers are back!

Tonight we are packing up and going camping for the weekend, to a music campout in Willits, where we'll be performing live on Friday night. A full mixed set will be published here next week. Very exciting stuff, and as a bonus I've got a new song to share...

This is an extended mix, which is why it's 8 minutes long, and meant to be played live. The album version will be much shortened.

Please feel free to leave comments with your feedback. Much appreciated!

Thursday, July 17, 2008

Tell Your Mana About Obama, and Obama Car Art

Obama's Potential Presidency

There is plenty of excitement around Barack Obama's potential presidency, and I think there's a lot to be excited about. There's is an overwhelming feeling among people I talked to in San Francsisco, how Obama is "Our President" — not a poster boy for old money or a powerful family. The fact that the Internet fund-raising helped Obama to compete and win against the Clinton clan is a testament to the truly new era, a more democratic one, where if someone can fire up a lot of people they can rally up quckly and effectively. This efficiency is something to look forward to, if and when Obama becomes a President.

Whether or not all the people behind Obama will continue to support him, is another question. People tend to idealize their heroes way to quickly, and that's also dangerous. The recent backlash of liberal bloggers about Obama's compromise vote — is a great example. Politics is still politics, and nobody ever gets their way all the time. Everyone must compromise at some point.

But enough said, I think that overall Obama is a great candidate, and will hopefully bring a new fresh perspective into the Washington. So, how do we get there? Well, donating money is, for once, a very easy thing to do thanks to http://barackobama.com. But now there are other ways.

Car Art Contest

Infectious.com (the company I work for) is running an open contest for Car Art Submissions around Obama. There are some restrictions - some specific words can not be used, but it's an amazing opportunity for artists around United States to create Obama Car Art that can be seen by thousands of people commuting daily in the next few months before the election. This is as grass roots as it gets.

If you know any artists that may be interested please send them to Infectious. Or you can grab the banner above and put it up on your blog. Either way - thank you!

Tuesday, June 17, 2008

Firefox3 PR Backfires?

After announcing to the world that Firefox 3 will be available at 10am PDT today, June 17th, amidst apparent publicity stunt to generate the record number of downloads per day (has anyone been really keeping a tally?) the web site http://getfirefox.com/ returns the pathetic

Http/1.1 Service Unavailable

Firefox is certainly a decent browser, but it's stability seems to have gone reversely proportional to the self-professed greatness and the size of their publicity stunts.

Safari is now by far the best looking, and fastest browser for Windows, and it has been that way for mac for a while.

Good luck Fifefox 3 (when we see you), but I for one, am not buying it.

Update @ 12:23pm

OK, so finally FF3 is available for download, and I have it installed and running. The first thing is that not all plugins are compatible, and if you are using FireBug for web development, you must install the 1.1 version available here.

Wednesday, June 11, 2008

Infectious.com launches!

It finally happened :) I've been working for Infectious.com since about July last year, and it's been a really fun run building a brand new product, from a mere conception to this moment - full public launch.

Click to go to Infectios.com

Of course some people may have caught the glimpse of this from TechCrunch article a few weeks ago. Nevertheless, here it is - Car Art For the Masses - available to you from a spanking new website, designed and developed by the Team Infectious and yours truly.

The idea of course is simple - everyone's car looks the same! OK, so some are dirtier than others, some stink more, all of this is certainly true, but from an aesthetic point of view, if you and your neighbor accidentally buy the same model of a car, you are screwed! Well, not really, and especially not anymore.

Stop wasting time and go get some cool art for your car, make it look like nobody else, even if you drive a stinky dirty '74 Datsun. I'm seriously.

Tuesday, April 22, 2008

Aptana - Please Don't Suck Any Harder

I wrote this post after hours of frustration, trying to fix my broken environment, and losing valuable time on a project that was falling behind.

I now realize that the post was overly emotional, and probably not entirely fair to the Aptana team. I'll post updates here as I work through the issues to get my RadRails working again.

Thursday, March 13, 2008

Car or Auto Make-Model-Year Database : For Breakfast

Make Model What?

If you like me were tasked with loading a database of recent car makes/models/years, you would start by looking on the web and seeing if someone else just has it out there, readily available, hopefully for free, but perhaps for a tiny nominal fee.?

If only it was that simple...

I looked and looked, and couldn't find anything that would fit the above requirements. So I thought, who would know about US car models better than Kelly Blue Book? So I went on their site, and sure enough they have a javascript file that lists all known to them makes and models of used cars. Since the file is public, I figured it's not really "evil" if I scrape and parse it for my own benefit. Disagree? Have a better source? Then leave a comment.

Anyway, to cut the long story short, I'm hoping to save a day or so to someone else who may, like me, be looking for this information. The ruby module shown below retrieves and parses the javascript from KBB site into a Ruby data structure of the following form - basically a hash, keyed on make, then on model with list of years as a value:

 
>> Constants::Auto::DB.keys.sort[0..5]
=> ["AMC", "Acura", "Alfa Romeo", "Audi", "BMW", "Bertone"]
>> Constants::Auto::DB["Subaru"].keys.sort[0..5]
=> ["B9 Tribeca", "Baja", "DL", "Forester", "GL", "GL-10"]
>> Constants::Auto::DB["Audi"]["A4"]
=> ["1999", "2007", "1998", "2006", "2005", "1996", "2004", "2003", "2002", "1997", "2001", "2000"]
>> Constants::Auto::DB["BMW"]["X5"]
=> ["2003", "2002", "2001", "2000", "2005", "2007", "2006", "2004"]

The idea is that you could load the initial hash: @models = KBB::Parser.new.to_hash and then save the output of @models.inspect in your local constants file - hence me using Constants::Auto::DB (I actually have a Rake task for doing this -- let me know if I should post it too). Then you would just re-run this every time you think new car models are added/changed on KBB. Realize, that hitting their site every time you need the data is clearly evil. So use this class to load the data initially, save the result of inspect() call into a ruby file, and use that cached version in your app. Re-run the load every time you want to update your database.

Please let me know if you find this code useful, or if you find a better/cleaner/more comprehensive way of maintaining car make/model/year database.

#
# author: Konstantin Gredeskoul © 2008
# license: public domain
#
require 'net/http'
require 'uri'

module KBB
  MODELS_URL = "http://file.kbb.com/kbb/ymmData.axd?VehicleClass=UsedCar"

  class Models
    def initialize(js)    
      @models = {}
      @makes = {}
      n = /ymUsed_\[\d{4}\]\s*=\s*'([^']+)'/
      m = /ymmUsed_\["(\d+)~(\d+)"\]\s*=\s*"([^"]+)"/
      js.split(/\n/).each do |line|
        next if line.strip.blank?
        if matched = n.match(line)
          matched[1].split(/,/).each do |token|
            id, name = token.split('|')
            @makes[id.to_i] = name
          end
        end
        
        if matched = m.match(line)
          year, make_id, models = matched[1], matched[2], matched[3]
          models.split(/,/).each do |t| 
            id, model_name = t.split('|')
            make_name = @makes[make_id.to_i]
            @models[make_name] ||= {}
            @models[make_name][model_name] ||= []
            @models[make_name][model_name] << year
          end
        end
      end
    end
    
    def to_hash
      @models
    end
  end

  class Parser
    def initialize
      @m = Models.new(Net::HTTP.get(URI.parse(MODELS_URL)))
    end
    def to_hash
      @m.to_hash
    end
  end

end

Tuesday, December 4, 2007

Beaches, Aussies and Christmas

It's been a little quiet here, as things were a little busy towards the end of November, and now I am away on a short trip to Australia visiting my family, relaxing and sun-bathing on fantastic beaches of Queensland, while sipping overpriced Jameson whiskey :)

Australian Christmas is in full effect, with enormous pines towering over hot beaches fully decorated in typical X-Mas crap, while in the former hippie town Byron Bay pines are dressed with shiny peace signs.

Australians just had an election, where labor party (a weak parallel of US Democratic party) have won -- a welcome change of government after 11 years of Liberals and John Howard (smart, but creepy suck-up to George Bush). The new power has immediately ratified Kyoto protocol in their first week "at the wheel". It's refreshing to see reusable green bags at the supermarkets here, just as they are becoming a norm in San Francisco.

A weird fact discovered today -- capitalism does not mean the demand is satisfied with supply. Beach mats are not heard of in Byron Bay - a beach town with $50 beach towels. There's a few things Australia can learn from third world Thailand, where beach mats were everywhere.

Signing off for now, but stay tuned, as I'm planning a PostgreSQL performance tuning post in a few weeks. This seems like a subject not well covered widely, not sure why.

Monday, November 12, 2007

Domain Registration Mayhem

I don't think it's a secret that the domain registration business is kinda whack. Just look at all the domain parking companies out there which take "shady business" to the whole new meaning. What I don't understand is the rationale behind some of the rules that govern domain business. For instance...

How does NetworkSolutions Inc gets away with charging $34.99 a year?

Seriously... WTF? I am hosting my domains with 1&1 Hosting, which charges $6.99 a year. This seems like a reasonable price, but here's the main reason the guys like NetworkSolutions are still in business:

You can not transfer your domain 2-3 weeks prior, and two months after the date of your domain renewal.

This dead simple, but annoying rule guarantees that everyone who WANTs to transfer their domain, but is trying to wait till last minute and/or forgets till last minute, CAN NOT move their domain to a more competitive provider. Please give me one good explanation on how this rule protects consumers...

See also: Network Solutions rules of domain transfer.

Sunday, November 11, 2007

More music is on its way...

Telene and I have been taking advantage of the crappy weather and doing recording sessions of the tracks for the new album. In addition, this morning the lovely Amber Johnston dropped by our studio and recorded a take or two.. The result - two new awesome songs, with a very different feel. Can't wait to get the album out, but realizing that patience is a virtue.

There are at this moment eight tracks in a near completion stage, for the total of about 45 minutes brand spanking new PolyGroovers.

Sorry, but we don't want to put the tracks up until the whole album is complete, although this one - Spin Cycle for Delicates and Romantics has been available for download for some time now... instrumental only, this is a good massage for the bone behind the ears :)

Saturday, November 10, 2007

Oh no, I am Back!

Yay, blog move is finally complete, and here we are -- with a shiny new dedicated blog domain name, and a Blogger/Google-based account. Blogger has gone a long way since I moved to WordPress from my original blogger account.

My main reason for this renewed love is the flexibility with CSS/HTML template, domain name support and ability to add javascript to your blog is also pretty sweet. In general, it just feels like they trust you more with your own blog here at Blogger. WordPress ends up being ruled by a pretty draconian law, and breeds rather annoyingly hawkish forum users.

Without too much product-bashing, I'm just happy to be done with the move, which unfortunately had to be manual.

Keep an eye out for a set of new posts about drop down menues and REST.