<?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>Ledona Tech</title>
	<atom:link href="http://blog.ledona.net/techblog/feed/" rel="self" type="application/rss+xml" />
	<link>http://blog.ledona.net/techblog</link>
	<description>Snips of code and random other stuff that I regularly forget or that others might find useful.</description>
	<lastBuildDate>Thu, 17 Mar 2011 19:15:39 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.2.1</generator>
		<item>
		<title>Permutation test</title>
		<link>http://blog.ledona.net/techblog/2010/11/20/permutation-test/</link>
		<comments>http://blog.ledona.net/techblog/2010/11/20/permutation-test/#comments</comments>
		<pubDate>Sat, 20 Nov 2010 20:09:20 +0000</pubDate>
		<dc:creator>ledona</dc:creator>
				<category><![CDATA[php]]></category>
		<category><![CDATA[research]]></category>

		<guid isPermaLink="false">http://blog.ledona.net/techblog/?p=61</guid>
		<description><![CDATA[A php implementation of the permutation test for significance.]]></description>
			<content:encoded><![CDATA[<p>While working on my thesis I needed to calculate the statistical significance of differences in performance between a couple classifiers and information retrieval methods that I was comparing.  One of the limitations I was working under were that the size of my gold standard was very limited (~100 items), so running multiple resampled tests and using t-test or something similar didn&#8217;t seem like a viable option.  I came across the following papers describing the use of the Permutation test:</p>
<p style="padding-left: 30px;">Mark D. Smucker, James Allan, and Ben Carterette. 2007. A comparison of statistical significance tests for information retrieval evaluation. In <em>Proceedings of the sixteenth ACM conference on Conference on information and knowledge management</em> (CIKM &#8217;07). ACM, New York, NY, USA, 623-632. DOI=10.1145/1321440.1321528 <a href="http://doi.acm.org/10.1145/1321440.1321528">http://doi.acm.org/10.1145/1321440.1321528</a></p>
<p style="padding-left: 30px;">Alexander Yeh. 2000. More accurate tests for the statistical significance of result differences. In<em>Proceedings of the 18th conference on Computational linguistics &#8211; Volume 2</em>, Vol. 2. Association for Computational Linguistics, Morristown, NJ, USA, 947-953. DOI=10.3115/992730.992783 <a href="http://dx.doi.org/10.3115/992730.992783">http://dx.doi.org/10.3115/992730.992783</a></p>
<p>The method seemed like exactly what I was looking for, unfortunately I could not find an implementation that was easily assessable and usable.  So I rolled my own.  If you find this useful please let me know.  More importantly, let me know if you find any errors, or if you have any suggestions.</p>
<p>You can download the code at: <a href="http://blog.ledona.net/RandomPermutation.php.txt">RandomPermutation.php</a></p>
]]></content:encoded>
			<wfw:commentRss>http://blog.ledona.net/techblog/2010/11/20/permutation-test/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Getting the Westell Proline 6100 out of the way</title>
		<link>http://blog.ledona.net/techblog/2010/04/30/getting-the-westell-proline-6100-out-of-the-way/</link>
		<comments>http://blog.ledona.net/techblog/2010/04/30/getting-the-westell-proline-6100-out-of-the-way/#comments</comments>
		<pubDate>Fri, 30 Apr 2010 17:29:29 +0000</pubDate>
		<dc:creator>ledona</dc:creator>
				<category><![CDATA[networking]]></category>

		<guid isPermaLink="false">http://blog.ledona.net/techblog/?p=58</guid>
		<description><![CDATA[I just got DSL service via Verizon in NYC.  The DSL modem they sent me, Westell Proline 6100, acts as a gateway to the internet as well as a router (performing tasks like firewall, DHCP, port forwarding, etc&#8230;).  A little experimenting revealed that it doesn&#8217;t perform most of its routing tasks well, and some things, [...]]]></description>
			<content:encoded><![CDATA[<p>I just got DSL service via Verizon in NYC.  The DSL modem they sent me, Westell Proline 6100, acts as a gateway to the internet as well as a router (performing tasks like firewall, DHCP, port forwarding, etc&#8230;).  A little experimenting revealed that it doesn&#8217;t perform most of its routing tasks well, and some things, like dynamic DNS, just don&#8217;t work at all.</p>
<p>I already have a wifi router that does all these things well. So my task was to set up the Westell modem so that it passes off all duties (other than connecting to Verizon) to my router.</p>
<p>I played around with some of the modem settings to no avail.  I googled and found a posting saying that a similar Westell modem model, with similar problems, could be set to &#8220;bridge mode&#8221;.  While in that mode it should pass all duties to whatever internet device it is connected to.  This too did not work for me.  Verizon technical support was useless (no one I spoke to even knew what dynamic DNS is).</p>
<p>Finally, out of desperation, I meticulously went through all of the Westell&#8217;s configuration options.  One setting did the trick.  It has an option to set up a connected device as a DMZ host.  Luckily all external connection requests get passed to that device AND that device is assigned the external IP address.  In my case that is everything I needed.</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.ledona.net/techblog/2010/04/30/getting-the-westell-proline-6100-out-of-the-way/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Audio File Metadata Tools (Mp3tag, Picard, GimmeSomeTunes, iTunes)</title>
		<link>http://blog.ledona.net/techblog/2010/04/02/audio-file-metadata-tools/</link>
		<comments>http://blog.ledona.net/techblog/2010/04/02/audio-file-metadata-tools/#comments</comments>
		<pubDate>Fri, 02 Apr 2010 20:04:58 +0000</pubDate>
		<dc:creator>ledona</dc:creator>
				<category><![CDATA[iTunes]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[microsoft]]></category>
		<category><![CDATA[music]]></category>
		<category><![CDATA[ubuntu]]></category>

		<guid isPermaLink="false">http://blog.ledona.net/techblog/?p=51</guid>
		<description><![CDATA[For almost a year now I&#8217;ve been working on re-ripping all my CDs to lossless audio files (FLAC) and simultaneously creating high quality VBR mp3s.  For my ripping I&#8217;ve used what I believe are the best 3 rippers available; X Lossless Decoder (OSX), Rubyripper (Linux/Ubuntu), and Exact Audio Copy (Windows). Problem That task done, the [...]]]></description>
			<content:encoded><![CDATA[<p>For almost a year now I&#8217;ve been working on re-ripping all my CDs to lossless audio files (FLAC) and simultaneously creating high quality VBR mp3s.  For my ripping I&#8217;ve used what I believe are the best 3 rippers available; <a href="http://tmkk.hp.infoseek.co.jp/xld/index_e.html" target="_blank">X Lossless Decoder</a> (OSX), <a href="http://code.google.com/p/rubyripper/" target="_blank">Rubyripper</a> (Linux/Ubuntu), and <a href="http://www.exactaudiocopy.de/" target="_blank">Exact Audio Copy</a> (Windows).</p>
<h1>Problem</h1>
<p>That task done, the next task is the ensure consistent metadata across my entire music collection. The rippers I just mentioned all support pulling metadata down from multiple online databases, but as anyone as anal as I am about their metadata knows, automatically populated audio metadata is often incorrect and never consistent.  For example, is the artist field in classical music for composer or performer?  Do you prefer hip-hop, rap, or r&amp;b?  Do you want to use Rock &amp; Roll or RockNRoll or Rock and Roll.  And just cause you know they are all the same does not mean that iTunes (or whatever you use) does.</p>
<p>So, to fix audio metadata I resort to using the following tools depending on the task; iTunes + <a href="http://www.eternalstorms.at/gimmesometune/GimmeSomeTune" target="_blank">GimmeSomeTune</a>, <a href="http://musicbrainz.org/doc/MusicBrainz_Picard" target="_blank">PicardTagger</a> and <a href="http://www.mp3tag.de/en/" target="_blank">Mp3tag</a>.</p>
<h1>Solution 1: iTunes + GimmeSomeTune</h1>
<p><a href="http://www.apple.com/itunes"><img class="alignright" style="margin: 10px;" title="iTunes" src="http://www.differentdistrict.com/images/uploads/itunes.png" alt="iTunes" width="100" height="100" /></a></p>
<p>I use iTunes to play my music and to sync with my iPhone and iPod, so its to be expected that I do some of my music tagging work in iTunes.  If it is a simple, manual task like renaming a couple tracks names, modifying an album title or artist, etc&#8230; Then I just use the tag editing functions built into iTunes.  This also works fine for manually adding album art.</p>
<p><a href="http://www.eternalstorms.at/gimmesometune/GimmeSomeTune"><img class="alignleft" style="margin: 10px;" title="GimmeSomeTune" src="http://www.eternalstorms.at/gimmesometune/GimmeSomeTune/GimmeSomeTune_files/droppedImage_1.png" alt="" width="128" height="128" /></a></p>
<p>GimmeSomeTune is a nice little iTunes plug in that automagically adds metadata to tracks that iTunes plays.  I have mine configured to add lyrics and album art if they are missing.  I would estimate that this works around 75% of the time.  The other 25% is a mixture of GimmeSomeTunes not finding the lyrics or album art for my music and finding the wrong lyrics or art.  In the later case I manually go in and fix the error or resort to using one of the two following applications.</p>
<p><em>One thing to note is that the GimmeSomeTune website says that the app is being rewritten from the ground up.</em></p>
<h1>Solution 2: PicardTagger</h1>
<h2><a href="http://musicbrainz.org"><img class="aligncenter" title="Musicbrainz Picard" src="http://musicbrainz.org/images/header_logo_a.gif" alt="" width="614" height="67" /></a></h2>
<p>PicardTagger is nice because it works onall platforms and it can try  and discover what a track is based solely on the music file (sorta like  how <a href="http://www.shazam.com/" target="_blank">shazam</a>).  It can also use whatever metadata is  already in a track (album name, artist, track number, track name) and  search for the rest of the data.  The problem with Picard is that it  only works against the <a href="http://musicbrainz.org/" target="_blank">MusicBrainz</a> database, which does not always have  what you want, or may not be able to find your music because of the way  that the database is set up for searching.</p>
<p>Another bonus is that PicardTagger has a build for all platforms.</p>
<h1>Solution 3:Mp3tag</h1>
<h1><a href="http://www.mp3tag.de/en/"><img class="alignnone" style="margin: 10px;" title="Mp3tag" src="http://www.mp3tag.de/images/logo4.gif" alt="" width="252" height="68" /></a></h1>
<p>This is (for me) the big dog.  The best music tagger I&#8217;ve seen. Some notable features that I have use are:</p>
<ul>
<li> It searches multiple music dat abases (Amazon, discogs, musicbranz and others),</li>
<li>it supports every audio format I can think of, it automatically downloads music art,</li>
<li>it supports all tag types, it can export and import music data from text and html,</li>
<li>it can be used to infer metadata from filenames or rename files based on metadata,</li>
<li>text editing and replacement features</li>
</ul>
<p>And all these functions can be be run in batch over subsets or your music collection or over the whole thing.  Basically, if Mp3tag doesn&#8217;t do it, its time to start writing code.</p>
<p>The one drawback is that Mp3tag only has a windows version.</p>
<h1>One last thing</h1>
<p>Using either Picard or Mp3tag would not work if iTunes didn&#8217;t scan audio files for changes.  Thankfully it does. Right before playing a file iTunes checks if it has been modified, if so it reads the files metadata and updates the iTunes music database.  Apple, please never take this away!</p>
<p>Happy Tagging&#8230;</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.ledona.net/techblog/2010/04/02/audio-file-metadata-tools/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>CLI Converting YouTube video to audio/mp3s</title>
		<link>http://blog.ledona.net/techblog/2010/03/23/cli-converting-youtube-video-to-audiomp3s/</link>
		<comments>http://blog.ledona.net/techblog/2010/03/23/cli-converting-youtube-video-to-audiomp3s/#comments</comments>
		<pubDate>Tue, 23 Mar 2010 19:24:07 +0000</pubDate>
		<dc:creator>ledona</dc:creator>
				<category><![CDATA[apple]]></category>
		<category><![CDATA[bash]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[ubuntu]]></category>

		<guid isPermaLink="false">http://blog.ledona.net/techblog/?p=37</guid>
		<description><![CDATA[Problem: I recently (like yesterday) wanted to convert some YouTube videos to audio tracks that I could listen to on my iPod.  A quick google search gives tons of possible solutions, some like vixy.net take a URL and convert it in the cloud and give you a link for download.  This would work fine if [...]]]></description>
			<content:encoded><![CDATA[<h1><img class="alignright" src="/techblog/images/youtube2mp3.png" alt="" width="212" height="444" />Problem:</h1>
<p>I recently (like yesterday) wanted to convert some YouTube videos to audio tracks that I could listen to on my iPod.  A quick google search gives tons of possible solutions, some like vixy.net take a URL and convert it in the cloud and give you a link for download.  This would work fine if I had only a couple videos and they were kinda short.  However I wanted to convert a bunch of videos each of which were over an hour in length.  So I decided to search for a command-line solution so I could write a shell script to do the conversions.</p>
<h1>Solution:</h1>
<p>So, basically I needed to download the YouTube video, and then convert that video to mp3.  For the first step there is a script called <strong><a title="youtube-dl" href="http://bitbucket.org/rg3/youtube-dl/wiki/Home" target="_blank">youtube-dl</a></strong>.  It downloads YouTube videos and saves them as flash video files.  It works PERFECTLY.  For converting flash video files to mp3s I used <span style="color: #888888;"><strong><a title="FFMPEG" href="http://ffmpeg.org/" target="_blank">ffmpeg</a></strong></span>.  Again, it works PERFECTLY!</p>
<p>I did my Youtube downloading on Ubuntu where there is a youtube-dl package, and I did my ffmpeg audio converting on a mac where there is a macports package available.  But both tools are cross platform and should work on whatever you have.</p>
<h1>Usage:</h1>
<p>Once both tools are installed, the following is all you need to do to first download from youtube and then convert to mp3.  Lets say the link to the youtube video is <em>http://www.youtube.com/watch?v=aFIPeFvPICs</em> , and you want an mp3 file named <em>audio.mp3</em> .  All you need do is on your command line (or in your shell script) run the following:</p>
<p><strong>&gt; youtube-dl -o video.flv http://www.youtube.com/watch?v=aFIPeFvPICs<em><br />
</em>&gt; ffmpeg -i video.flv -ar 44100 audio.mp3</strong></p>
<p>Both tools have a bunch of options.  The only additional options that I had to use were to include a username and password for Youtube because they were required to download the video I wanted.  In that case you run youtube-dl as follows:</p>
<p><strong>&gt; youtube-dl -u USERNAME -p PASSWORD -o video.flv http://www.youtube.com/watch?v=aFIPeFvPICs</strong><em><br />
</em></p>
]]></content:encoded>
			<wfw:commentRss>http://blog.ledona.net/techblog/2010/03/23/cli-converting-youtube-video-to-audiomp3s/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Converting a cygwin/bash path to a windows dos path</title>
		<link>http://blog.ledona.net/techblog/2009/11/06/converting-a-cygwinbash-path-to-a-windows-dos-path/</link>
		<comments>http://blog.ledona.net/techblog/2009/11/06/converting-a-cygwinbash-path-to-a-windows-dos-path/#comments</comments>
		<pubDate>Fri, 06 Nov 2009 22:33:20 +0000</pubDate>
		<dc:creator>ledona</dc:creator>
				<category><![CDATA[bash]]></category>
		<category><![CDATA[code]]></category>
		<category><![CDATA[cygwin]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[microsoft]]></category>

		<guid isPermaLink="false">http://blog.ledona.net/techblog/?p=31</guid>
		<description><![CDATA[I have a bash script that calls a java application. Originally this script and java app were only run on a linux machine. Then for a couple good reasons I needed to run it in windows under cygwin. I already had java installed under windows, so I needed to get the bash script running under [...]]]></description>
			<content:encoded><![CDATA[<p>I have a bash script that calls a java application.  Originally this script and java app were only run on a linux machine.  Then for a couple good reasons I needed to run it in windows under cygwin.  I already had java installed under windows, so I needed to get the bash script running under cygwin to run the java app.  The problem is that java is expecting a windows classpath (e.g. c:\path\to\whatever;d:\another\path) as opposed to a POSIX/cygwin classpath (e.g. /cygdrive/c/path/to/whatever:/cygdrive/d/another/path).  In addition to the path seperaters and the direction of the slash is the complication of converting symbolic links.</p>
<p>After some digging and testing here is what I came up with.  I&#8217;m sure there are numerous other (possibly simpler) ways of getting this done, but this works just fine.  Admittedly not a common problem, but hopefully useful to someone.</p>
<hr />
<pre># save the old splitting char
SaveIFS=$IFS
# set the splitting char to linux split
IFS=":"
# split the classpath
declare -a SPLITPATH=($CLASSPATH)
# restore IFS
IFS=$SaveIFS
# iterate through the path elements
for (( i = 0 ; i &lt; ${#SPLITPATH[@]} ; i++ ))
do
   # get rid of symbolic links
   new_single=`readlink -f "${SPLITPATH[i]}"`
   # convert from cygwin paths to windows paths
   new_single=`cygpath -w "$new_single"`
   # append to the new path
   new_path=$new_path";"$new_single
done
export CLASSPATH=$new_path</pre>
]]></content:encoded>
			<wfw:commentRss>http://blog.ledona.net/techblog/2009/11/06/converting-a-cygwinbash-path-to-a-windows-dos-path/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Quick &amp; Dirty CSV CLI Text Viewer</title>
		<link>http://blog.ledona.net/techblog/2009/10/21/quick-dirty-csv-cli-text-viewer/</link>
		<comments>http://blog.ledona.net/techblog/2009/10/21/quick-dirty-csv-cli-text-viewer/#comments</comments>
		<pubDate>Wed, 21 Oct 2009 22:59:03 +0000</pubDate>
		<dc:creator>ledona</dc:creator>
				<category><![CDATA[linux]]></category>
		<category><![CDATA[php]]></category>

		<guid isPermaLink="false">http://blog.ledona.net/techblog/?p=25</guid>
		<description><![CDATA[A project I&#8217;m currently working on has me repeatedly looking at csv text files.  When the columns line up well I can simply cat or less the data on a linux command line.  But when the data does not line up I have to eyeball it and try and figure out what value goes to [...]]]></description>
			<content:encoded><![CDATA[<p>A project I&#8217;m currently working on has me repeatedly looking at csv text files.  When the columns line up well I can simply <strong><em>cat</em></strong> or <strong><em>less</em></strong> the data on a linux command line.  But when the data does not line up I have to eyeball it and try and figure out what value goes to what column.  Very frustrating.  A quick search on google did not return anything that would give me a quick and dirty command-line csv text viewer that would align the columns.  So I threw one together in PHP.  Hope this helps someone out there.</p>
<hr />
<pre>&lt;?php
	// A quick dirty CSV viewer

	$USAGE = "USAGE: csvfilename [ column_width ]";
	if ($argc &lt; 2) {
		echo $USAGE . "\n";
		exit(1);
	}

	$csvFilename = $argv[1];
	$colWidth = ($argc == 3) ? $argv[2] - 1 : 5;

	$lines = file($csvFilename);
	foreach($lines as $line) {
		$cols = explode(",", $line);
		$newCols = array();
		foreach($cols as $col) {
			$col = trim($col);
			if (strlen($col) &gt; $colWidth) {
				// trim the column
				$col = substr( $col, 0, $colWidth);
			}

			if (strlen($col) &lt; $colWidth) {
				// pad the col
				$col = str_pad($col, $colWidth, " ", STR_PAD_LEFT);
			}

			$newCols[] = $col;
		}

		echo implode($newCols, ", ") . "\n";
	}
?&gt;</pre>
]]></content:encoded>
			<wfw:commentRss>http://blog.ledona.net/techblog/2009/10/21/quick-dirty-csv-cli-text-viewer/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Digital Music Metadata &#8211; GimmeSomeTune</title>
		<link>http://blog.ledona.net/techblog/2009/03/30/digital-music-metadata-gimmesometune/</link>
		<comments>http://blog.ledona.net/techblog/2009/03/30/digital-music-metadata-gimmesometune/#comments</comments>
		<pubDate>Mon, 30 Mar 2009 21:28:01 +0000</pubDate>
		<dc:creator>ledona</dc:creator>
				<category><![CDATA[iTunes]]></category>
		<category><![CDATA[music]]></category>

		<guid isPermaLink="false">http://blog.ledona.net/techblog/?p=22</guid>
		<description><![CDATA[My new music collection maintenance recommendation is GimmeSomeTune .  For what it does it works very well.  GimmeSomeTune runs in the background and monitors the music currently playing in iTunes.  When a new track is played it can check to if the track has lyrics and/or artwork associated to it in iTunes.  If it does [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.eternalstorms.at/gimmesometune/"><img class="alignleft" title="GimmeSomeTune" src="http://www.eternalstorms.at/gimmesometune/files/blocks_image_0_1.png" alt="" width="89" height="89" /></a></p>
<p>My new music collection maintenance recommendation is <a href="http://www.eternalstorms.at/gimmesometune/">GimmeSomeTune</a> .  For what it does it works very well.  <a href="http://www.eternalstorms.at/gimmesometune/">GimmeSomeTune</a> runs in the background and monitors the music currently playing in iTunes.  When a new track is played it can check to if the track has lyrics and/or artwork associated to it in iTunes.  If it does not it can automatically pull down lyrics and artwork and add it to the track.  In the case of artwork it appears to apply whatever it finds to all tracks of the album that playing track is part of.  I&#8217;m not sure where its getting artwork or lyrics, but it works pretty well on more popular stuff, while (not surprisingly) it is less accurate on more obscure stuff.  The artwork and lyrics are typically of pretty good quality. Added bonus is that it is &#8220;donationware&#8221; (i.e. free to use, donate what you wish).</p>
<p>It can do other things like integrate with LastFM, and act as a mini controller for iTunes, but while those functions seem to work ok, the thing that makes <a href="http://www.eternalstorms.at/gimmesometune/">GimmeSomeTune</a> special is the automatic lyric and coverart updating.</p>
<p>Only problems I&#8217;ve encountered are that the current version does not have a function that allows you to scan and update a bunch of tracks at once.  There are a couple ways around this.  I will likely write an applescript that plays the first couple seconds of all tracks that I want automatically updated, that should give <a href="http://www.eternalstorms.at/gimmesometune/">GimmeSomeTune</a> the opportunity to update what it can.  The second (more troubling) problem is that for anything that <a href="http://www.eternalstorms.at/gimmesometune/">GimmeSomeTune</a> gets wrong, it will consistently get it wrong.  So if it uses the wrong coverart or lyrics for a track, and you go in and remove the bad info, the next time you play that track <a href="http://www.eternalstorms.at/gimmesometune/">GimmeSomeTune</a> will again add the same incorrect info (unless presumably the source that it is getting its information from with better metadata).  The only way around this seems to be using a placeholder for artwork or lyrics so <a href="http://www.eternalstorms.at/gimmesometune/">GimmeSomeTune</a> will leave the track alone.</p>
<p>Anyways, I&#8217;m still on the lookout for something better, so let me know if you know of anything.</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.ledona.net/techblog/2009/03/30/digital-music-metadata-gimmesometune/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Bash for loop example</title>
		<link>http://blog.ledona.net/techblog/2009/02/02/bash-for-loop-example/</link>
		<comments>http://blog.ledona.net/techblog/2009/02/02/bash-for-loop-example/#comments</comments>
		<pubDate>Tue, 03 Feb 2009 05:16:22 +0000</pubDate>
		<dc:creator>ledona</dc:creator>
				<category><![CDATA[bash]]></category>
		<category><![CDATA[linux]]></category>

		<guid isPermaLink="false">http://blog.ledona.net/techblog/?p=20</guid>
		<description><![CDATA[Here&#8217;s a simple example that uses the for command in bash to echo a list of strings for a in 1 2 3; do echo $a;  done ; Note that the semicolons can be carriage returns instead.  In fact it seems that everything prior to the first semi-colon can appear on the same line, and [...]]]></description>
			<content:encoded><![CDATA[<p>Here&#8217;s a simple example that uses the for command in bash to echo a list of strings</p>
<p><em>for a in 1 2 3; do echo $a;  done ;</em></p>
<p>Note that the semicolons can be carriage returns instead.  In fact it seems that everything prior to the first semi-colon can appear on the same line, and <em>do </em>can appear on the first line or by itself on the second line or on the same line as the first command in the list of commands to execute (in the case of the example that is <em>echo</em>).</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.ledona.net/techblog/2009/02/02/bash-for-loop-example/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Best CD ripping/encoding for OSX</title>
		<link>http://blog.ledona.net/techblog/2009/01/22/best-cd-rippingencoding-for-osx/</link>
		<comments>http://blog.ledona.net/techblog/2009/01/22/best-cd-rippingencoding-for-osx/#comments</comments>
		<pubDate>Thu, 22 Jan 2009 22:09:33 +0000</pubDate>
		<dc:creator>ledona</dc:creator>
				<category><![CDATA[apple]]></category>
		<category><![CDATA[music]]></category>

		<guid isPermaLink="false">http://blog.ledona.net/techblog/?p=18</guid>
		<description><![CDATA[The best ripping/encoding software for OSX is and has been for a very long time (in my opinion) Max.  It supports both CDParanoia for ripping and numerous encoding formats including MP3, FLAC, OGG and a bunch more.  It even does transcoding. There are 3 types of ripping/encoding configuration settings that are important to me (and [...]]]></description>
			<content:encoded><![CDATA[<p>The best ripping/encoding software for OSX is and has been for a very long time (in my opinion) <a href="http://sbooth.org/Max/">Max</a>.  It supports both CDParanoia for ripping and numerous encoding formats including MP3, FLAC, OGG and a bunch more.  It even does transcoding.</p>
<p>There are 3 types of ripping/encoding configuration settings that are important to me (and should be to you) when ripping CDs; the rip settings, the encode settings and the output metadata settings.  When ripping I want the highest quality rip I can get. For that I configure Max to use cdparanoia set to Full paranoia mode.  For encoding I want both mp3 files and FLAC files.  MP3 files are the most portable, while FLAC files are lossless and have the highest possible quality.  Max allows you to encode to multiple formats simultaneously, so for encoding CDs I enable and configure both.  I use the default FLAC settings.  For MP3 I use the Transparent setting, which produces the highest quality VBR (variable bit rate) MP3 files appropriate for the audio.</p>
<p>If there is any weakness to Max it is in the management of metadata.  Since Max is concerned with ripping and encoding its not too much of a negative that metadata management is lacking, but it is something of an inconvenience.  Max attempts to pulls tag information (artist, album, track title, ets&#8230;) from MusicBrainz, which in my experience has maybe a 70% hit rate.  Even if it pulls the correct information it does not automatically pull album art.  Max does allow you to pull art from Amazon, but if the tag information does not match with Amazon, or if no tag information is available from MusicBrainz then you&#8217;ll have to manually correct your tags before querying Amazon.  I&#8217;d estimate that getting a valid hit in MusicBrainz and having the tags match with Amazon for album are is about 50% for me.  For the other 50% you can manually enter all the album info prior to ripping and Max will place the metadata into the encoded music files.  That&#8217;s too much of a hassle for me, so instead I just enter the artist and album name.  For compilations I just enter the album name.  Later I use an app like mp3tag (sadly only available on PC) to correct tags and get album art in bulk.</p>
<p>In addition to tags you should make sure that the filename convention works for you.  I like having a folder full of artist names and in each folder have all music tracks with a naming convention of:</p>
<p>ALBUMNAME-TRACKNUMBER-TRACKTITLE</p>
<p>If the album is a compilation it will be placed into a top level folder named Various Artists.</p>
<p>The only thing to add is that on PC the best I&#8217;ve seen (and I&#8217;ve used it extensively as well) is <a href="http://www.exactaudiocopy.de/">Exact Audio Copy (EAC)</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.ledona.net/techblog/2009/01/22/best-cd-rippingencoding-for-osx/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Using find to collect and tar files</title>
		<link>http://blog.ledona.net/techblog/2009/01/13/using-find-to-collect-and-tar-files/</link>
		<comments>http://blog.ledona.net/techblog/2009/01/13/using-find-to-collect-and-tar-files/#comments</comments>
		<pubDate>Tue, 13 Jan 2009 18:06:48 +0000</pubDate>
		<dc:creator>ledona</dc:creator>
				<category><![CDATA[linux]]></category>

		<guid isPermaLink="false">http://blog.ledona.net/techblog/?p=16</guid>
		<description><![CDATA[Lets say that you have a deep, wide directory structure with a ton of files of various types.  How do you go about extracting all the files with a given filename, while maintaining the folder structure that the files were in?  And for added fun lets say you want to tar the resulting list of [...]]]></description>
			<content:encoded><![CDATA[<p>Lets say that you have a deep, wide directory structure with a ton of files of various types.  How do you go about extracting all the files with a given filename, while maintaining the folder structure that the files were in?  And for added fun lets say you want to tar the resulting list of files.</p>
<p>&gt; find . -name &#8216;FILENAME&#8217;  -exec tar &#8211;append -vf ~/TAR_FILE.tar {} \;</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.ledona.net/techblog/2009/01/13/using-find-to-collect-and-tar-files/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

