<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>sandipb.net &#187; General</title>
	<atom:link href="http://blog.sandipb.net/category/general/feed/" rel="self" type="application/rss+xml" />
	<link>http://blog.sandipb.net</link>
	<description>&#62; yours truly.</description>
	<lastBuildDate>Thu, 19 Jan 2012 15:38:34 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<item>
		<title>Humbling tweet of the year 2011</title>
		<link>http://blog.sandipb.net/2012/01/02/humbling-tweet-of-the-year-2011/</link>
		<comments>http://blog.sandipb.net/2012/01/02/humbling-tweet-of-the-year-2011/#comments</comments>
		<pubDate>Mon, 02 Jan 2012 09:42:19 +0000</pubDate>
		<dc:creator>Sandip Bhattacharya</dc:creator>
				<category><![CDATA[General]]></category>
		<category><![CDATA[India]]></category>
		<category><![CDATA[kashmir]]></category>
		<category><![CDATA[politics]]></category>
		<category><![CDATA[tragedy]]></category>
		<category><![CDATA[tweet]]></category>
		<category><![CDATA[twitter]]></category>

		<guid isPermaLink="false">http://blog.sandipb.net/?p=526</guid>
		<description><![CDATA[Quite an irony that this very honest and non-jingoistic tweet was made by the Chief Minister of a state that the rest of India is so jingoistic about.]]></description>
			<content:encoded><![CDATA[<p>Quite an irony that this very honest and non-jingoistic tweet was made by the Chief Minister of a state that the rest of India is so jingoistic about.</p>
<!-- tweet id : 145059278040993792 --><style type='text/css'>#bbpBox_145059278040993792 a { text-decoration:none; color:#0084B4; }#bbpBox_145059278040993792 a:hover { text-decoration:underline; }</style><div id='bbpBox_145059278040993792' class='bbpBox' style='padding:20px; margin:5px 0; background-color:#C0DEED; background-image:url(http://a3.twimg.com/profile_background_images/192677692/OMER_2.jpg); background-repeat:no-repeat'><div style='background:#fff; padding:10px; margin:0; min-height:48px; color:#333333; -moz-border-radius:5px; -webkit-border-radius:5px;'><span style='width:100%; font-size:18px; line-height:22px;'>Every time I see incidents like <a href="http://twitter.com/search?q=%23AMRI" title="#AMRI">#AMRI</a> I'm convinced we really are a 3rd world nation with delusions of greatness.</span><div class='bbp-actions' style='font-size:12px; width:100%; padding:5px 0; margin:0 0 10px 0; border-bottom:1px solid #e6e6e6;'><img align='middle' src='http://blog.sandipb.net/wp-content/plugins/twitter-blackbird-pie//images/bird.png' /><a title='tweeted on December 9, 2011 2:06 pm' href='http://twitter.com/#!/abdullah_omar/status/145059278040993792' target='_blank'>December 9, 2011 2:06 pm</a> via <a href="http://blackberry.com/twitter" rel="nofollow" target="blank">Twitter for BlackBerry®</a><a href='https://twitter.com/intent/tweet?in_reply_to=145059278040993792' class='bbp-action bbp-reply-action' title='Reply'><span><em style='margin-left: 1em;'></em><strong>Reply</strong></span></a><a href='https://twitter.com/intent/retweet?tweet_id=145059278040993792' class='bbp-action bbp-retweet-action' title='Retweet'><span><em style='margin-left: 1em;'></em><strong>Retweet</strong></span></a><a href='https://twitter.com/intent/favorite?tweet_id=145059278040993792' class='bbp-action bbp-favorite-action' title='Favorite'><span><em style='margin-left: 1em;'></em><strong>Favorite</strong></span></a></div><div style='float:left; padding:0; margin:0'><a href='http://twitter.com/intent/user?screen_name=abdullah_omar'><img style='width:48px; height:48px; padding-right:7px; border:none; background:none; margin:0' src='http://a1.twimg.com/profile_images/1622445337/IMG_0077-3_normal.jpg' /></a></div><div style='float:left; padding:0; margin:0'><a style='font-weight:bold' href='http://twitter.com/intent/user?screen_name=abdullah_omar'>@abdullah_omar</a><div style='margin:0; padding-top:2px'>Omar Abdullah</div></div><div style='clear:both'></div></div></div><!-- end of tweet -->
]]></content:encoded>
			<wfw:commentRss>http://blog.sandipb.net/2012/01/02/humbling-tweet-of-the-year-2011/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>One liner to convert Maildir/ to mbox using mutt</title>
		<link>http://blog.sandipb.net/2009/01/07/one-liner-to-convert-maildir-to-mbox-using-mutt/</link>
		<comments>http://blog.sandipb.net/2009/01/07/one-liner-to-convert-maildir-to-mbox-using-mutt/#comments</comments>
		<pubDate>Wed, 07 Jan 2009 13:59:57 +0000</pubDate>
		<dc:creator>Sandip Bhattacharya</dc:creator>
				<category><![CDATA[General]]></category>
		<category><![CDATA[email]]></category>
		<category><![CDATA[mutt]]></category>
		<category><![CDATA[one-liner]]></category>
		<category><![CDATA[shell]]></category>
		<category><![CDATA[tech]]></category>

		<guid isPermaLink="false">http://blog.sandipb.net/?p=293</guid>
		<description><![CDATA[If .news/ is the maildir that you want to convert to the mbox news, this one-liner will do the job for you. mutt -f .news/ -e 'set confirmcreate=no; set delete=no; push "T.*&#60;enter&#62;;snews&#60;enter&#62;&#60;quit&#62;"' (Gleaned from this mailing list post )]]></description>
			<content:encoded><![CDATA[<p>If <code><span style="color:blue;">.news/</span></code> is the maildir that you want to convert to the mbox <code><span style="color:blue;">news</span></code>, this one-liner will do the job for you.</p>
<p><code><br />
mutt -f <span style="color:blue;">.news/</span> -e 'set confirmcreate=no; set delete=no; push "T.*&lt;enter&gt;;s<span style="color:blue;">news</span>&lt;enter&gt;&lt;quit&gt;"'<br />
</code></p>
<p>(Gleaned from <a title="Source" href="http://newsgroups.derkeiler.com/Archive/Comp/comp.mail.mutt/2006-06/msg00005.html">this</a> mailing list post )</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.sandipb.net/2009/01/07/one-liner-to-convert-maildir-to-mbox-using-mutt/feed/</wfw:commentRss>
		<slash:comments>6</slash:comments>
		</item>
		<item>
		<title>Apple is as big a threat to FOSS as Microsoft</title>
		<link>http://blog.sandipb.net/2008/10/24/apple-is-as-big-a-threat-to-foss-as-microsoft/</link>
		<comments>http://blog.sandipb.net/2008/10/24/apple-is-as-big-a-threat-to-foss-as-microsoft/#comments</comments>
		<pubDate>Fri, 24 Oct 2008 09:16:15 +0000</pubDate>
		<dc:creator>Sandip Bhattacharya</dc:creator>
				<category><![CDATA[General]]></category>
		<category><![CDATA[apple]]></category>
		<category><![CDATA[evangelism]]></category>
		<category><![CDATA[foss]]></category>
		<category><![CDATA[Os X]]></category>
		<category><![CDATA[tech]]></category>
		<category><![CDATA[windows]]></category>

		<guid isPermaLink="false">http://sandipb.wordpress.com/?p=285</guid>
		<description><![CDATA[Many FOSS enthusiasts do not realize is that Apple is as, if not more, significant threat than Microsoft in the war for software freedom. Most of the technical arguments that FOSS evangelists have, fall apart when you are talking about &#8230; <a href="http://blog.sandipb.net/2008/10/24/apple-is-as-big-a-threat-to-foss-as-microsoft/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Many FOSS enthusiasts do not realize is that Apple is as, if not more, significant threat than Microsoft in the war for software freedom.</p>
<p>Most of the technical arguments that FOSS evangelists have, fall apart when you are talking about Apple and Mac Os X. Mac Os X has very less, if not none, of the perceived instability of Windows. Default applications bundled with the OS do quite a decent job for many users. And OS being based on BSD itself makes most of the arguments about <em>unix-better-than-windows</em> moot. On top of this, a significant number of well known FOSS folks use Macs. I have seen several photos of FOSS conferences where a large number of the people were using Macs (I am assuming they use Os X. I could be wrong).</p>
<p>So the only argument left to fight about against Apple is the philosophical angle, one that has always been the toughest to get across.</p>
<p>I see this problem becoming bigger as Apple makes further inroads. According to <a title="appleinsider apple market share report" href="http://www.appleinsider.com/articles/08/03/17/apple_snags_14_percent_of_us_based_pc_retail_sales_in_february.html">some</a> market reports, they already are a market leader in $1000+ notebooks, and have increased their share to ~10+% in new PC sales in US.</p>
<p>Accordingly, it is very important that FOSS evangelists make sure that their arguments make as much relevance to Macs as to Windows. Stop talking about <acronym title="Blue Screen of Death">BSOD</acronym>s, or Viruses, etc. Talk more about the evils of closed source software.</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.sandipb.net/2008/10/24/apple-is-as-big-a-threat-to-foss-as-microsoft/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Discussing Paul Graham&#8217;s essay on software patents</title>
		<link>http://blog.sandipb.net/2008/10/23/discussing-paul-grahams-essay-on-software-patents/</link>
		<comments>http://blog.sandipb.net/2008/10/23/discussing-paul-grahams-essay-on-software-patents/#comments</comments>
		<pubDate>Thu, 23 Oct 2008 10:37:17 +0000</pubDate>
		<dc:creator>Sandip Bhattacharya</dc:creator>
				<category><![CDATA[General]]></category>
		<category><![CDATA[foss]]></category>
		<category><![CDATA[patents]]></category>
		<category><![CDATA[software patents]]></category>

		<guid isPermaLink="false">http://sandipb.wordpress.com/?p=281</guid>
		<description><![CDATA[Thanks to Saurabh&#8217;s mail on ILUGD, found out about this nice essay by Paul Graham on software patents. Not being much of a lawyer or an expert on these things, but nevertheless having a conviction that software patents are evil, &#8230; <a href="http://blog.sandipb.net/2008/10/23/discussing-paul-grahams-essay-on-software-patents/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Thanks to <a title="The mail which led me to this essay" href="http://article.gmane.org/gmane.user-groups.linux.delhi/21676">Saurabh&#8217;s mail</a> on <a title="ILUGD website" href="http://www.linux-delhi.org">ILUGD</a>, found out about <a title="Paul's essay on software patents" href="http://www.paulgraham.com/softwarepatents.html">this nice essay</a> by <a title="Bio of Paul Graham" href="http://www.paulgraham.com/bio.html">Paul Graham</a> on software patents. Not being much of a lawyer or an expert on these things, but nevertheless having a conviction that software patents are evil, I have dared to comment on parts of this essay. Of course, you are right, whenever possible I have quoted out of context to put him at a disadvantage. <img src='http://blog.sandipb.net/wp-includes/images/smilies/icon_razz.gif' alt=':-P' class='wp-smiley' /> </p>
<p>Now YOU have an incentive to <a title="Paul's essay on software patents" href="http://www.paulgraham.com/softwarepatents.html">go read the essay</a> to find out whether I make sense. <img src='http://blog.sandipb.net/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /> </p>
<blockquote><p>One thing I do feel pretty certain of is that if you&#8217;re against software patents, you&#8217;re against patents in general. Gradually our machines consist more and more of software. Things that used to be done with levers and cams and gears are now done with loops and trees and closures. There&#8217;s nothing special about physical embodiments of control systems that should make them patentable, and the software equivalent not.</p>
<p>Unfortunately, patent law is inconsistent on this point. Patent law in most countries says that algorithms aren&#8217;t patentable. This rule is left over from a time when &#8220;algorithm&#8221; meant something like the Sieve of Eratosthenes. In 1800, people could not see as readily as we can that a great many patents on mechanical objects were really patents on the algorithms they embodied.</p></blockquote>
<p>Yes, we believe that the patents system has moved much away from it&#8217;s original purpose but we especially believe the problem is in software patents/algorithms. Saying that algorithms nowadays are more complex and therefore is ok to patent is incorrect. Algorithms get built over others and with knowledge of previous algorithms, a lot of people are near about the same distance from the frontier. The chances of different people hitting the same method to solve a problem is much higher now than before. This is especially true in the entrepreneurial culture (startups) of today.</p>
<blockquote><p>To be patentable, an invention has to be more than new. It also has to be non-obvious.</p></blockquote>
<p>I have heard this several times. How do you define &#8220;obvious&#8221;? Leaving such a significant issue to such an ambiguous term itself breaks the system.</p>
<blockquote><p>Applying for a patent is a negotiation. You generally apply for a broader patent than you think you&#8217;ll be granted, and the examiners reply by throwing out some of your claims and granting others. So I don&#8217;t really blame Amazon for applying for the one-click patent. The big mistake was the patent office&#8217;s, for not insisting on something narrower, with real technical content.</p></blockquote>
<p>So the system requires applicants to attempt to overreach? And what is the implication of that on public freedom?</p>
<blockquote><p>Where Amazon went over to the dark side was not in applying for the patent, but in enforcing it. A lot of companies (Microsoft, for example) have been granted large numbers of preposterously over-broad patents, but they keep them mainly for defensive purposes. Like nuclear weapons, the main role of big companies&#8217; patent portfolios is to threaten anyone who attacks them with a counter-suit.</p></blockquote>
<p>Another example of how patents have moved away from their original intent. They are no longer an incentive to invent. They are more like tactical business weapons. Used as defense by the very people who have caused this situation to come about.</p>
<blockquote><p>We tell the startups we fund not to worry about infringing patents, because startups rarely get sued for patent infringement. There are only two reasons someone might sue you: for money, or to prevent you from competing with them.</p></blockquote>
<p>So startups, the really innovative side of the business today(Paul says the same thing at the end), don&#8217;t need patents to innovate? I find this argument very inconsistent myself. I thought most startups nowadays, who focus on innovation(rather than just providing &#8220;solutions&#8221;),  measure their success by the patents they manage to claim. But again, why have a system when it is not needed by the same people whom it is supposed to help?</p>
<blockquote><p>If your startup grows big enough, however, you&#8217;ll start to get sued, no matter what you do. If you go public, for example, you&#8217;ll be sued by multiple patent trolls who hope you&#8217;ll pay them off to go away.More on them later.</p>
<p>In other words, no one will sue you for patent infringement till you have money, and once you have money, people will sue you whether they have grounds to or not. So I advise fatalism. Don&#8217;t waste your time worrying about patent infringement. You&#8217;re probably violating a patent every time you tie your shoelaces.</p></blockquote>
<p>Well, this is exactly the problem we talk about.</p>
<blockquote><p>We do advise the companies we fund to apply for patents, but not so they can sue competitors. Successful startups either get bought or grow into big companies. If a startup wants to grow into a big company, they should apply for patents to build up the patent portfolio they&#8217;ll need to maintain an armed truce with other big companies. If they want to get bought, they should apply for patents because patents are part of the mating dance with acquirers.</p></blockquote>
<p>See how a system which was supposed to be a vehicle of invention is now more of a business weapon?</p>
<blockquote><p>Frankly, it surprises me how small a role patents play in the software business. It&#8217;s kind of ironic, considering all the dire things experts say about software patents stifling innovation, but when one looks closely at the software business, the most striking thing is how little patents seem to matter.</p></blockquote>
<p>I am confused now. What are we talking about here?</p>
<blockquote><p>I&#8217;m not sure what the proportions are of the preceding three ingredients, but the custom among the big companies seems to be not to sue the small ones, and the startups are mostly too busy and too poor to sue one another. So despite the huge number of software patents there&#8217;s not a lot of suing going on. With one exception: patent trolls.</p>
<p>Patent trolls are companies consisting mainly of lawyers whose whole business is to accumulate patents and threaten to sue companies who actually make things. Patent trolls, it seems safe to say, are evil.</p>
<p>&#8230;</p>
<p>Patent trolls seem to have caught big companies by surprise. In the last couple years they&#8217;ve extracted hundreds of millions of dollars from them. Patent trolls are hard to fight precisely because they create nothing. Big companies are safe from being sued by other big companies because they can threaten a counter-suit. But because patent trolls don&#8217;t make anything, there&#8217;s nothing they can be sued for. I predict this loophole will get closed fairly quickly, at least by legal standards. It&#8217;s clearly an abuse of the system, and the victims are powerful. [8]</p>
<p>But evil as patent trolls are, I don&#8217;t think they hamper innovation much. They don&#8217;t sue till a startup has made money, and by that point the innovation that generated it has already happened. I can&#8217;t think of a startup that avoided working on some problem because of patent trolls.</p></blockquote>
<p>So do startups innovate for the sake of innovation? And it is not about getting big one day? or not about getting rich one day? I consider this as a convoluted logic. Like saying &#8220;don&#8217;t worry about robbers till you have money they can rob&#8221;. It seems to make sense till you realize that most people don&#8217;t exactly like to live a life of penury.</p>
<blockquote><p>One thing I can say is that 99.9% of the people who express opinions on the subject do it not based on such research, but out of a kind of religious conviction. At least, that&#8217;s the polite way of putting it; the colloquial version involves speech coming out of organs not designed for that purpose.</p></blockquote>
<p>Guilty as charged. <img src='http://blog.sandipb.net/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<blockquote><p>Whether they encourage innovation or not, patents were at least intended to. You don&#8217;t get a patent for nothing. In return for the exclusive right to use an idea, you have to publish it, and it was largely to encourage such openness that patents were established.</p>
<p>Before patents, people protected ideas by keeping them secret. With patents, central governments said, in effect, if you tell everyone your idea, we&#8217;ll protect it for you.</p></blockquote>
<p>Given a choice between software patents or software trade secrets (encrypted php code, anyone?) what would you prefer? I would much prefer the latter. It is so much more of a level playing field that way &#8211; at least for FOSS. It would also give a more relaxed environment for innovators to work in.</p>
<blockquote><p>In the software business I know from experience whether patents encourage or discourage innovation, and the answer is the type that people who like to argue about public policy least like to hear: they don&#8217;t affect innovation much, one way or the other. Most innovation in the software business happens in startups, and startups should simply ignore other companies&#8217; patents. At least, that&#8217;s what we advise, and we bet money on that advice.</p>
<p>The only real role of patents, for most startups, is as an element of the mating dance with acquirers. There patents do help a little. And so they do encourage innovation indirectly, in that they give more power to startups, which is where, pound for pound, the most innovation happens. But even in the mating dance, patents are of secondary importance. It matters more to make something great and get a lot of users.</p></blockquote>
<p>So he ends the essay with a complete contradiction. Why have a system which doesn&#8217;t work the way it is intended to?</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.sandipb.net/2008/10/23/discussing-paul-grahams-essay-on-software-patents/feed/</wfw:commentRss>
		<slash:comments>6</slash:comments>
		</item>
		<item>
		<title>Catching up with Python</title>
		<link>http://blog.sandipb.net/2008/10/20/catching-up-with-python/</link>
		<comments>http://blog.sandipb.net/2008/10/20/catching-up-with-python/#comments</comments>
		<pubDate>Mon, 20 Oct 2008 12:31:52 +0000</pubDate>
		<dc:creator>Sandip Bhattacharya</dc:creator>
				<category><![CDATA[General]]></category>
		<category><![CDATA[perl]]></category>
		<category><![CDATA[python]]></category>

		<guid isPermaLink="false">http://sandipb.wordpress.com/?p=277</guid>
		<description><![CDATA[Am trying to catch up with Python where I left off years ago. &#60;rant&#62; What have they done to the language when I was gone? It is no longer the simple language as before. The decorator syntax looks so .. &#8230; <a href="http://blog.sandipb.net/2008/10/20/catching-up-with-python/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Am trying to catch up with Python where I left off years ago.</p>
<p>&lt;rant&gt; What have they done to the language when I was gone? It is no longer the simple language as before. The <a href="http://wiki.python.org/moin/PythonDecorators">decorator</a> syntax looks so .. well, Perlish. <a href="http://www.python.org/doc/2.5.2/tut/node7.html#SECTION007140000000000000000"> List comprehensions</a>, in some ways very inappropriately named, took a few moments to sink in. It is great that it is concise, but then .. so was Perl! Look where it got &#8220;them&#8221; &#8211; Concise Perl programs looks not too different from a binary file open in a text editor.<br />
&lt;/rant&gt;</p>
<p>There are so many changes to the language since 1.5.2. Does anybody know a place where I can get a list? I am already quite late. They are already discussing about the next major version now.</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.sandipb.net/2008/10/20/catching-up-with-python/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Blog split</title>
		<link>http://blog.sandipb.net/2008/10/13/blog-split/</link>
		<comments>http://blog.sandipb.net/2008/10/13/blog-split/#comments</comments>
		<pubDate>Mon, 13 Oct 2008 14:10:12 +0000</pubDate>
		<dc:creator>Sandip Bhattacharya</dc:creator>
				<category><![CDATA[General]]></category>
		<category><![CDATA[blogging]]></category>
		<category><![CDATA[personal]]></category>
		<category><![CDATA[sandipb.net]]></category>

		<guid isPermaLink="false">http://sandipb.wordpress.com/?p=273</guid>
		<description><![CDATA[For some (probably conceited ) reason, I felt that my blog was getting overrun (or about to really get overrun) with non-technical babble arising from my frustration about where this country is headed. So before I turn off those three &#8230; <a href="http://blog.sandipb.net/2008/10/13/blog-split/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>For some (probably conceited <img src='http://blog.sandipb.net/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' />  ) reason, I felt that my blog was getting overrun (or about to really get overrun) with non-technical babble arising from my frustration about where this country is headed. So before I turn off those three of you who read my blog, I have decided to split my blog on a very fuzzy boundary of technical/non-technical lines. My non-technical rants will now be posted at the appropriately named <a href="http://rants.sandipb.net" class="broken_link">http://rants.sandipb.net</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.sandipb.net/2008/10/13/blog-split/feed/</wfw:commentRss>
		<slash:comments>7</slash:comments>
		</item>
		<item>
		<title>Using ffmpeg on Ubuntu to convert DV videos for video sharing websites</title>
		<link>http://blog.sandipb.net/2008/09/21/using-ffmpeg-on-ubuntu-to-convert-dv-videos-for-video-sharing-websites/</link>
		<comments>http://blog.sandipb.net/2008/09/21/using-ffmpeg-on-ubuntu-to-convert-dv-videos-for-video-sharing-websites/#comments</comments>
		<pubDate>Sun, 21 Sep 2008 10:08:37 +0000</pubDate>
		<dc:creator>Sandip Bhattacharya</dc:creator>
				<category><![CDATA[General]]></category>
		<category><![CDATA[ffmpeg]]></category>
		<category><![CDATA[kino]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[panasonic]]></category>
		<category><![CDATA[tech]]></category>
		<category><![CDATA[ubuntu]]></category>
		<category><![CDATA[video]]></category>
		<category><![CDATA[video editing]]></category>
		<category><![CDATA[vimeo]]></category>

		<guid isPermaLink="false">http://sandipb.wordpress.com/?p=252</guid>
		<description><![CDATA[To begin with, this is the problem that I had. I had recorded a short clip using my Panasonic NV-GS330 camcorder. I had to upload it to Vimeo, my video sharing website of choice. From the camcorder to the computer &#8230; <a href="http://blog.sandipb.net/2008/09/21/using-ffmpeg-on-ubuntu-to-convert-dv-videos-for-video-sharing-websites/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>To begin with, this is the problem that I had. I had recorded a short clip using my <a href="http://panasonic.net/pavc/camcorder/dv/global/products/nv-gs330/" class="broken_link">Panasonic NV-GS330</a> camcorder. I had to upload it to <a href="http://vimeo.com/">Vimeo</a>, my video sharing website of choice.</p>
<h3>From the camcorder to the computer</h3>
<p>Importing the video from the camcorder to the laptop was not much of a problem. I plugged in the camcorder to my laptop using a <a href="http://en.wikipedia.org/wiki/FireWire">firewire</a> card. Then I used <a href="http://www.kinodv.org/">Kino</a> to position the tape (the camcorder uses <a href="http://en.wikipedia.org/wiki/Mini_dv">mini dv</a> tapes) just before the beginning of the clip I wanted to import and hit the <em>capture</em> button. Soon, the dv capture file for the clip was lying in my home directory.</p>
<h3>Figuring out the output format</h3>
<p>What is your format of choice for uploading to the video sharing website? Regardless of the format you use, all video sharing website will re-encode it to the video standard(or quality) that they use to serve the clips to the viewers. To avoid changing too many things in this re-encoding, which decreases quality, it is always better to go with the recommendations of the video sharing website. Luckily, vimeo has quite a <a href="http://vimeo.com/help/compression">detailed page</a> about the characteristics of the video they would like their users to upload. This makes it easy for me, so I note it down:</p>
<ul>
<li> They want the h.264 codec. </li>
<li>They don&#8217;t care much for your frame rate if it is a regular video(and not HD) &#8211; so I can keep my video in PAL.</li>
<li>They would like a keyframe every 30 frames &#8211; umm, this will make the videos larger, but let me go ahead with this anyway. </li>
<li>They would like a max video bitrate of 1800kb/s. That is a bit too much for the kind of video I have, so I will keep it down to 900kbps for now (actually you can probably go down to 500). The lower this rate is, the lesser is the size of the video that you will have to upload, but unfortunately lower is the quality.
</li>
<li>Size recommended in 640&#215;480 (4:3 ratio) &#8211; I tried uploading my 16:9 video anyway, but they squished it down to 4:3 and it looked terrible. So I resolved to keep the output video size to 640&#215;480 to prevent any scaling during re-encoding.
</li>
<li>Do I want de-interlacing? I checked my camcorder manual, and yes, the video is interlaced. Actually it seems most non-professional camcorders have interlaced video anyway, so you would most possibly need to enable this.
</li>
<li>Audio quality recommended is 128kbps. Since my audio is regular day-to-day conversation and noises(as opposed to music or audio where quality is more critical), I am ok with 64kbps (anything to keep the file size low). Actually, even if I had gone down to 32kbps, I don&#8217;t think anyone will notice.
</li>
<li>Vimeo recommends AAC as the audio format, but somehow vlc had this problem playing audio for the generated videos. So I decided to go with mp3 as the output audio format instead. However, this has it&#8217;s own problem in Ubuntu &#8211; ffmpeg doesn&#8217;t come with mp3 support in Ubuntu due to it&#8217;s licencing restrictions. Using the medibuntu repository, as described <a href="http://www.pyrosoft.co.uk/blog/2008/04/15/encoding-mp3-audio-with-ffmpeg-on-ubuntu-hardy/" title="Encoding mp3 audio with ffmpeg on Ubuntu Hardy">in this life saving tip</a>, helped me get a version of ffmpeg which encodes mp3 files.
</li>
</ul>
<h3>Using ffmpeg</h3>
<p>Now comes the tough part &#8211; using the non-linear video editor <a href="http://ffmpeg.mplayerhq.hu/">ffmpeg</a> and it&#8217;s millions of knobs <img src='http://blog.sandipb.net/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' />  . Actually, in it&#8217;s simplest form ffmpeg is really really easy to use! Just using <code>ffmpeg -i input.dv -vcodec h264 output.avi</code> will do the job for you. But it is not going to give you the requirements that you had just drawn up. For one, the default bitrate is 200kbps, which will give you terrible video. Also, I have video in 16:9 format, as my camcorder records in widescreen, and I have to convert the video into 4:3 640&#215;480 format. The right way to do it, so that you don&#8217;t have to crop off any video data, is to convert the video into a <a href="http://en.wikipedia.org/wiki/Letterbox">letterbox form</a>, which ffmpeg can do very effectively.</p>
<h5> Resizing video from 16:9 to 4:3 (letterboxing) using ffmpeg</h5>
<p>ffmpeg has a <code>-s (width)x(height)</code> parameter which can let you resize the video. To preserve the aspect ratio for my video in the 4:3 format with 640 being the final width of the video, my video would first need to be scaled to the required width as it is the larger of the two dimensions. Then black bars would be added to the height to make it add up to 480. The magic resizing size is 640&#215;360 (<code>-s 640x360</code>), with 40 pixels each, above and below the video (<code>-padtop 60 -padbottom 60 </code>), to reach 480 in the vertical dimension. The padding color is usually black (<code>-padcolor 000000</code>) but you can also go with white to make the video merge into the usually white background of the websites. Black, to me, gives quite a <i>retro</i> feel to the video <img src='http://blog.sandipb.net/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' />  and so I would go with that.</p>
<h5> The actual command line</h5>
<p>There is a huge list of switches that can be used in ffmpeg to get the video of your choice. The advanced ones require you to understand intimately how video compression works. A lot of optimization is possible which can get you the best results for the nature of the video. However, I decided to keep my learning curve as short as I could and came up with a configuration which works for me.</p>
<p><code><br />
/usr/bin/ffmpeg -threads 2 -f dv -i input.dv -vcodec h264 -g 30 -deinterlace -b 900k -s 640x360 -padtop 60 -padbottom 60 -padcolor 000000 -aspect 4:3 -acodec mp3 -ab 64k output.avi<br />
</code></p>
<h3>An easier way</h3>
<p>Of course, there are numbers here that you would like to tweak for your needs, and therefore I have created this <a href="http://www.sandipb.net/downloads/dv2avi.sh.txt">little bash wrapper script</a> to make it really easier for you to tweak it. Edit the config values at the top of the script to suit your taste. You can also configure the metadata (like author name, copyright, etc.) of your videos. Remember to at least change these, unless you want me to own the copyrights to your uploaded videos <img src='http://blog.sandipb.net/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /> .</p>
<p>This is the advantage of using a linear video editing tool like ffmpeg. It is so easy to script it for regular uses!</p>
<h3>Tweaking your file size and quality</h3>
<p>With the configuration values earlier, I was able to convert a 28MB DV file(about 8 seconds in duration, these files are big!) to an excellent 1MB AVI file. With a video bitrate of 500kbps however, this came down to about 600kb and an acceptable video quality. You should tweak with the video bit rate to see which one gives you the best trade off for your video.</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.sandipb.net/2008/09/21/using-ffmpeg-on-ubuntu-to-convert-dv-videos-for-video-sharing-websites/feed/</wfw:commentRss>
		<slash:comments>10</slash:comments>
		</item>
		<item>
		<title>Not tougher but unfairer laws</title>
		<link>http://blog.sandipb.net/2008/09/18/not-tougher-but-unfairer-laws/</link>
		<comments>http://blog.sandipb.net/2008/09/18/not-tougher-but-unfairer-laws/#comments</comments>
		<pubDate>Wed, 17 Sep 2008 22:36:29 +0000</pubDate>
		<dc:creator>Sandip Bhattacharya</dc:creator>
				<category><![CDATA[General]]></category>
		<category><![CDATA[bjp]]></category>
		<category><![CDATA[India]]></category>
		<category><![CDATA[laws]]></category>
		<category><![CDATA[police]]></category>
		<category><![CDATA[pota]]></category>
		<category><![CDATA[terrorism]]></category>

		<guid isPermaLink="false">http://sandipb.wordpress.com/?p=245</guid>
		<description><![CDATA[For some unknown reason, I occasionally waste my time reading comments on news stories at ToI (Times of India). For all those waiting to pounce upon me for reading a virtual tabloid &#8230; I know, I know. The only reason &#8230; <a href="http://blog.sandipb.net/2008/09/18/not-tougher-but-unfairer-laws/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>For some unknown reason, I occasionally waste my time reading comments on news stories at <a href="http://timesofindia.indiatimes.com">ToI (Times of India)</a>. For all those waiting to pounce upon me for reading a virtual tabloid &#8230;  I know, I know. The only reason I read ToI is because they are probably one of the fastest with breaking news in India.</p>
<p>In any case, as I was saying, I was recently going through the comments at ToI  after the Delhi blasts. It kept sickening me as I kept on reading idiots, writing in barely comprehensible English, rambling about how Indians needed &#8220;tougher laws&#8221;. I closed my eyes to let the fleeting wave of disgust and condescension pass over, shuddered, and kept reminding myself of the realities of the country I lived in. It pained me to see how ordinary fellow citizens are being misled by the irresponsible, incompetent and corrupt politicians &#8211; both in the opposition and the ruling party.</p>
<p>The phrase &#8220;tougher laws&#8221;  is a good example of marketing propaganda. Just using the right words makes it seem as if it is the solution to our apparent problems. Just put these laws in place, and, voila, terrorism would disappear in India. Could running the country be any easier?</p>
<p>What a load of bull*. The fact is there is nothing tough about the laws that BJP/Modi/Moily and others are harping about. To actually phrase it correctly, the right words to be used here are <em>unfairer laws</em> (if I may coin such a word for brevity).</p>
<p>I had written sometime back about <a href="http://blog.sandipb.net/2008/05/19/the-pota-games/">the thoughtlessness of POTA</a>, which BJP has been clamoring for a while to be put in place. Others are talking about putting in place similar acts like MCOCA and something similar in Modi&#8217;s state.</p>
<p>I will just repeat the highlights of the POTA here &#8211; it allows you to be imprisoned for six months on mere suspicion and without even filing charges in court, leave alone the delays in the court! It allows your (most possibly tortured) confessions in front of a policeman as evidence, as opposed to confession before a magistrate. The act is even accused to be based on the assumption that the person is guilty until proven otherwise &#8211; a complete departure from the basis of justice in any modern country where a person is considered innocent till proven guilty.</p>
<p>The sad thing is that people are assuming all this is good as long as it is applied on the bad guys. The basic fallacy in the line of thinking is that one is committing the same mistake as the law itself &#8211; they are assuming that the police has caught the bad guys in the first place. I am not even going into one of the basic principles of a democracy &#8211; justice that is fair and reasonable.</p>
<p>How many of these POTA zealots has any reasonable confidence that:</p>
<ul>
<li> the police is competent enough to distinguish between good guys and bad guys, not based on mere suspicion but with chargeable evidence</li>
<li>The police is not so much under pressure for results that they are looking for a scapegoat</li>
<li>the police is not prejudiced enough to affect their investigation. Prejudices could be about religion, caste, income, etc.</li>
</ul>
<p>We all know of landmark cases like the recent Arushi murder case, or the Nithari cannibalism cases, or the BMW case, or any of the recent glorified police-media crime circuses. Don&#8217;t they give you a lot of confidence in the competence of policemen to catch the bad guys in the first place? It is amusing how the very people who had been critical of Gujarat police of being one of the accessories of the riots there, are actually taking the same police by their word that they have caught the people behind the Ahmadabad blasts.</p>
<p>The problem is that each of these common people like you and me, keep believing that cases like Arushi&#8217;s father or other similar stories will not happen with us. It takes only one of these to destroy the lives of you and the people around you. And only when they do happen to you, would you realize the need to keep the justice system strong, alive and more importantly  <em>fair</em> in this country.</p>
<p>As in everything about India, the country revels in symbolism and not in actual work. Clamoring for POTA is such an act of  symbolism. Just put it in place, and go around thinking that you have fixed the problem. It is like starting off a poverty alleviation program and going around telling people that you have taken care of poverty &#8211; never mind that only 5% of that money you put in will actually reach the poor (the actual objective of the program in the first place).</p>
<p>It infuriates me no end every week how completely useless checks are being done in malls and other public places, which only ends with us getting into needless traffic snarls and delays. Especially, when I know with the sham of a check being done, anybody can drive into the basement parking of any of these malls with a car loaded with tonnes of explosives and blow up the mall without being caught. Another example of symbolism &#8211; lip service for mall owners to show off their apparent &#8220;concern&#8221; about security.</p>
<p>Have you seen how the security checks while getting into the cinema hall in the mall is just so much stricter than the one in entering the mall? And this security check is not for your security &#8211; it is for the cinema owners so that you are forced to buy their overpriced food (so you are checked to see that you are not smuggling any food in), it is for the movie producers so that you cannot take bootleg copies of their movies (so you cannot get that pocket camera you have been carrying for casual snaps inside the hall). Doesn&#8217;t this give you a good perspective about how seriously the mall owners think about your security?</p>
<p>Nobody will talk about fixing the real problems in the security scene of our country today &#8211; corruption in police and the judicial system, enough human intelligence, enough training and sensitization of police so that the common man is comfortable enough to work with the police, co-ordination between the states and the center, more investment to make a world class police force, adequate staffing in the perenially understaffed and overworked police force.</p>
<p>BTW, I actually find it very amusing how after every blast someone stands up saying &#8220;We had warned you that something like that might happen&#8221;, just to score a point. After the Bangalore blasts, the center claimed so. After the Delhi blasts, the Gujarat government claimed so. It is a proper circus out here.</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.sandipb.net/2008/09/18/not-tougher-but-unfairer-laws/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Draft of Indian Government&#8217;s policy on Open Standards in e-governance released</title>
		<link>http://blog.sandipb.net/2008/09/04/draft-of-indian-governments-policy-on-open-standards-in-e-governance-released/</link>
		<comments>http://blog.sandipb.net/2008/09/04/draft-of-indian-governments-policy-on-open-standards-in-e-governance-released/#comments</comments>
		<pubDate>Wed, 03 Sep 2008 19:20:50 +0000</pubDate>
		<dc:creator>Sandip Bhattacharya</dc:creator>
				<category><![CDATA[General]]></category>
		<category><![CDATA[goi]]></category>
		<category><![CDATA[standards]]></category>
		<category><![CDATA[tech]]></category>

		<guid isPermaLink="false">http://sandipb.wordpress.com/?p=239</guid>
		<description><![CDATA[Thanks to Vinay Sreenivasa for letting us know on the ILUGD list: The government has released a draft version of a Policy on Open standards for e-Governance. It is presently open for Public review. Please find the policy at the &#8230; <a href="http://blog.sandipb.net/2008/09/04/draft-of-indian-governments-policy-on-open-standards-in-e-governance-released/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Thanks to Vinay Sreenivasa for <a href="http://article.gmane.org/gmane.user-groups.linux.delhi/20615">letting us know on the ILUGD list</a>:</p>
<blockquote><p>
The government has released a draft version of a Policy on Open standards for e-Governance. It is presently open for Public review.</p>
<p>Please find the policy at the link below-<br />
<a href="http://egovstandards.gov.in/Policy_Open_Std_review" class="broken_link">http://egovstandards.gov.in/Policy_Open_Std_review</a></p>
<p>The policy seems to have some really good points like-<br />
5.1) Mandatory Characteristics:<br />
5.1.1)Selected Standard should be Royalty Free for life time of the standard.<br />
5.1.2)Selected Standard should be developed in a collaborative and consensus manner and not led by a single agency or a small closed group of interested parties<br />
5.1.3)Selected Standard should be recursively open; They shall not use unpublished extensions
</p></blockquote>
<p>As a side note, the website says that it belongs to &#8220;IntraGOV Group, NICHQ, National Informatics Centre, Department of Information Technology, Ministry of Communications and Information Technology&#8221;. And the site runs on Plone! Nice!</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.sandipb.net/2008/09/04/draft-of-indian-governments-policy-on-open-standards-in-e-governance-released/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>A. R. Rahman on the future of music</title>
		<link>http://blog.sandipb.net/2008/08/18/a-r-rahman-on-the-future-of-music/</link>
		<comments>http://blog.sandipb.net/2008/08/18/a-r-rahman-on-the-future-of-music/#comments</comments>
		<pubDate>Mon, 18 Aug 2008 14:11:29 +0000</pubDate>
		<dc:creator>Sandip Bhattacharya</dc:creator>
				<category><![CDATA[General]]></category>
		<category><![CDATA[a r rahman]]></category>
		<category><![CDATA[bollywood]]></category>
		<category><![CDATA[music]]></category>

		<guid isPermaLink="false">http://sandipb.wordpress.com/?p=220</guid>
		<description><![CDATA[It is indeed heartening to know that one of the finest composers in India has such a progressive outlook about the future of music. Excerpt from Hindustan Times. Music companies must recognise the changing ground reality. Today the conventional outlets &#8230; <a href="http://blog.sandipb.net/2008/08/18/a-r-rahman-on-the-future-of-music/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>It is indeed heartening to know that one of the finest composers in India has such a progressive outlook about the future of music. <a href="http://www.hindustantimes.com/StoryPage/StoryPage.aspx?id=35dbcb94-f018-4a11-9c5f-269d1d70a90d">Excerpt from Hindustan Times</a>.</p>
<blockquote><p>Music companies must recognise the changing ground reality. Today the conventional outlets for music sales are drying up. Soon all music will be free while the performers and performances will be paid for.</p></blockquote>
<p>Found the link at <a href="http://appaji.livejournal.com/52636.html">appaji.net</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.sandipb.net/2008/08/18/a-r-rahman-on-the-future-of-music/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

