<?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>Feeding the Bit Bucket</title>
	<atom:link href="http://www.adrianmouat.com/bit-bucket/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.adrianmouat.com/bit-bucket</link>
	<description>Software development thoughts and rants</description>
	<lastBuildDate>Wed, 09 Jun 2010 17:02:03 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.2</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>The programming equivalent of &#8220;a long stand&#8221;</title>
		<link>http://www.adrianmouat.com/bit-bucket/2010/05/the-programming-equivalent-of-a-long-stand/</link>
		<comments>http://www.adrianmouat.com/bit-bucket/2010/05/the-programming-equivalent-of-a-long-stand/#comments</comments>
		<pubDate>Mon, 31 May 2010 19:27:16 +0000</pubDate>
		<dc:creator>Adrian Mouat</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://www.adrianmouat.com/bit-bucket/?p=148</guid>
		<description><![CDATA[Builders apprentices often get sent on pointless endeavours, such as going for &#8220;a long stand&#8221;, &#8220;tartan paint&#8221; or a &#8220;sky hook&#8221;.
I think I saw the programming equivalent today &#8211; proving that a GUID is not unique.
The poor programmer does get a bit much stick, but he has just tried to write a loop that will [...]]]></description>
			<content:encoded><![CDATA[<p>Builders apprentices often get sent on pointless endeavours, such as going for &#8220;a long stand&#8221;, &#8220;tartan paint&#8221; or a &#8220;sky hook&#8221;.</p>
<p>I think I saw the programming equivalent today &#8211; <a href="http://stackoverflow.com/questions/1705008/simple-proof-that-guid-is-not-unique">proving that a GUID is not unique</a>.</p>
<p>The poor programmer does get a bit much stick, but he has just tried to write a loop that will take 10790283070806014188970 years to compute. He then asks if using multiple threads will help solve his problem&#8230;</p>
]]></content:encoded>
			<wfw:commentRss>http://www.adrianmouat.com/bit-bucket/2010/05/the-programming-equivalent-of-a-long-stand/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Clojure Resources</title>
		<link>http://www.adrianmouat.com/bit-bucket/2010/05/clojure-resources/</link>
		<comments>http://www.adrianmouat.com/bit-bucket/2010/05/clojure-resources/#comments</comments>
		<pubDate>Thu, 13 May 2010 20:03:00 +0000</pubDate>
		<dc:creator>Adrian Mouat</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://www.adrianmouat.com/bit-bucket/?p=136</guid>
		<description><![CDATA[I&#8217;ve recently been learning Clojure, a form of Lisp that runs on the JVM.  There are already a lot of resources about Clojure on the internet, but they vary in depth and usefulness. Therefore, I&#8217;ve compiled a bit of an overview of the various resources, in the hope that it helps the new Clojure (and [...]]]></description>
			<content:encoded><![CDATA[<p>I&#8217;ve recently been learning <a href="http://www.clojure.org">Clojure</a>, a form of Lisp that runs on the JVM.  There are already a lot of resources about Clojure on the internet, but they vary in depth and usefulness. Therefore, I&#8217;ve compiled a bit of an overview of the various resources, in the hope that it helps the new Clojure (and Lisp) programmer get started:</p>
<ul>
<li> Why you might want to consider learning/using Clojure is concisely covered by <a href="http://clojure.org/rationale">Rich Hickey here</a>.</li>
<li>One of the first decisions you will face is which editor to use. Unfortunately, this isn&#8217;t necessarily an easy decision. Clojure and Lisp programmers typically use a REPL to interact with their programs as they are writing them. You want your editor to have some level of integration with a Clojure REPL. This <a href="http://www.assembla.com/wiki/show/clojure/Getting_Started">Getting Started</a> resource covers most of the common choices. It&#8217;s probably worth saying that Emacs offers one of the most mature and powerful environments and is a good choice if you are already comfortable with the editor. If you&#8217;re on Windows, <a href="http://clojure.bighugh.com/">Clojure Box</a> offers a quick way to get started with Clojure and Emacs. Personally, I&#8217;ve tried  the Eclipse plug-in <a href="http://code.google.com/p/counterclockwise/">counter-clockwise</a>, but had some problems with it and I currently use Vim set-up according to<a href="http://writequit.org/blog/?p=386"> this guide at write-quit</a>. (I see counter-clockwise has had a new release since I tested it, so it may well be worth revisiting).</li>
<li>Once you have your environment set up, you will probably want some sort of quick start guide. One of the most commonly referenced tutorials is <a href="http://java.ociweb.com/mark/clojure/article.html">R. Mark Volkmann&#8217;s at ociweb</a>. This is certainly a very valuable and authoritative resource, but I found it rather hard-going for a first contact. The <a href="http://www.youtube.com/watch?v=Aoeav%5FT1ARU&amp;feature=PlayList&amp;p=AC43CFB134E85266&amp;index=0">Intro to Clojure</a> video series was highly rated by <a href="http://stackoverflow.com/questions/599519/which-tutorial-on-clojure-is-best">this stackoverflow question</a>, but I can&#8217;t say I want to use videos to learn a language. Satish Talim suggested <a href="http://clojure-notes.rubylearning.org/">Clojure Notes</a>, which looks like a good introduction and may be the best place to start.</li>
<li>Regarding books, Stuart Halloway has <a href="http://thinkrelevance.com/blog/2008/09/16/pcl-clojure.html">ported some of the Practical Common Lisp</a> book (<a href="http://www.gigamonkeys.com/book/">original available free here</a>) to Clojure. This leads me onto his <a href="http://www.pragprog.com/titles/shcloj/programming-clojure">Programming Clojure</a> book, which is the best resource I have found so far (but not free). There is also <a href="http://en.wikibooks.org/wiki/Learning_Clojure">a wikibook</a> available, but it seems incomplete.</li>
<li><a href="http://planet.clojure.in">Planet Clojure</a> is your best reference for new and interesting Clojure posts (they describe themselves as a &#8220;meta-blog&#8221; of various Clojure hackers and contributors).</li>
</ul>
<p>Hope this helps someone!</p>
]]></content:encoded>
			<wfw:commentRss>http://www.adrianmouat.com/bit-bucket/2010/05/clojure-resources/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
		<item>
		<title>The Pain of Premiere Pro</title>
		<link>http://www.adrianmouat.com/bit-bucket/2009/11/the-pain-of-premiere-pro/</link>
		<comments>http://www.adrianmouat.com/bit-bucket/2009/11/the-pain-of-premiere-pro/#comments</comments>
		<pubDate>Mon, 09 Nov 2009 20:46:48 +0000</pubDate>
		<dc:creator>Adrian Mouat</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://www.adrianmouat.com/bit-bucket/?p=111</guid>
		<description><![CDATA[Permiere Pro has lately proven itself to be the singular worst piece of software I have ever had the misfortune to use. It has cost us far more time than it has saved, certainly several times its RRP in wasted hours. Normally I&#8217;m a software developer, but a project I was working on required me [...]]]></description>
			<content:encoded><![CDATA[<p>Permiere Pro has lately proven itself to be the singular worst piece of software I have ever had the misfortune to use. It has cost us far more time than it has saved, certainly several times its RRP in wasted hours. Normally I&#8217;m a software developer, but a project I was working on required me to do some basic video editing and I was shocked by the poor quality of the software being used.</p>
<p>In case you don&#8217;t know, Premiere Pro is &#8220;professional&#8221; video editing software, in a similar category to Avid Xpress and Apple&#8217;s Final Cut Pro. And to be fair, Premiere certainly seems to be fully featured. It&#8217;s just that it doesn&#8217;t work. It randomly crashes. Constantly. And when it&#8217;s not randomly crashing, it&#8217;s repeatedly crashing at the same point.</p>
<p style="text-align: left;">The first thing that irritated me is that I&#8217;m running it on a split new laptop with the maximum amount of memory (which is admittedly constrained to &lt; 4 GB as I&#8217;m using 32-bit Windows XP) and yet it gives me messages such as &#8220;Adobe is running low on system memory. Please save your project and proceed with caution.&#8221;. Quickly you realise that it&#8217;s best to give Adobe full run of the machine and close any other programs which use memory (like Web browsers).</p>
<p style="text-align: left;">The next thing that perplexed me was that <em>every</em> time I close Premiere, I get a message telling me that Premiere unexpectedly quit and offering to send Adobe the crash report. No, Adobe, the quit wasn&#8217;t unexpected &#8212; I normally exited the application &#8212; but apparently you shouldn&#8217;t do that in Adobe land. This started to bug me, so I filled in the crash report and attempted to send it. Except I can&#8217;t, because my e-mail address isn&#8217;t valid according to Adobe<sup>1</sup>.</p>
<p style="text-align: center;"><img class="size-full wp-image-119 aligncenter" title="Premiere Pro Crash Report" src="http://www.adrianmouat.com/bit-bucket/wp-content/uploads/2009/11/crash_report_e-mail1.png" alt="crash_report_e-mail" width="550" height="506" /></p>
<p>Quite often, Premiere doesn&#8217;t want to import certain media. Sometimes it tells you this, other times it imports the footage but only displays a blank screen or inverted colours. This is irritating, but can normally be worked around by using free software such as ffmpeg or Virtual Dub to re-encode the footage. (Yes, these free programs seem to handle various video formats better than Adobe&#8217;s £750 payware. Adobe even <a href="http://kb2.adobe.com/cps/406/kb406449.html#format">suggest using VirtualDub themselves</a> (see Solution 6)).</p>
<p>However, these issues pale into insignificance once you face the beast that goes by the name of &#8220;Export Media&#8221;. This launches what is sort of an associated application known as &#8220;Adobe Media Encoder&#8221;, which renders your project into your final move file (e.g. .mov, .avi or .mpg). Sometimes this works flawlessly.  Sometimes it will stop at a seemingly random point in the encoding and the logfile will contain such revelations as:</p>
<blockquote>
<pre>...
 - Encoding Time: 00:01:07

2009-10-28 14:18:47 : Encoding Failed

-----------------------------------------

Error compiling movie.

 Unknown error.

-----------------------------------------</pre>
</blockquote>
<p>Hmm, &#8220;Unknown Error&#8221;. Doesn&#8217;t really help, does it? Restarting the export will result in it stopping at exactly the same point. This forces you to come up with random hypotheses as to what caused it crash, testing them in order until you either fix the problem or give up. Sometimes re-encoding the original video footage can fix things, which would suggest the video is corrupted (although it will play fine in Premiere and other video software).</p>
<p>I had thought &#8220;Unknown Error&#8221; was the least useful error message I&#8217;d seen. I was wrong. Sometimes the encoding fails part-way, yet Media Encoder reports &#8220;Encoding completed successfully&#8221;. I don&#8217;t want to take personal offence from a bit of software, but it stopped with the progress bar halfway, created half a video file then declared it was happily done. Surely that&#8217;s simply rude?</p>
<p>Of course, you can attempt to find and follow <a href="http://kb2.adobe.com/cps/332/332331.html">the official Adobe advice</a>. The first &#8220;note&#8221; here tells you to restart your computer &#8220;to refresh its memory&#8221; (read: not only is our software full of bugs, its also full of memory leaks). Solution 1 is to turn various effects off (read: lots of our effects have bugs). Solution 2 is to change the encoding (read: our codecs have bugs). The third solution annoys me even more: &#8220;Quit any applications that may be interfering with the render process&#8221;. Why? Surely Adobe should be able to share memory and resources with other processes? Solution 4 is &#8220;Use a different codec for your export&#8221; (read: our export function is full of bugs). Solution 5 is &#8220;Disable Auto Save&#8221; (read: our basic functionality breaks our other functions). I tried all of these; no dice.</p>
<p>In the interest of of ending on a positive, helpful note, I have the following suggestions for how Adobe can make things better:</p>
<ul>
<li>Replace &#8220;Unkown Error&#8221; wherever it occurs in the codebase. Handle exceptions properly &#8211; you&#8217;re meant to be a professional company and this is an very sloppy coding practice.</li>
<li>Test the software. I&#8217;m using a split new machine from a vary large vendor. Why on earth doesn&#8217;t it work? There must be huge flaws in the testing process at Adobe.</li>
<li>Remove support for features that don&#8217;t work. A particular encoding doesn&#8217;t work a given percentage of the time? Either fix it, or don&#8217;t pretend to support it.</li>
<li>Look at <a href="http://kb2.adobe.com/cps/332/332331.html">your own advice</a>. Most of these &#8220;solutions&#8221; indicate deficiencies in the underlying software.</li>
<li>Provide some sort of cuddly toy with each purchase of Premiere Pro. Although this won&#8217;t make the software any better, it will reduce stress by giving users a representation of Adobe that can be tortured during periods of stress brought on by attempting to use the software.</li>
</ul>
<div id="_mcePaste" style="overflow: hidden; position: absolute; left: -10000px; top: 690px; width: 1px; height: 1px;">- Source File: C:\DOCUME~1\amouat\LOCALS~1\Temp\adobe_sucks.prproj</p>
<p>- Output File: C:\beingrid\be-demos\doc\WP6.2-DemoDevelopment\BE03\video\demo-video\with_titles\adobe_sucks_1.mov</p>
<p>- Preset Used: Custom</p>
<p>- Video: 1024&#215;768, 15 [fps], Progressive, Quality 100</p>
<p>- Audio: 48000 Hz, Mono, 16 bit</p>
<p>- Bitrate: H.264</p>
<p>- Encoding Time: 00:01:07</p>
<p>2009-10-28 14:18:47 : Encoding Failed</p>
<p>&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8211;</p>
<p>Error compiling movie.</p>
<p>Unknown error.</p>
<p>&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8211;</p>
</div>
<ol class="footnotes"><li id="footnote_0_111" class="footnote">I think this must be because my work address contains too many dots for Adobe. I&#8217;ve redacted my address as this post does not represent the views of my employer, just me. But trust me, it&#8217;s valid.</li></ol>]]></content:encoded>
			<wfw:commentRss>http://www.adrianmouat.com/bit-bucket/2009/11/the-pain-of-premiere-pro/feed/</wfw:commentRss>
		<slash:comments>6</slash:comments>
		</item>
		<item>
		<title>Cloud for Academia?</title>
		<link>http://www.adrianmouat.com/bit-bucket/2009/10/cloud-for-academia/</link>
		<comments>http://www.adrianmouat.com/bit-bucket/2009/10/cloud-for-academia/#comments</comments>
		<pubDate>Wed, 07 Oct 2009 21:15:33 +0000</pubDate>
		<dc:creator>Adrian Mouat</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://www.adrianmouat.com/bit-bucket/?p=107</guid>
		<description><![CDATA[GridVoices have published my article &#8220;Cloud for Academia&#8220;, which takes a brief look at how various Cloud offerings could be used for HPC applications.
UPDATE 4/11/2009: This article has now been syndicated (if that&#8217;s the right word!) on HPCWire.
]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.gridipedia.eu/grid_voices/">GridVoices</a> have published my article &#8220;<a href="http://www.gridipedia.eu/grid_voices/?p=174">Cloud for Academia</a>&#8220;, which takes a brief look at how various Cloud offerings could be used for HPC applications.</p>
<p><strong>UPDATE 4/11/2009</strong>: This article has now been syndicated (if that&#8217;s the right word!) on <a href="http://www.hpcwire.com/specialfeatures/cloud_computing/features/Cloud-for-Academia-68614567.html">HPCWire.</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.adrianmouat.com/bit-bucket/2009/10/cloud-for-academia/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Package Managers &#8211; Linux&#8217;s Killer Feature?</title>
		<link>http://www.adrianmouat.com/bit-bucket/2009/08/package-managers-linuxs-killer-feature/</link>
		<comments>http://www.adrianmouat.com/bit-bucket/2009/08/package-managers-linuxs-killer-feature/#comments</comments>
		<pubDate>Thu, 20 Aug 2009 21:11:12 +0000</pubDate>
		<dc:creator>Adrian Mouat</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://www.adrianmouat.com/bit-bucket/?p=102</guid>
		<description><![CDATA[Package managers &#8211; your yums, portages, apts etc &#8211; must be one of the best features of linux. It used to be pretty impossible to keep an installation up-to-date, now it&#8217;s trivial most of the time.
I actually wonder if this is Linux&#8217;s killer feature &#8211; whilst your Windows installation slowly rots until you are prepared [...]]]></description>
			<content:encoded><![CDATA[<p>Package managers &#8211; your yums, portages, apts etc &#8211; must be one of the best features of linux. It used to be pretty impossible to keep an installation up-to-date, now it&#8217;s trivial most of the time.</p>
<p>I actually wonder if this is Linux&#8217;s killer feature &#8211; whilst your Windows installation slowly rots until you are prepared to face the pain of a major OS upgrade, your Linux installation has been incrementally improving itself. I reckon that Gnome overtook XP sometime in the last few releases in terms of features and (in some places) usability.</p>
<p>Sure, Windows will probably retake the lead with Windows 7, but how long will it be until the next major version of windows? XP is a staggering 8 years old, will it take as long until most people are prepared to update again? In that case, Microsoft may find they are in serious trouble by then, facing Linux distributions with with improved <a href="http://www.linuxfoundation.org/collaborate/lwf">kernels</a>, <a href="http://btrfs.wiki.kernel.org">file systems</a> and <a href="http://live.gnome.org/ThreePointZero/Plan">desktops</a>, especially with distributions like Ubuntu pushing usability and user experience.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.adrianmouat.com/bit-bucket/2009/08/package-managers-linuxs-killer-feature/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Hunter S. Thompson and the Death of Objectivity</title>
		<link>http://www.adrianmouat.com/bit-bucket/2009/07/hunter-s-thompson-and-the-death-of-objectivity/</link>
		<comments>http://www.adrianmouat.com/bit-bucket/2009/07/hunter-s-thompson-and-the-death-of-objectivity/#comments</comments>
		<pubDate>Mon, 20 Jul 2009 21:56:46 +0000</pubDate>
		<dc:creator>Adrian Mouat</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://www.adrianmouat.com/bit-bucket/?p=88</guid>
		<description><![CDATA[David Weinberger writes on &#8220;Joho the Blog&#8221; that &#8220;transparency is the new objectivity&#8220;. In the post, he explains how journalists have traditionally strived to appear objective, but today&#8217;s bloggers typically go down a different path and aim for transparency. That is to say, a journalist will not openly reveal their biases (which sometimes grow into [...]]]></description>
			<content:encoded><![CDATA[<p>David Weinberger writes on &#8220;Joho the Blog&#8221; that &#8220;<a href="http://www.hyperorg.com/blogger/2009/07/19/transparency-is-the-new-objectivity/">transparency is the new objectivity</a>&#8220;. In the post, he explains how journalists have traditionally strived to <em>appear</em> objective, but today&#8217;s bloggers typically go down a different path and aim for transparency. That is to say, a journalist will not openly reveal their biases (which sometimes grow into hidden agendas) but many bloggers will happily wear their allegiances on their sleeve.</p>
<p><img class="alignright" title="The Gonzo Fist" src="http://www.adrianmouat.com/bit-bucket/wp-content/uploads/2009/07/Gonzo-202x300.png" alt="The Gonzo Fist" width="162" height="240" /></p>
<p>It&#8217;s common knowledge that media outlets typically favour certain strains of politics over others, for example Fox News is famously Republican and were <a href="http://www.worldpublicopinion.org/pipa/articles/international_security_bt/102.php?nid=&amp;id=&amp;pnt=102">arguably responsible for perpetuating falsehoods about the Iraq war</a>. In the UK, the Daily Mail leans heavily towards the right and <a href="http://www.mailwatch.co.uk/tag/immigration/">publishes very questionable stuff about immigration</a>, whilst the Guardian leans towards the left (and at least attempts to confine its political rants to the editorials).</p>
<p>However, none of these outlets openly say this. The Guardian claims to live by the words <a href="http://www.guardian.co.uk/information/theguardian/story/0,,906788,00.html">&#8220;A newspaper&#8217;s primary office is the gathering of news. At the peril of its soul it must see that the supply is not tainted.&#8221;</a> I couldn&#8217;t find an equivalent statement on the Daily Mail&#8217;s website, but <a href="http://www.and.co.uk">AND</a>, their parent company (how much did that address cost?!), claims <a href="http://www.and.co.uk/">&#8220;Our mission is to be the most trusted and relevant focal point in every community we serve, ensuring the best outcomes for people when making the important decisions in their lives.&#8221;</a> (Although this arguably makes no claims to objectivity assuming it doesn&#8217;t affect their trust or relevance).</p>
<p>In contrast, the blogger Michelle Malkin openly declares <a href="http://michellemalkin.com/about/">her conserative allegiances</a> and there&#8217;s no doubting <a href="http://www.liberaloasis.com/">LiberalOasis</a>&#8217;s politics with the tag-line &#8220;where the Left is right and the Right is wrong&#8221;. For a British example, see <a href="http://iaindale.blogspot.com/">Iain Dale</a>, who actually stood as a conservative candidate and whose banner quotes are mildly amusing and sometimes reveal more about the person being quoted:</p>
<blockquote><p>&#8220;Political intelligence in every sense&#8221; &#8211; Roland White, The Sunday Times<br />
&#8220;Much wittier than your average Tory&#8221; &#8211; Lance Price, Former Labour Communications Director.<br />
&#8220;I read it every day&#8221; &#8211; Adam Boulton, Sky News</p></blockquote>
<p>The thing is, none of this is exactly new. Hunter S. Thompson pioneered Gonzo journalism which Wikipedia <a href="http://en.wikipedia.org/wiki/Gonzo_journalism">currently defines</a> as &#8220;a style of journalism which is written subjectively, often including the reporter as part of the story&#8221;. Sound familiar? Throughout Thompson&#8217;s writing, he was often part of the story, as much making the news as writing about it (he didn&#8217;t go to the library to write <a href="http://www.amazon.co.uk/Hells-Angels-Penguin-Modern-Classics/dp/014118745X/ref=sr_1_1?ie=UTF8&amp;s=books&amp;qid=1248126137&amp;sr=8-1">his book on the Hell&#8217;s Angels</a> &#8211; he spent a year living with them). Hunter managed to write a pretty definitive <a href="http://www.amazon.co.uk/Loathing-Campaign-Harper-Perennial-Classics/dp/0007204485/ref=pd_sim_b_3">account of the 1972 presidential race,</a> which reads with a refreshing honesty despite containing completely fictional elements (such as alleging Ed Muskie was addicted to the drug Abogaine and his advisers had flown in a Brazilian doctor to treat him, but how the hell did anyone not realise he was extracting the proverbial urine there?). My point being that Hunter forsook objectivity, yet still managed to deliver in authoritativeness through his &#8220;transparency&#8221; &#8211; there was never any doubt where Hunter&#8217;s allegiances lay. According to Wikipedia, Thompson said in an interview &#8220;Objective journalism is one of the main reasons American politics has been allowed to be so corrupt for so long. You can&#8217;t be objective about Nixon.&#8221; Of course, I&#8217;m not saying all bloggers can or should write with the vitriol of Thompson, but they should aim to be open about to which side they lean and how they came to be in possession of the facts &#8211; this way people know to check the opposing argument for themselves.</p>
<p>Weinberger is right &#8211; only with transparency can we ever hope to arrive somewhere close to the ever unobtainable &#8220;objective truth&#8221;.</p>
<p><strong>Update:<br />
</strong><br />
A <a href="http://news.ycombinator.com/item?id=716979">commenter on Hacker News</a> pointed out that blogs are normally more analagous to editorials than news stories, and editorials are usually clear in their political bias.</p>
<p>I would still argue that for a newspaper to claim objectivity they should attempt much greater transparency. Some papers now allow comments on stories, which is good move in this direction (but who stops them deleting comments they disagree with?).</p>
]]></content:encoded>
			<wfw:commentRss>http://www.adrianmouat.com/bit-bucket/2009/07/hunter-s-thompson-and-the-death-of-objectivity/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>Where the Cloud meets the Grid</title>
		<link>http://www.adrianmouat.com/bit-bucket/2009/06/where-the-cloud-meets-the-grid/</link>
		<comments>http://www.adrianmouat.com/bit-bucket/2009/06/where-the-cloud-meets-the-grid/#comments</comments>
		<pubDate>Sun, 14 Jun 2009 10:08:16 +0000</pubDate>
		<dc:creator>Adrian Mouat</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://www.adrianmouat.com/bit-bucket/?p=82</guid>
		<description><![CDATA[The GridVoices blog on Gridipedia has just moved to a WordPress installation. Back in April, I wrote this article for them, which looks at the similarities and differences between Grid and Cloud computing.
]]></description>
			<content:encoded><![CDATA[<p>The <a href="http://www.gridipedia.eu/grid_voices">GridVoices blog</a> on <a href="http://www.gridipedia.eu">Gridipedia</a> has just moved to a WordPress installation. Back in April, I wrote <a href="http://www.gridipedia.eu/grid_voices/?p=18">this article</a> for them, which looks at the similarities and differences between Grid and Cloud computing.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.adrianmouat.com/bit-bucket/2009/06/where-the-cloud-meets-the-grid/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Running JUnit from Vim</title>
		<link>http://www.adrianmouat.com/bit-bucket/2009/06/running-junit-from-vim/</link>
		<comments>http://www.adrianmouat.com/bit-bucket/2009/06/running-junit-from-vim/#comments</comments>
		<pubDate>Mon, 01 Jun 2009 21:21:17 +0000</pubDate>
		<dc:creator>Adrian Mouat</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://www.adrianmouat.com/bit-bucket/?p=56</guid>
		<description><![CDATA[Normally when I&#8217;m programming in Java I&#8217;ll use Eclipse. However, in some cases Eclipse can be a bit heavyweight and I&#8217;ll fallback on Vim. The last time I did this I started to miss the ability to quickly and easily run unit tests on a per class basis. For this reason, I added the following [...]]]></description>
			<content:encoded><![CDATA[<p>Normally when I&#8217;m programming in Java I&#8217;ll use Eclipse. However, in some cases Eclipse can be a bit heavyweight and I&#8217;ll fallback on Vim. The last time I did this I started to miss the ability to quickly and easily run unit tests on a per class basis. For this reason, I added the following function to my .vimrc which runs the appropriate test class for the current Java class.</p>
<blockquote>
<pre>function RunTest()

    let cla = matchstr(expand("%:p"), '^.*[/\\]src[/\\]\(test\|java\)[/\\]\zs.*')
    "still need to replace /s with .s
    let class = "java org.junit.runner.JUnitCore " .  strpart(substitute(cla, "/", "\.", "g"), 0, strlen(cla) -5)

    if match(class, "Test") == -1
        let class = class . "Test"
    endif

    echo class
    echo system(class)
endfunction

map &lt;F6&gt; &lt;Esc&gt;:echo RunTest()&lt;CR&gt;</pre>
</blockquote>
<p>The code assumes that your test directory structure mimics your source directory structure and all the names of your test classes are the same as the source classes with &#8220;Test&#8221; appended e.g. if you are editing &#8220;src/mypackage/MyClass.java&#8221;, it will attempt to run &#8220;test/mypackage/MyClassTest&#8221;. (If you are currently editing a test class, it should run that class).</p>
<p>I also mapped F6 as a shortcut to the function.</p>
<p>I really don&#8217;t know Vim script TK at all, so I&#8217;m sure the code could be a lot cleaner. Still, it was a big help for me, and I now find it quicker to run the correct test in Vim than Eclipse.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.adrianmouat.com/bit-bucket/2009/06/running-junit-from-vim/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Why use diffxml?</title>
		<link>http://www.adrianmouat.com/bit-bucket/2009/05/why-use-diffxml/</link>
		<comments>http://www.adrianmouat.com/bit-bucket/2009/05/why-use-diffxml/#comments</comments>
		<pubDate>Tue, 19 May 2009 20:19:53 +0000</pubDate>
		<dc:creator>Adrian Mouat</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[diffxml]]></category>

		<guid isPermaLink="false">http://www.adrianmouat.com/bit-bucket/?p=15</guid>
		<description><![CDATA[I&#8217;m the author of the diffxml tool for comparing XML documents. In this post I&#8217;d like to explain why you might want to use diffxml to compare XML documents rather than traditional text tools such as the UNIX diff command.
There are two things that diffxml understands that diff doesn&#8217;t; the syntax of XML documents (e.g. [...]]]></description>
			<content:encoded><![CDATA[<p>I&#8217;m the author of the <a href="http://diffxml.sf.net">diffxml</a> tool for comparing XML documents. In this post I&#8217;d like to explain why you might want to use diffxml to compare XML documents rather than traditional text tools such as the UNIX diff command.</p>
<p>There are two things that diffxml understands that diff doesn&#8217;t; the syntax of XML documents (e.g. &lt;br/&gt; is equivalent to &lt;br&gt;&lt;/br&gt;) and the hierarchical structure they represent.<span id="more-15"></span></p>
<p>The advantages of understanding XML syntax are pretty easy to explain. Consider these two XML documents:</p>
<blockquote><p><code>&lt;a<br />
&gt;text&lt;b/&gt;<br />
&lt;c&gt;&lt;/c&gt;<br />
&lt;/a&gt;</code></p></blockquote>
<p>and</p>
<blockquote><p><code>&lt;a&gt;text&lt;b&gt;&lt;/b&gt;<br />
&lt;d/&gt;<br />
&lt;/a&gt;</code></p></blockquote>
<p>If we compare these using diff, we get the following output:</p>
<blockquote><p><code>1,3c1,2<br />
&lt; &lt;a<br />
&lt;     &gt;text&lt;b/&gt;<br />
&lt; &lt;c&gt;&lt;/c&gt;</code></p></blockquote>
<p>Which is telling us that every line in the document has changed. However, if we use diffxml to difference the documents, we get:</p>
<blockquote><p><code>&lt;?xml version="1.0" encoding="UTF-8" standalone="no"?&gt;<br />
&lt;delta&gt;<br />
&lt;insert charpos="2" childno="4" name="d" nodetype="1" parent="/node()[1]"/&gt;<br />
&lt;delete node="/node()[1]/node()[5]"/&gt;<br />
&lt;/delta&gt;</code></p></blockquote>
<p>Which is telling us that the difference between the documents is the insertion of an element &#8220;d&#8221; and the removal of another element<sup>1</sup>.</p>
<p>The other major advantage of diffxml is that it understands the hierarchical, or &#8220;tree&#8221; structure of XML documents. It&#8217;s a little harder to explain what this means, but consider the following. The XML document:</p>
<blockquote><p><code>&lt;a&gt;&lt;b&gt;&lt;d/&gt;&lt;/b&gt;&lt;c&gt;&lt;e/&gt;&lt;/c&gt;&lt;/a&gt;</code></p></blockquote>
<p>Can be represented as:</p>
<p><img class="size-medium wp-image-33 alignnone" title="Tree representation of XML" src="http://www.adrianmouat.com/bit-bucket/wp-content/uploads/2009/05/tree1.png" alt="Tree representation of XML" width="79" height="102" /></p>
<p>And the XML document:</p>
<blockquote><p><code>&lt;a&gt;&lt;b/&gt;&lt;c&gt;&lt;d/&gt;&lt;e/&gt;&lt;/c&gt;&lt;/a&gt;</code></p></blockquote>
<p>Can be represented as:</p>
<p><img class="size-full wp-image-41 alignnone" title="Tree representation of XML document" src="http://www.adrianmouat.com/bit-bucket/wp-content/uploads/2009/05/tree2.png" alt="Tree representation of XML document" width="98" height="100" /></p>
<p>It&#8217;s clear from the diagram that the only change is that the element &#8220;d&#8221; has moved from element &#8220;b&#8221; to element &#8220;c&#8221;. There is no way that a line-based differencing utility could tell us this, but diffxml gives us:</p>
<blockquote><p><code>&lt;?xml version="1.0" encoding="UTF-8" standalone="no"?&gt;<br />
&lt;delta&gt;<br />
&lt;move childno="1" new_charpos="1" node="/node()[1]/node()[1]/node()[1]" old_charpos="1" parent="/node()[1]/node()[2]"/&gt;<br />
&lt;/delta&gt;</code></p></blockquote>
<p>Which correctly identifies that the only difference is the move of a single element to a new parent.</p>
<p>I hope this makes it clear why tools such as diffxml which understand the heirarchical narture of XML documents are often a better choice than line-based equivalents for comparing XML documents.</p>
<ol class="footnotes"><li id="footnote_0_15" class="footnote">Admittedly the output is a little hard for humans to read currently. There are a couple of things that can be done to improve this (use proper node names instead of using the node() axis and put a string in the nodetype attribute), but in the future I hope to provide some sort of graphical interface.</li></ol>]]></content:encoded>
			<wfw:commentRss>http://www.adrianmouat.com/bit-bucket/2009/05/why-use-diffxml/feed/</wfw:commentRss>
		<slash:comments>7</slash:comments>
		</item>
		<item>
		<title>Welcome</title>
		<link>http://www.adrianmouat.com/bit-bucket/2009/05/welcome/</link>
		<comments>http://www.adrianmouat.com/bit-bucket/2009/05/welcome/#comments</comments>
		<pubDate>Sat, 02 May 2009 15:29:06 +0000</pubDate>
		<dc:creator>Adrian Mouat</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[computer science]]></category>
		<category><![CDATA[writing]]></category>

		<guid isPermaLink="false">http://www.adrianmouat.com/bit-bucket/?p=3</guid>
		<description><![CDATA[I nearly called this blog "Tergiversations", after an essay by Richard Gabriel in his book "Patterns of Software". It's a very important book to me. I found the book in a bargain bin in the academic bookstore on my university campus at the end of my first year. At this time I was considering if Computer Science was the correct choice of course for me, or if I should do something completely different, perhaps in Arts &#038; Humanities.]]></description>
			<content:encoded><![CDATA[<blockquote><p>Tergiversations. It&#8217;s a real word: tergiversate means &#8216;to change repeatedly one’s attitude or opinions with respect to a subject or cause.&#8217;</p>
<p>Richard Gabriel, &#8220;Patterns of Software&#8221;.</p></blockquote>
<p>I nearly called this blog &#8220;Tergiversations&#8221;, after an essay by <a href="http://www.dreamsongs.com/">Richard Gabriel</a> in his book &#8220;<a href="http://www.dreamsongs.com/Files/PatternsOfSoftware.pdf">Patterns of Software</a>&#8220;. It&#8217;s a very important book to me. I found the book in a bargain bin in the academic bookstore on my university campus at the end of my first year. At this time I was considering if Computer Science was the correct choice of course for me, or if I should do something completely different, perhaps in Arts &amp; Humanities.</p>
<p>Gabriel&#8217;s book affirmed my course choice. In it, I saw someone who clearly loved his subject matter and was capable of deep insight into it. There was no doubt that Computer Science contained serious challenges and was worthy of anyone&#8217;s attention. More than this, I saw there was a very subjective side to the field, and that people&#8217;s imaginations – even their force of character – were of vital importance (of course, now I realise that this is probably true of most scientific subjects, but it was a revelation to me then).</p>
<p>The book itself is a series of essays, its title coming from an essay exploring how the ideas in Christopher Alexander&#8217;s books &#8220;The Timeless Way of Building&#8221; and &#8220;A Pattern Language&#8221; apply to software. It also contains essays on writing, programming languages and some more personal stuff. All are worth reading.</p>
<p>I wanted to call the blog &#8220;Tergiversations&#8221; to show that I was willing to listen to others and change my viewpoints accordingly. For me, one of the most striking differences between science and other disciplines is a willingness to concede, to accept that someone else&#8217;s theory is correct and yours isn&#8217;t. Of course, this largely occurs because many things in science can be objectively proven; you can&#8217;t argue about the existence of a <a href="http://en.wikipedia.org/wiki/Black_swan_theory">black swan</a>. At least in science, objective progress can be made, in artistic or political endeavour any progress tends to be subjective. I could argue all day against the BNP, but I couldn&#8217;t prove beyond doubt that their beliefs are misguided and immoral. However, I can easily prove that my Java code runs twice as fast as yours. (Interestingly, I recently read an <a href="http://arstechnica.com/articles/culture/conservapedias-evolutionary-foibles.ars">article</a> where these two worlds collided, and I&#8217;m just glad I don&#8217;t have to deal with Andy Schlafly)</p>
<p>In the end, I didn&#8217;t name the blog &#8220;Tergiversations&#8221;; it has the negative connotations of being evasive and desertion, whereas all I wanted to indicate was a willingness to change one&#8217;s mind and to try new methods (I&#8217;m sure Richard is well aware of this; I failed to remember the precise definition and the context he used it in until I re-read the essay).</p>
<p>To sum up; many thanks to Richard Gabriel for writing &#8220;Patterns of Software&#8221;, and welcome to &#8220;Feeding the Bit-Bucket&#8221;<sup>1</sup>.</p>
<ol class="footnotes"><li id="footnote_0_3" class="footnote">Yes, I know this captures none of the meaning I talked about. However, it does capture the likely end product of this blog, and some of the eternal aspect of writing.</li></ol>]]></content:encoded>
			<wfw:commentRss>http://www.adrianmouat.com/bit-bucket/2009/05/welcome/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
