Piotr Kaźmierczak 2014-11-26T20:57:38+00:00 http://piotrkazmierczak.com Piotr Kaźmierczak Chimps Rock at Game Theory 2014-10-20T00:00:00+00:00 http://piotrkazmierczak.com/2014/10/20/chimps-rock-at-game-theory <blockquote> <p>Economics assumes that people are rational, self-interested, lightning fast calculators. Obviously a bad assumption as we are constantly told. Chimps, on the other hand, are rational, self-interested, lightning fast calculators.</p> </blockquote> Shaka, When the Walls Fell 2014-09-28T00:00:00+00:00 http://piotrkazmierczak.com/2014/09/28/shaka-when-the-walls-fell <p>Ian Bogost writes about a famous Star Trek TNG episode: </p> <blockquote> <p>On stardate 45047.2, Jean-Luc Picard leads the crew of the Enterprise in pursuit of a transmission beacon from the El-Adrel system, where a Tamarian vessel has been broadcasting a mathematical signal for weeks. The aliens, also known as the Children of Tama, are an apparently peaceable and technologically advanced race with which the Federation nevertheless has failed to forge diplomatic relations. The obstacle, as Commander Data puts it: “communication was not possible.”</p> </blockquote> <p>The funniest thing about this particular episode is how polarized opinions about it are. <a href="http://en.memory-alpha.org/wiki/Darmok_%28episode%29">“Darmok”</a> is by far the most controversial of all <abbr title="Star Trek: The Next Generation">TNG</abbr> episodes. While (as Bogost points out) the episode touches upon the very essence of Star Trek and Gene Rodenberry’s vision of utopian human future, most controversy that surrounds it concerns how… <em>unserious</em> it is. I think this might be the only TNG episode that I felt slightly uncomfortable watching, because of how silly it felt. <!--more--></p> <p>But Bogost’s piece reminded me of a book I read some time ago, which touches upon the issue of understanding vs. comprehension, the nature of intelligence (yes, there’s even a discussion about Searle’s <a href="http://en.wikipedia.org/wiki/Chinese_room">Chinese Room</a> in there) and difficulties of “first contact” in a much more intellectually demanding yet satisfying way. This book is Peter Watts’ <a href="http://en.wikipedia.org/wiki/Blindsight_(Watts_novel)">“Blindsight”</a>. While I don’t agree with many of the points the author makes throughout the novel, I can’t think of a better “hard sci-fi” that I’ve read in a long, long time. “Blindsight” most definitely isn’t an easy read, but if you like good old science-fiction that really tries to do science justice and packs loads of facts, you won’t be disappointed. Oh and best of all, the novel is available online for free (CC license).</p> Last bike ride in Norway 2014-09-22T00:00:00+00:00 http://piotrkazmierczak.com/2014/09/22/last-bike-ride-in-Norway <p>Last weekend, me and Karolina went on <a href="http://piotrandkarolina.wordpress.com/2014/09/14/sunday-ride-to-fanafjellet/">a bike ride</a> from Laksevåg in Bergen, through Nesttun and Lysekloster to Fanafjellet and then back to town. It was a lovely, sunny day, and we had a pleasant ~50km ride, but what I didn’t realize that day is that it was our last bike ride in Norway, at least for the foreseeable future. The bike on the picture above, <a href="http://piotrkazmierczak.com/2010/05/16/meet-jake/" title="Meet Jake">Kona Jake</a>, has just been sold, because Karolina is moving to Munich this Thursday, and I will follow her in about two-three weeks. My contract at Bergen University College is over since mid-July, and my PhD education at the University of Bergen is almost finished (I will hand in my thesis within the next two weeks). We’re moving out, starting a new chapter of our lives in Germany. </p> <p>There’s many, many things that I will miss once I move, but I think the absolutely fantastic nature of Bergen and its surroundings will be chief among them. If you like cycling and/or mountains, and you can afford it, you should definitely visit Western Norway. I’ve been to a lot of places around the world but in my opinion nothing comes even close to the beauty of this land.</p> <p>You will be missed, Norway. </p> Spotify, Pandora and how streaming music kills jazz and classical 2014-07-26T00:00:00+00:00 http://piotrkazmierczak.com/2014/07/26/spotify-pandora-and-how-streaming-music-kills-jazz-and-classical <blockquote> <p>“All of my colleagues — composers and arrangers — are seeing huge cuts in their earnings,” says Paul Chihara, a veteran composer who until recently headed UCLA’s film-music program. “In effect, we’re not getting royalties. It’s almost amusing some of the royalty checks I get.” One of the last checks he got was for $29. “And it bounced.”</p> </blockquote> <p><a href="http://www.salon.com/2014/07/20/its_not_just_david_byrne_and_radiohead_spotify_pandora_and_how_streaming_music_kills_jazz_and_classical/">Scott Timberg writes</a> about how the recent rise of streaming services like Spotify, Rdio or Pandora affects royalties in the world of niche music. It’s sad, but not unexpected. However, at least in Europe a jazz/classical music enthusiast observes a growing number of websites that sell uncompressed audio files from small labels. There’s the German <a href="http://www.highresaudio.com/">Highresaudio</a> and the Norwegian <a href="http://www.gubemusic.com/">Gubemusic</a>, and both these services have a pretty big catalogue (at least compared to the American <a href="http://www.hdtracks.com/">HDTracks</a>).<sup id="fnref:1"><a href="#fn:1" class="footnote">1</a></sup> They are also both targeting the narrow group of listeners, and their catalogues contain mostly jazz and classical music. Which brings us to the second quote from the article:</p> <blockquote> <p>Here’s a good place to start: Say you’re looking for a bedrock recording, the Beethoven Piano Concertos, with titan Maurizio Pollini on piano. Who is the “artist” for this one? Is it the Berlin Philharmonic, or Claudio Abbado, who conducts them? Is it Pollini? Or is it Beethoven himself? If you can see the entire record jacket, you can see who the recording includes. Otherwise, you could find yourself guessing.</p> </blockquote> <p>My question is: why hasn’t anyone figured this out yet? It’s an at-least-decent business idea, and there’s a consumer group that can be easily targeted. Jazz fans complain about Spotify’s lack of content all the time. They also tend to be affluent (or pose as such, or are willing to spend more money on music), so you can charge them more. And they’re often suffering from <em>audiophiliac</em> illness. </p> <p>Create an <em>elite</em>, expensive streaming service for jazz and classical lovers. <strong>Take our money!</strong></p> <div class="footnotes"> <ol> <li id="fn:1"> <p>Yes, I know high-res downloads <a href="http://xiph.org/~xiphmont/demo/neil-young.html">make no sense</a>. I don’t care. I only care that it’s lossless and that they have albums others don’t. <a href="#fnref:1" class="reversefootnote">&#8617;</a></p> </li> </ol> </div> Moto G 4G and Android from an iPhone 4 user's perspective 2014-07-24T00:00:00+00:00 http://piotrkazmierczak.com/2014/07/24/moto-g-4g-and-android-from-an-iphone-4-users-perspective <iframe border="0" scrolling="no" width="78" height="17" allowtransparency="true" frameborder="0" style="margin-bottom: -3px; z-index: 1338; border: 0px; background-color: transparent; overflow: hidden;" src="http://www.instapaper.com/e2?url=http%3A%2F%2Fpiotrkazmierczak.com%2F2014%2F07%2F24%2Fmoto-g-4g-and-android-from-an-iphone-4-users-perspective%2F&amp;title=Moto+G+4G+and+Android+from+an+iPhone+4+user%27s+perspective"></iframe> <p>Some time ago I realized that my 2010 iPhone 4 is no longer usable, at least not in any pleasant manner. While initially I thought iOS 7 is to blame, I quickly discovered that the OS itself wasn’t the problem, but the bigger memory footprint of many apps that wanted to take advantage of what iOS 7 offered was.<sup id="fnref:1"><a href="#fn:1" class="footnote">1</a></sup> Daily use of a 4-year-old iPhone became too frustrating, so I started considering options. Also, the screen was cracked and I’ve no idea how, where or when I cracked it. </p> <p>First, of course, was the 5s, Apple’s latest and greatest. It is, <a href="http://www.theverge.com/2014/6/11/5797664/the-best-smartphone">according to some</a>, the best smartphone you can buy today, and from what I saw in the stores, it’s a remarkable piece of engineering indeed. Still, the basic, 16GB 5s costs <a href="http://store.apple.com/no/buy-iphone/iphone5s">5790 NOK</a> here in Norway, so I figured perhaps it’d be wise to consider other options.<sup id="fnref:2"><a href="#fn:2" class="footnote">2</a></sup> There was the 5c, which is basically iPhone 5’s hardware for 4490 NOK, and there was the 4s for a ridiculous 3290 NOK, both of which I dismissed as too expensive as well. So then there was Android.</p> <p>The Internet says one should buy <a href="http://www.anandtech.com/show/7517/google-nexus-5-review">Nexus</a>. It’s <em>pure</em> Android, straight from Google, it’s fast and it’s relatively cheap (2689 NOK – cheaper than the iPhone 4s!), but it’s also quite big. I held it in my hand and it felt uncomfortably large (what’s with all these huge smartphones?). So then the next great thing was, the Internet said, <a href="http://www.theverge.com/2013/12/2/5156546/moto-g-review">Moto G</a> and <a href="http://www.theverge.com/2014/5/22/5737290/motorola-moto-e-review">Moto E</a>, Google’s cheap phones. Both models run close-to-stock Android, and both are kept up-to-date with latest version of the OS.<sup id="fnref:3"><a href="#fn:3" class="footnote">3</a></sup></p> <p>At first I was tempted by Moto E. Since an Android phone was supposed to be just an experiment, I could simply buy the cheapest option. But then again Moto G was not significantly more expensive, and reviews claimed it had superior display and camera, so I went for the updated G, with 8 GB of internal memory (microSD expandable) and 4G antenna. Here are my impressions of the handset and Android. <!--more--></p> <p>First and foremost, this is an unbelievably cheap phone. Its build quality isn’t exactly a match for my old iPhone 4 (not to mention the 5s), but it’s still a well built and pretty good looking (if not unassuming) phone. The contrast in speed of operation between my old iPhone and Moto G is, expectedly, staggering. Even though Moto G is no benchmark winner compared to other Android handsets, it still works remarkably quickly. There’s very little noticeable lag when launching apps, switching between them or even browsing with multiple tabs open in Chrome. And here comes the best part: I payed £139.95 for Moto G.</p> <p>I honestly think this is the very best ace Google has up its sleeve. Competing with Apple on the high-end is difficult, and will always be tricky, regardless of how brilliant the phone is. But if they’re able to make a “low-end” phone <em>that</em> good, sell it for <em>less than half the price</em> of a 2011 iPhone 4s and still make money on it – well, that’s just impossible to beat. So yes, it’s <em>great</em> value. Let’s talk about the software now. </p> <p>The last time I played with Android was when I tried my friend’s <a href="http://en.wikipedia.org/wiki/HTC_Desire">HTC Desire</a>. This was 2010, and there was no question Android was inferior to iOS. HTC Desire was sluggish and ugly compared to iPhone 4. Well, four years later the gap between the two is no longer that visible, or perhaps gone. Android 4.4 that the Moto G is running is much more polished and much better. I can see how it may be more appealing to some people than iOS. It allows more freedom of choice when it comes to, e.g., setting default apps<sup id="fnref:4"><a href="#fn:4" class="footnote">4</a></sup> or choosing 3rd party keyboards. It has widgets, which I’m not a huge fan of, but I agree it’s cool to have live weather updates on the home screen. And finally, Google Play store app selection isn’t as bad as I thought. Sure, there’s no <a href="http://dayoneapp.com/">Day One</a> (which I miss a lot), but at least there’s <a href="http://asherv.com/threes/">Threes</a> (hell, there’s even <a href="https://www.instapaper.com/android">Instapaper</a>!). But it’s not perfect. </p> <p>It seems to me Android only makes sense when you’re heavily invested in the Google ecosystem. Google account isn’t technically necessary to use the device, but in reality you’ll be reminded at every step that you should use it. I wasn’t so big on Google apps for various reasons (which is perhaps a story for another post), and I quickly realized that in order to have more fun using Moto G I’d better give GMail and Google Calendar another shot. It’s nothing wrong for Google to make you <em>want</em> to use their services if they design the OS, in principle, but it’s slightly paradoxical that it’s Apple’s iOS that plays better with open standards such as IMAP, CalDav and CardDav out of the box. Again, this is not to say that you can’t use these on Android, it’s just that the experience is much better on iOS. And of course you can do <em>anything</em> using 3rd party apps, but this brings me to another problem. </p> <p>Android stock apps suck. With the exception of Chrome and GMail perhaps, everything else that comes with Android 4.4 is pretty bad. iPhone users like to complain about Mail.app, but its quality is really great compared to Android’s default Mail application. Same goes for everything else – contacts, photo management, camera or hangouts. iOS doesn’t allow you to change defaults, but the defaults it provides are of <em>decent</em> quality. So yeah, you can use 3rd party apps, but this causes another problem which Karolina pointed out: clutter. Suddenly there are many different things serving the same function.<sup id="fnref:5"><a href="#fn:5" class="footnote">5</a></sup> And when you bring the widgets on it can get real crazy, but I guess this depends on a user. </p> <p>Finally there’s the issue of interface design guidelines. It would appear that while Android’s appearance improved greatly, the user experience is still inconsistent between apps. Stock apps are consistent of course, and many 3rd party apps are as well (<a href="http://www.mailboxapp.com/">Mailbox</a>!), but soo many are not. Take <a href="http://www.any.do/">Any.Do</a> for example. While in principle a great app, it just looks odd on the screen on my phone. It looks like it’s been designed for a different OS. Same goes for many other apps as well, which makes the poor quality of default apps an even bigger flaw. </p> <p>But at the end of the day GMail, Chrome, <a href="https://twitter.com/pkazmierczak/status/482137624019484672">Snapchat</a>, Evernote and Play Music work just fine, and that’s mostly what I need from a smartphone. There are also parts of Android that work better than iOS, like Google Play Music. Uploading all my music files to Google servers for free and syncing them with my phone without a computer? Yes, please! And even though I have lots of iOS habits that make me want to buy a 5s even though it’s oh-so-pricey, after a couple more months with Moto G I might consider buying another Android headset. And if Google sticks to the tradition of keeping the prices of Nexus phones low, my next phone might easily be the Nexus 6 (or whatever it’s called). </p> <p>Bottom line is, for the price of Moto G you can have a half of a 3 year old iPhone, a crappy old out-of-date Android phone, or a low-end Nokia Lumia with an OS that has the smallest app selection on the market. And then it’s a no-brainer. </p> <div class="footnotes"> <ol> <li id="fn:1"> <p>Evernote, which is an app I use on a daily basis, became as beautiful as unusable. Sometimes it’d take a minute to open or save a note. <a href="#fnref:1" class="reversefootnote">&#8617;</a></p> </li> <li id="fn:2"> <p>I’m moving out from Norway soon, so I can’t get a new iPhone with a 2-year contract. Also, I’m not saying the 5s isn’t worth the money. <a href="#fnref:2" class="reversefootnote">&#8617;</a></p> </li> <li id="fn:3"> <p>Or so Google claims; let’s see if it’s still true when the sale of Motorola Mobility to Lenovo gets through. <a href="#fnref:3" class="reversefootnote">&#8617;</a></p> </li> <li id="fn:4"> <p>To readers unfamiliar with iOS: while it allows 3rd party browsers and email clients, it doesn’t allow to set them as default handlers (this might change with iOS 8 I guess). <a href="#fnref:4" class="reversefootnote">&#8617;</a></p> </li> <li id="fn:5"> <p>Actually, this is a problem even with the “stock” 4.4 that Moto G’s running. When I want to open a photograph from en email attachment, it asks me which app to use: “Photos” or “Gallery”. How would I know? Why do I have to know? Why are there two apps that serve exactly the same purpose installed by default? There’s your poor design right there. <a href="#fnref:5" class="reversefootnote">&#8617;</a></p> </li> </ol> </div> Jazz icon Charlie Haden dies at 76 2014-07-12T00:00:00+00:00 http://piotrkazmierczak.com/2014/07/12/jazz-icon-charlie-haden-dies-at-76 <p>I am very sad to read that Charlie Haden <a href="http://www.theguardian.com/music/2014/jul/12/jazz-icon-charlie-haden-dies-at-76">died last Friday</a>.<sup id="fnref:1"><a href="#fn:1" class="footnote">1</a></sup> He was one of the first jazz musicians I ever heard about, when my dad bought the now legendary <a href="https://en.wikipedia.org/wiki/Beyond_the_Missouri_Sky_%28Short_Stories%29">“Beyond the Missouri Sky”</a> (Verve 1997) record, and I immediately fell in love with his great bass lines and compositions. Then I learned about Charlie Haden’s history with Ornette, and I also realized he played with Keith Jarrett’s quartet in the 70s. A versatile, curious musician who always enriched any jazz album he appeared on with his lyrical bass lines. His death is a terrible loss. Seems sadly prophetic that his latest duo album with Jarrett is titled <a href="http://www.ecmrecords.com/Catalogue/ECM/2300/2399.php?cat=%2FLabels%2FECM&amp;we_start=0&amp;lvredir=712">“Last Dance”</a> (ECM 2014). </p> <p>Below are a couple of my favorite tracks by Charlie Haden or with him as a sideman. Listen and admire. </p> <iframe src="https://embed.spotify.com/?uri=spotify:user:pkazmierczak:playlist:3lUZ37foSjnb4pQQ3CH4Kw" width="300" height="330" frameborder="0" allowtransparency="true"></iframe> <div class="footnotes"> <ol> <li id="fn:1"> <p>Not a long time ago Paco de Lucia passed away. Seems 2014 is a very bad year for jazz music. <a href="#fnref:1" class="reversefootnote">&#8617;</a></p> </li> </ol> </div> "speed" and "aerodynamics" 2014-06-14T00:00:00+00:00 http://piotrkazmierczak.com/2014/06/14/speed-and-aerodynamics <blockquote class="twitter-tweet" lang="en"><p>Companies selling &quot;speed&quot; and &quot;aerodynamics&quot; to dudes who only ride on the weekends, rather than selling them an experience.</p>&mdash; John Watson (@JohnProlly) <a href="https://twitter.com/JohnProlly/statuses/476173495353618432">June 10, 2014</a></blockquote> <script async="" src="//platform.twitter.com/widgets.js" charset="utf-8"></script> <p>I used to laugh at people paying$7k for bicycles with handmade steel frames and all the hype that surrounded the whole <a href="http://2014.handmadebicycleshow.com">NAHBS</a> community. After some months of reading <abbr>PinP</abbr> aka <a href="http://theradavist.com">The Radavist</a>, however, I’ve changed my mind completely. </p> <p>Modern competitive cycling is, to me, completely uninteresting sport. I don’t watch the big races, I don’t care about the pros.<sup id="fnref:1"><a href="#fn:1" class="footnote">1</a></sup> Doping is so prevalent that following these events makes no sense to me, and in the same way I don’t give a shit about carbon frames designed in wind tunnels. What John Watson’s community represents is the opposite: yes, it’s nice to crush <a href="http://en.wikipedia.org/wiki/King_of_the_Mountains">KOM</a>s<sup id="fnref:2"><a href="#fn:2" class="footnote">2</a></sup> and go <a href="http://www.velominati.com/the-rules/#10">as fast as you can</a>, but that’s not why we ride. We ride, because riding a bike is <em>rad</em>, because the experience of being outdoors in beautiful mountains is fantastic, and because riding a bike is part of our lifestyle – we <em>love</em> bikes. And yes, if I’m to choose between a Taiwan-made carbon frame wind-tunnel-developed bike from one of the major manufacturers versus a steel frame bicycle US/UK-made by guys who <em>love</em> the work, I’m gonna pay those guys, and I’m gonna pay them more than I should. And I’m still gonna be faster uphill than the 50+ overweight fellas on their Pinarello Dogma bikes. </p> <div class="footnotes"> <ol> <li id="fn:1"> <p>Except for <a href="http://www.majawloszczowska.pl">Maja</a>. Maja is awesome. <a href="#fnref:1" class="reversefootnote">&#8617;</a></p> </li> <li id="fn:2"> <p>Though even Strava says that riding is <a href="http://blog.strava.com/strava-instagram-5584/">not only about KOMs</a>. <a href="#fnref:2" class="reversefootnote">&#8617;</a></p> </li> </ol> </div> Quickest way to scrobble tracks to Last.fm with iTunes and AppleScript 2014-06-09T00:00:00+00:00 http://piotrkazmierczak.com/2014/06/09/quickest-way-to-scrobble-tracks-to-last-fm-with-itunes-and-applescript <p>It’s amazing in how many ways one can waste time. Until recently I didn’t know what <a href="http://en.wikipedia.org/wiki/AppleScript">AppleScript</a> was, but once I read about it, I quickly came up with what might best be described as silliest “programming” project ever. Based on <a href="http://stackoverflow.com/questions/7648618/applescript-to-play-a-song-with-a-specific-artist-in-itunes">two</a> <a href="http://stackoverflow.com/questions/11174778/best-way-to-make-this-apple-script-play-a-specific-portion-of-a-song-in-itunes">threads</a> from SO, I hacked a very short script that is meant for <a href="http://last.fm">Last.fm</a> <em>cheating</em>. </p> <div class="highlight"><pre><code class="language-applescript" data-lang="applescript"><span class="k">tell</span> <span class="nb">application</span> <span class="s2">&quot;iTunes&quot;</span> <span class="k">set</span> <span class="nv">mySongs</span> <span class="k">to</span> <span class="nb">every</span> <span class="nv">track</span> <span class="k">of</span> <span class="nv">library</span> <span class="nv">playlist</span> <span class="mi">1</span> <span class="nb">whose</span> <span class="nv">artist</span> <span class="ow">is</span> <span class="s2">&quot;Uri Caine Trio&quot;</span> <span class="k">repeat</span> <span class="nv">with</span> <span class="nv">theTrack</span> <span class="k">in</span> <span class="nv">mySongs</span> <span class="nb">play</span> <span class="nv">theTrack</span> <span class="k">repeat</span> <span class="k">until</span> <span class="p">(</span><span class="nv">player</span> <span class="na">position</span> <span class="o">&gt;</span> <span class="p">((</span><span class="k">get</span> <span class="nv">duration</span> <span class="k">of</span> <span class="nb">the</span> <span class="nv">current</span> <span class="nv">track</span><span class="p">)</span> <span class="o">/</span> <span class="mi">2</span><span class="p">))</span> <span class="ow">or</span> <span class="p">(</span><span class="nv">player</span> <span class="na">position</span> <span class="o">&gt;</span> <span class="mi">240</span><span class="p">)</span> <span class="nb">delay</span> <span class="mf">0.5</span> <span class="k">end</span> <span class="k">repeat</span> <span class="k">end</span> <span class="k">repeat</span> <span class="k">end</span> <span class="k">tell</span></code></pre></div> <p>In other words, the script tells iTunes to play all the tracks by the artist mentioned in the second line and skip to the next track if either 50% of the track length or 4 minutes of playing have passed (otherwise Last.fm won’t count the track as played). The rationale behind this script is twofold:</p> <ol> <li> <p>One can use it to scrobble artists whose albums one listens to on a, say, standalone CD-player in order to make one’s charts 100% accurate, or at least as accurate as Audioscrobbler allows. </p> </li> <li> <p>One can use it to “overscrobble” particular artists in order to project a particular image, e.g. one may scrobble lots of Keith Jarrett albums in order to increase count, thus appearing more intellectually profound. </p> </li> </ol> <p>Either way, I expect everyone to have lots of fun using the above script, and I expect myself to have even more fun exploring AppleScript further and creating more silly programs. </p> Wayne Shorter Quartet at USF Verftet (NattJazz 2014) 2014-06-06T00:00:00+00:00 http://piotrkazmierczak.com/2014/06/06/wayne-shorter-quartet-at-usf-verftet-nattjazz-2014 <p>I first heard about Wayne Shorter when my dad bought the brilliant <a href="http://en.wikipedia.org/wiki/1_%2B_1_(album)">“1+1”</a> (Verve 1997) album he recorded with Herbie Hancock. I listened to it and was blown away – the soprano saxophone in the hands of Wayne Shorter sounded like nothing I heard before. I had a “jazz band” in my music school at the time,<sup id="fnref:1"><a href="#fn:1" class="footnote">1</a></sup> and I told the guys “Look, Shorter and Hancock play without drums and bass, so we can do it too!”, but obviously we couldn’t, and we all quickly understood that we know nothing about improvisation. </p> <p>I haven’t bought any Wayne Shorter records for a couple of years. Some time ago I bought two of his classic albums – <a href="http://en.wikipedia.org/wiki/JuJu_(Wayne_Shorter_album)">“Juju”</a> (Blue Note 1964) and <a href="http://en.wikipedia.org/wiki/Speak_No_Evil">“Speak No Evil”</a> (Blue Note 1965) – and enjoyed them, but of course this was the old post- hard-bop sound of late 60s, significantly different to Shorter’s current music which I didn’t know. That is, until last year’s release of his new<sup id="fnref:2"><a href="#fn:2" class="footnote">2</a></sup> quartet’s “Without a Net” (Blue Note 2013). </p> <p>“Without a Net” reminds me of “1+1” a lot, even though it’s a quartet with piano (Danilo Perez), double bass (John Patitucci) and drums (Brian Blade), but the music is so much alike – somewhere between aggressive hard-bop and contemplative free, on the intersection of the best of classic 60s jazz, and the new, contemporary, and somewhat intellectually challenging music. I loved the album immediately, even though (as with “1+1”) I realized that I didn’t fully understand it, and it took me some time to fully appreciate the music. So when I heard Wayne Shorter Quartet is coming to town, I knew I had to go and see them live. </p> <p>They played last Friday at our local Spring jazz festival <a href="http://nattjazz.no/">NattJazz</a>, and the concert was excellent. The music, as Hannah put it, was “enchanting”.<sup id="fnref:3"><a href="#fn:3" class="footnote">3</a></sup> The contemplative and delicate sound of Wayne Shorter’s saxophone juxtaposed with energetic, aggressive sound of the trio created what can only be described as <em>magic</em>, and it lasted for a 1,5hr concert and three encores. Next to <a href="/2013/07/08/keith-jarrett-trio-30th-anniversary-tour-at-de-doelen-rotterdam/">Keith Jarrett Trio</a>, <a href="/2012/07/09/im-in-london-for-the-first-time-in-the-uk-2/">Uri Caine Trio</a> and Ornette Coleman quartet’s performances, Wayne Shorter Quartet’s Friday concert was one of the best one’s I’ve ever been to. </p> <p>Here’s what their recent concert in Vienna looked like, the Verftet concert was quite similar. </p> <iframe width="420" height="315" src="//www.youtube.com/embed/0UeqbMV1d0k?rel=0" frameborder="0" allowfullscreen=""></iframe> <div class="footnotes"> <ol> <li id="fn:1"> <p>We were 13. It wasn’t even remotely close to “jazz”, we were barely able to play the notes. <a href="#fnref:1" class="reversefootnote">&#8617;</a></p> </li> <li id="fn:2"> <p>Actually, <a href="http://en.wikipedia.org/wiki/Wayne_Shorter#Quartet">the quartet</a> isn’t so new, they’ve been playing for 14 years now. I didn’t know. <a href="#fnref:2" class="reversefootnote">&#8617;</a></p> </li> <li id="fn:3"> <p>“It’s the PG-13 description. “ <a href="#fnref:3" class="reversefootnote">&#8617;</a></p> </li> </ol> </div> Strava’s Cycling App Is Helping Cities Build Better Bike Lanes 2014-06-06T00:00:00+00:00 http://piotrkazmierczak.com/2014/06/06/stravas-cycling-app-is-helping-cities-build-better-bike-lanes <p><a href="http://www.wired.com/2014/06/strava-sells-cycling-data/" class="link">Wired:</a> </p> <blockquote> <p>Current methods of counting cyclists take a ton of time or a ton of money. The DOT can videotape traffic and have someone sit at a monitor and count cyclists, or it can send someone to sit on the sidewalk and watch them go by in real time. Neither method is terribly efficient.</p> </blockquote> <p>You’d think that the problem of building cycling lanes is a simple one, right? Well, it’s not. Apparently most cities struggle with obtaining data; no one really knows where and how many cyclists ride, and the only method available until now was installing bike counters, but these are expensive and measure bicycle traffic only at fixed points. So now, apparently, you can buy data from Strava, and this is brilliant.<sup id="fnref:1"><a href="#fn:1" class="footnote">1</a></sup> </p> <p>Strava is my favorite sport-tracking service (I wrote about it <a href="/2012/03/03/i-ride-because-im-angry-at-other-people/">before</a>), and it’s found a new and somewhat surprising source of revenue – selling “heatmaps” to cities.<sup id="fnref:2"><a href="#fn:2" class="footnote">2</a></sup> Heatmaps are created by analyzing publicly available GPS data from users’ rides and mapping them to frequency. For example, this is a heatmap for Bergen:</p> <p><a href="http://labs.strava.com/heatmap/#13/5.30730/60.38387/gray/bike"><img src="/images/strava-heatmap.png" /></a></p> <p>Some say that Strava isn’t popular amongst commuters, and that it’s mainly used by people who treat cycling as sport, and not just a mean of transportation, but as is clearly visible on the screenshot above, racers need to get through town just like anyone else; I’d conjecture they need to do this even more often than others. </p> <p>Anyways, I just wanted to point everyone’s attention to the Wired article, because:</p> <ul> <li>it’s very good and you should read it; </li> <li>I envy Strava the brilliant idea of “heatmaps”; </li> <li>it makes me wanna seriously consider a career as a <a href="http://automattic.com/work-with-us/data-wrangler/">Data Wrangler</a>. </li> </ul> <div class="footnotes"> <ol> <li id="fn:1"> <p>Cheap, too. Only $20000/year. <a href="#fnref:1" class="reversefootnote">&#8617;</a></p> </li> <li id="fn:2"> <p>Some people get upset with <a href="http://www.strava.com">Strava</a> selling “their” data, but they don’t realize the data is anonymized completely, very useful, and publicly available anyway. <a href="#fnref:2" class="reversefootnote">&#8617;</a></p> </li> </ol> </div> Hit & Run 2014-03-22T00:00:00+00:00 http://piotrkazmierczak.com/2014/03/22/hit-and-run <iframe border="0" scrolling="no" width="78" height="17" allowtransparency="true" frameborder="0" style="margin-bottom: -3px; z-index: 1338; border: 0px; background-color: transparent; overflow: hidden;" src="http://www.instapaper.com/e2?url=http%3A%2F%2Fpiotrkazmierczak.com%2F2014%2F03%2F22%2Fhit-and-run%2F&amp;title=Hit+%26+Run"></iframe> <p>Last Sunday night I was walking home and I got hit by a car on a zebra crossing.<sup id="fnref:1"><a href="#fn:1" class="footnote">1</a></sup> It was pretty late (around 11:30pm) and there was very little traffic. I was on a green light and while I was in the middle of the road, a black car came from behind me (he was making a left turn). I stopped, turned right, and as I was facing the car it hit me on my left leg knocking me down, and then just drove off. Before we get any further, I am happy to assure everyone that I’m perfectly fine, and that I did not sustain any serious injuries. But here are some of my thoughts about the accident. </p> <p>I remember very vividly how I felt immediately after the accident – I was mad. The guy didn’t stop. In Norway. <a href="https://www.google.com/#q=norway+best+country+to+live">The best country on earth</a>. I mean, seriously. If this happened in my lovely homeland or anywhere else in the world, I would still be outraged, but perhaps less surprised. But it happened in Norway – someone<sup id="fnref:2"><a href="#fn:2" class="footnote">2</a></sup> just hit me with a car on a zebra crossing, and then ran away. So yes, my very first feeling when I was lying there in the middle of the street was outrage mixed with bewilderment. This feeling didn’t really pass when another car stopped and called the ambulance – “Call the goddamn cops!” – I yelled – “I don’t need a doctor, I’m fine, just get that guy who nearly ran me over!” Luckily the person who rescued me was a little more lucid and called the ambulance first – “You got blood all over your head man, you <em>need</em> an ambulance.” </p> <p>Right after the rage came fear. I didn’t realize what happened until 10 minutes after the accident, I didn’t realize how lucky I was and how close to a very serious injury (at best) I was. While sitting in the ambulance and later in the emergency room I kept thinking that it really was a close call – thoughts that the doctor confirmed. And then I also realized that it all felt highly unreal. You know, one of those things that happen to <em>other</em> people. Like cancer, tsunamis or losing your house. Being hit by a car coming out of nowhere is one of those things. And I immediately realized that I wasn’t prepared for it at all. I had medical insurance as anyone who pays taxes in Norway has, but did I have any accident-specific insurance or life insurance? I’m not sure, probably not. I think I have some insurance from my work, but does it cover such cases? Unlikely. I don’t know. And of course I was lucky that it didn’t really cost me much, except for drugs, a cab ride back home and the fact that I need to buy new glasses.<sup id="fnref:3"><a href="#fn:3" class="footnote">3</a></sup> I had a computer in my bag but it sustained only minor injuries. Then again – what if it sustained some serious damage? I wasn’t prepared for that. I guess it’s like with backups, that there are two categories of people: those that have accident &amp; life insurance, and those that will have it. Now I’m becoming the former. </p> <p>The police told me there are virtually no chances at finding the driver, because I am uncertain about the car and I haven’t seen the registration plates, but they did say they would look for him and even notified the <a href="http://www.bt.no/nyheter/lokalt/--Stakk-av-etter-pakjorsel-3080452.html">local paper</a>. It’s been almost a week since the accident now and I haven’t heard from them, so I assume the driver will not be found, but as time passes I am feeling less angry and more grateful for how benign my injuries were. </p> <p>Finally, I was and still am overwhelmed at how friendly, helpful and supportive everyone around me has been. Huge thanks go to: </p> <ul> <li>Hannah, for showing up at my apartment the day after, helping me with the police, cooking chicken zoup for me and leasing Toby;</li> <li>my parents, for calling me twice a day to check how I’m doing (and for my uncle and aunt for calling on their behalf when necessary); </li> <li>Truls &amp; Samia, for providing me with premium quality chocolate;</li> <li>Karolina, for helping me wash my head in such a way that the bandages stay relatively dry; </li> <li>Erik E., for sketching plans of capturing the driver and bringing him to justice (I believe we agreed that the penalty in this case was hanging); </li> <li>my sister and her husband, for reminding me that Rambo had it worse;<sup id="fnref:4"><a href="#fn:4" class="footnote">4</a></sup> </li> <li>Erik P., Maja, Pim, Thomas and Beata for being worried and making sure I was alright. </li> </ul> <p>It’s really sweet of you all. You made being hit by a car a genuine pleasure, almost. I’m not planning on being in a similar accident again, though, and as we know it is <a href="https://xkcd.com/795/">unlikely</a> I will have such an accident again. It’s just one more thing I can cross off my bucket list. </p> <div class="footnotes"> <ol> <li id="fn:1"> <p>For the locals: it was a zebra crossing on the corner of Carl Konows gt and Fyllingsveien. <a href="#fnref:1" class="reversefootnote">&#8617;</a></p> </li> <li id="fn:2"> <p>As we agreed with Truls and his father while discussing it, it must have been a driver from Oslo (or Poland, or Lithuania), for it is <em>impossible</em> that this was a local. As pointed out by Hannah, it is also impossible for the driver to be from Kristiansand. <a href="#fnref:2" class="reversefootnote">&#8617;</a></p> </li> <li id="fn:3"> <p>This one is actually a potentially big expense, but then again I can buy glasses in Poland with my mom. Me and my mom like going glasses shopping. It’s our thing. <a href="#fnref:3" class="reversefootnote">&#8617;</a></p> </li> <li id="fn:4"> <p>I tried finding a clip from “First Blood” of Rambo stitching his own arm, but I couldn’t find it anywhere. The only thing YouTube has to offer is his <a href="http://www.youtube.com/watch?v=xTgXnDZoYNA">“Nothing’s over!”</a> speech. <a href="#fnref:4" class="reversefootnote">&#8617;</a></p> </li> </ol> </div> No Smartphone For Lent 2014-03-04T00:00:00+00:00 http://piotrkazmierczak.com/2014/03/04/no-smartphone-for-lent <p>Matt Mullenweg is trying to give up using his smartphone during Lent, and I’m starting to think it’s a good idea. I notice that I’m dependent on a number of apps on my phone to a great degree – especially Calendar, Reminders, Evernote, Mail, Tweetbot and Google Maps – and I’m starting to think that I delegate too much of my own memory to my phone. I don’t exactly manage a company, and if I forget something then (1) probably nothing tragic will happen, and (2) perhaps it’ll teach me to remember things better, hell, maybe even to write things down on a piece of paper. And I really don’t <em>need</em> to check my email all the time, same way I don’t <em>need</em> to know what’s on twitter right now. </p> <p>So the plan is to switch to, as Matt puts it, <em>makes-phone-calls-only phone</em> and see how much I can manage with that. My bet is I won’t make it to the end of Lent, but I’m gonna try anyway. </p> Слава Україні! 2014-02-23T00:00:00+00:00 http://piotrkazmierczak.com/2014/02/23/slava-ukrayini <p><a href="http://www.economist.com/blogs/easternapproaches/2014/02/ukraines-new-dawn">The Economist:</a></p> <blockquote> <p>Once you have gained a taste for adrenaline-flavoured simplicity, it can become addictive. Ukraine needs a decade of hard work on reform to recover the chances squandered in the past 25 years, building the institutions, habits and attitudes needed for honest, lawful government. That will require patience and expertise, not courage and barricades.</p> </blockquote> <p>I love Ukraine and Ukrainians, and I’m so glad that the violence stopped, but at the same time I’m worried about Ukraine’s future. The amount of bad journalism that you can find on the topic online is staggering, but the blog entry on <a href="http://www.economist.com/blogs/easternapproaches">“Eastern Approaches”</a> by The Economist is luckily rather good (as usual), providing a thorough and non-emotional analysis of the whole situation.</p> Put.io – a discussion about piracy on Hacker News 2014-02-04T00:00:00+00:00 http://piotrkazmierczak.com/2014/02/04/put-io-a-discussion-about-piracy-on-hacker-news <p><a href="http://put.io">put.io</a> is a service that lets you download and seed torrents, and also watch the downloaded movie files, in the cloud. An obvious question that such a business model raises is a matter of illegal downloads, and that spawned an interesting discussion on HN. </p> <p>Whenever I read discussions about illegal torrent downloads, I immediately think of three issues. </p> <p>The first one is <a href="http://theoatmeal.com/comics/game_of_thrones">convenience</a> – as a Netflix and <a href="http://hbonordic.com/home">HBO Nordic</a> customer I miss the comfort of watching great quality mp4 files so much that I… became an <a href="https://www.ipredator.se">IPredator</a> customer, and I download the movies/shows I already payed for simply to be able to watch them without my laptop fan spinning like crazy.<sup id="fnref:1"><a href="#fn:1" class="footnote">1</a></sup> </p> <p>The second is the whole issue of what’s <em>right</em>, and how human beings aren’t necessarily entitled to watch the latest episode of “Mad Men” whenever and however they want. I used to support this claim and I still think that the argument of “I can’t get it in any other way so I’m gonna download it illegally using bittorrent” is weak, but I find it very <a href="http://www.marco.org/2012/02/25/right-vs-pragmatic">unpragmatic</a> to simply forbid downloading. I’m also starting to believe that contemporary TV shows and movies are becoming a significant part of modern culture to a degree that it’s just not <em>right</em> to deny access to that part to people who don’t have Netflix in their countries, or can’t afford going to the cinema very often. <!--more--></p> <p>And that brings me to the third issue, which is especially visible in the HN discussion linked above: it’s astonishing how many people (mostly Americans I guess) don’t realize how little digital content is legally available outside the US and the UK. The “if you can afford a modern computer and a fast internet connection, you can afford paying for TV/movies” argument is probably one of the weakest arguments against internet piracy, and is in fact the crux of the whole problem. What MPAA or RIAA don’t acknowledge is that the vast majority of the world’s population simply has no means of paying for a great number of TV shows or movies, because these are unavailable in their respective countries.<sup id="fnref:2"><a href="#fn:2" class="footnote">2</a></sup> People also seem to forget that high-speed internet became very cheap <a href="http://en.wikipedia.org/wiki/List_of_countries_by_number_of_broadband_Internet_subscriptions">to most people of the world</a>, same as computers, but digital goods are still hardly available anywhere outside the US. It’s baffling.<sup id="fnref:3"><a href="#fn:3" class="footnote">3</a></sup></p> <p>So yeah, the whole piracy discussion aside, put.io is actually an interesting service, and I wish it well, hoping it won’t be seized by the Dutch police any time soon. </p> <div class="footnotes"> <ol> <li id="fn:1"> <p>Yeah, both HBO Nordic and Netflix’s streaming hogs my macbook’s CPU incredibly. Both services also regularly crash my Safari.app, either due to bugs in Flash or Silverlight. Also, HBO Nordic’s iPad app is one of the worst things in the entire universe. <a href="#fnref:1" class="reversefootnote">&#8617;</a></p> </li> <li id="fn:2"> <p>Or available after years of delays, with terrible dubbing. <a href="#fnref:2" class="reversefootnote">&#8617;</a></p> </li> <li id="fn:3"> <p>Unless you’re a lawyer. Then I guess it’s no longer baffling but obvious, because the obstacles are clearly not of technical nature. <a href="#fnref:3" class="reversefootnote">&#8617;</a></p> </li> </ol> </div> Winter Sports 2014-01-25T00:00:00+00:00 http://piotrkazmierczak.com/2014/01/25/winter-sports <p>I don’t ski,<sup id="fnref:1"><a href="#fn:1" class="footnote">1</a></sup> and every winter doing any sorts of sports becomes a major problem. This year I’m trying to change that. As anyone will tell you, riding a bike or running in bad weather is simply a matter of attitude. One should just embrace <a href="http://www.velominati.com/the-rules/#9">Rule #9</a> and keep on pushing, but I’ve never been able to do that myself. Every year I promised myself that I won’t be paying any attention to rain or snow, but year after year I failed, bought that monthly bus ticket and locked my bike at home. </p> <p>This year, however, things are different. I just got the lamest Strava badge for 150km ridden in a month: </p> <p><a href="http://www.strava.com/athletes/40808"><img src="/images/winter-sports.png" class="small" /></a></p> <p>but it’s the very first time I got any kind of badge for <em>January</em>. </p> <p>The surprising thing is, once you convince yourself riding in winter is possible, it’s not that bad. Granted, my times on all segments are considerably worse, but I realized that neither rain nor cold bothers me that much.<sup id="fnref:2"><a href="#fn:2" class="footnote">2</a></sup> The trick is to convince yourself that it’s ok to ride in bad weather, and that still comes pretty hard to me, but I found another way – I take an indirect and much longer route home from my office, thus having some extra exercise, because I’m carrying a heavy bag on my back, and riding on a cyclocross bike. But it works, I am finally riding in the winter. </p> <div class="footnotes"> <ol> <li id="fn:1"> <p>Which is kinda wrong. I’ve been living in Norway for almost 4 years now, and only went skiing once. I have a tentative plan of trying snowboard this year, but then again I have this plan <em>every</em> year. <a href="#fnref:1" class="reversefootnote">&#8617;</a></p> </li> <li id="fn:2"> <p>Most of the time winters in Western Norway are very wet, and not that cold, contrary to popular belief. <a href="#fnref:2" class="reversefootnote">&#8617;</a></p> </li> </ol> </div> How I traveled from Norway to Poland for Christmas this year 2013-12-30T00:00:00+00:00 http://piotrkazmierczak.com/2013/12/30/how-i-traveled-from-norway-to-poland-for-christmas-this-year <iframe border="0" scrolling="no" width="78" height="17" allowtransparency="true" frameborder="0" style="margin-bottom: -3px; z-index: 1338; border: 0px; background-color: transparent; overflow: hidden;" src="http://www.instapaper.com/e2?url=http%3A%2F%2Fpiotrkazmierczak.com%2F2013%2F12%2F30%2Fhow-i-traveled-from-norway-to-poland-for-christmas-this-year%2F&amp;title=How+I+traveled+from+Norway+to+Poland+for+Christmas+this+year"></iframe> <p>I traveled by train, and this post is an account of my experiences and a warning for others who might be attempting the same thing. It costed a lot of money, but most importantly, it was a very exhausting and stressful experience. So if you’re reading this and planning on doing the same thing – don’t.</p> <p>First of all: why did I do it? Well, there’s a couple of reasons. First was curiosity – I like trains, and I really wanted to try that kind of long international train travel. Second was finance – plane tickets have a tendency of becoming ridiculously expensive before Christmas, and I had a hard time finding the sort of tickets I wanted (BGO–WAW, POZ–BGO), so I figured that trains can be cheaper. In the end they weren’t, but they weren’t significantly more expensive either, and given that I’ve had <strong>a lot</strong> of flying last month, I decided I’ll give the train a chance.</p> <p>Secondly: how did I do it? Well I checked a couple of possible connections via <a href="http://bahn.de">the best railway connection finder in the world</a>, and I decided to go like this:</p> <ul> <li>morning train from Bergen to Oslo;</li> <li>Oslo to Katrineholm;</li> <li>night train from Katrineholm to Lund;</li> <li>Oresund train accross the sea to Copenhagen;</li> <li>ICE 38 from Copenhagen to Berlin;</li> <li>and a EuroCity from Berlin to Poznań, where I’d meet with my friends and continue to my parents’ place by car.</li> </ul> <p>So that was the plan, and it looked good. In the end I managed to arrive in Poznań on time, but there was a lot of stress and some adventures on the way.</p> <p>I took off from Bergen at 8am. <a href="http://en.wikipedia.org/wiki/Bergen_Line">Bergensbana</a> is probably one of world’s most beautiful train routes, but not in December. The sun doesn’t rise until ~9:40, so you can’t see any of the beautiful fiords of Western Norway.</p> <p><img src="/images/trainChristmas1.jpg" alt="" /></p> <p>By the time it’s daylight, the train reaches <a href="http://en.wikipedia.org/wiki/Hardangervidda">Hardangervidda</a>, and everything’s just <em>white</em>, but you won’t even see that, because the train goes through the snow like a giant plough, and in effect all you see through the windows is a giant white cloud.</p> <p><img src="/images/trainChristmas2.jpg" alt="" /></p> <p>It gets better in Eastern Norway as the train approaches Oslo, but then again the landscape becomes a bit boring there. But apart from all that, the Bergen-Oslo train was one of the best parts of my trip. The train itself is comfy, there are power outlets in 2nd class, and it was on time.</p> <p>So, Oslo S. It’s nice there. I went upstairs to grab a bite, and while I was waiting for my burger the big display that lists all departures showed that my train to Sweden is cancelled. ‘Fantastic’, I thought, ‘but let’s finish the burger first and then think what to do next.’ My immediate thought was to call SAS, book a one-way ticket to WAW and forget about all that train non-sense. This is also the moment of the trip when stress comes into play.</p> <p>See, because when you travel by plane, you can book travel with multiple legs operated by different carriers and have it all on one ticket, so if one part of your trip gets cancelled or delayed, the rest of it gets adjusted somehow and it’s not your problem. With international train travel it’s different. I tried booking everything with Bahn.de, but that’s apparently impossible, so I ended up having tickets bought from 3 companies: <a href="http://nsb.no">NSB</a>, <a href="http://sj.se">SJ</a>, and <a href="http://bahn.de">DB</a>. If I got lost somewhere in Sweden due to delays, I’d lose my German tickets and seat reservations, because it’s not their fault SJ fucked things up. So when I learned that the train to Stockholm is cancelled, I got worried. But I figured it could still all work out fine, because I booked my tickets with generous transfer times.</p> <p>I walked towards platform 19 at Oslo S and jumped on a bus<sup id="fnref:1"><a href="#fn:1" class="footnote">1</a></sup> to Karlstad, where an inter-city train number 58 to Stockholm would await all the passengers. And despite it being a relatively old and crowded bus, it brought us all to Karlstad pretty quickly. Actually there were two buses – a lot of people. We all stood on the platform and waited for the train (which couldn’t have been late, because that where its route started), and then someone announced through the speakers that the train will be delayed, 1 hour. There wasn’t even enough room at the station for all of us to fit. The train arrived after about 30 minutes, so it wasn’t all that bad, and even though the carriages looked very old from outside, they were very comfortable and modern on the inside. The problem was the train number 58 didn’t really move anywhere. We stood in Karlstad for an hour or more, so I was getting worried again that I won’t make my night-train connection in Katrineholm. I had 2 hours allocated for the transfer, but in the end I only spent 20 minutes there because of all the delays. Mind you, there was no snow in Sweden, so I’ve no idea why there were so many problems with SJ.</p> <p>Katrineholm is the Swedish equivalent of <a href="http://en.wikipedia.org/wiki/Koluszki">Koluszki</a> – apparently the only reason to be there is to get off of one train and get on another one – but the night train Stockholm-Malmö arrived on time, and it was way more comfortable than I expected. I had a couple of hours of sleep and got up at 5am to get off in Lund Central and make another train – <a href="http://en.wikipedia.org/wiki/%C3%96resundst%C3%A5g">Øresundståg</a> to Copenhagen. This part of the trip was relatively uneventful, and when I got to Copenhagen, I finally had a decent morning coffee.</p> <p><img src="/images/trainChristmas3.jpg" alt="" /></p> <p>Copenhagen station was pretty busy, and, as always, full of junkies. Anyways, I finished my coffee and went to platform 4, where an ICE 38 train to Hamburg/Berlin arrived and took me to Germany.</p> <p>So here’s the thing about ICE. It’s advertised as high-speed, premium service by DB, and it usually is. I mean, I hope it usually is, because my ICE experience was definitely the worst part of the trip.</p> <p>First off, ICE 38 is nowhere near high-speed. It’s a <em>diesel high-speed train</em>, geddit? It’s diesel, because tracks in southern Denmark aren’t electrified, and because it has to be loaded on a ferry (!) in order to cross the Fehrman belt (from Rodbyhavn to Puttgarden).</p> <p><img src="/images/trainChristmas4.jpg" alt="" /></p> <p>On top of being slow, the ICE 38 was late. It left Copenhagen on time, but was late for the ferry, was 20 minutes late in Hamburg Hbf, and then it simply broke down. It took another 35 minutes before we left for Berlin. The ridiculous thing about ICE is that it was hands-down the most expensive leg of my journey – the ticket from Copenhagen to Berlin costed €140 (in comparison, the NSB ticket from Bergen to Oslo costed 300 NOK (which is ~€35), the SJ ticket from Oslo to Copenhagen costed 800 SEK (which is ~€90), and the last part from Berlin to Poznań was ~€40 (bought that one very late, would have been much cheaper if booked earlier)). For €140 I’d expect much more.</p> <p>I arrived pretty late in Berlin Hbf and only managed to grab a shot of the Christmas tree:</p> <p><img src="/images/trainChristmas5.jpg" alt="" /></p> <p>and had to run to catch the EuroCity train to Gdynia which was already waiting. Didn’t even manage to buy any <a href="http://en.wikipedia.org/wiki/Hanuta">Hanutas</a>, and it’s all your fault, Deutsche Bahn.</p> <p>Now comes the final part: a Polish train operated by <a href="http://en.wikipedia.org/wiki/PKP_Intercity">PKP InterCity</a>. If you ever lived in Poland or known any Polish people, you’d know that PKP has the worst possible reputation in my homeland. So it came as no surprise when I saw the train looked pretty bad from the outside,</p> <p><img src="/images/trainChristmas6.jpg" alt="" /></p> <p>but it came as a <em>major</em> surprise that it was brand new, roomy and comfortable inside. More than that, it was fast, on time, and they served free snacks + coffee/tea/juice in 2nd class. So, yeah, turns out that PKP InterCity was the cheapest and best part of my whole journey, by a fat margin.</p> <p>In the end, I wanted an adventure and had one. I remember I used to enjoy traveling crazy routes with many transfers when I was a teenager in Poland, but doing the same on a European scale is much more annoying and possibly much more expensive (thus also stressful). Also, winter in central Sweden is never warm, and people tend to have more than one piece of hand luggage before Christmas. My one-way plane ticket from POZ to BGO with SAS costed less than a €100, and the flights+transfers will most likely take less than 40 hours.</p> <p>So if you’re thinking of doing what I did, just <em>don’t</em>. Happy New Year.</p> <div class="footnotes"> <ol> <li id="fn:1"> <p>Kudos to NSB staff by the way. When trains get cancelled/delayed in Poland, no one knows anything. NSB handled everything very well and there was a lot of helpful people that explained where the buses are and where you should get off. <a href="#fnref:1" class="reversefootnote">&#8617;</a></p> </li> </ol> </div> The Best, Most Elegant iPhone Games of 2013 2013-12-16T00:00:00+00:00 http://piotrkazmierczak.com/2013/12/16/the-best-most-elegant-iphone-games-of-2013-the-new-yorker <p>For those of you having Christmas holidays, The New Yorker<sup id="fnref:1"><a href="#fn:1" class="footnote">1</a></sup> recommends some “elegant” iOS games. I must say I’m not much of a gamer (except for an occasional <a href="https://en.wikipedia.org/wiki/Counter_strike_source">CS:Source</a>), and I actually never played any games on my iPhone or iPad (except for <a href="http://www.atebits.com/letterpress/">LetterPress</a>, in which I <em>always</em> lose to <a href="http://karolinakrzyzanowska.com/">Karolina</a>), but still I decided to test some of the games mentioned in the article and, frankly, had my mind blown away. Just like Rothman says: it’s unbelievable how beautifully designed and perfectly engineered these small games are. <a href="http://sticketsgame.com/">Stickets</a> is a highly annoying (for the less intelligent among us) and innovative puzzle game (a sort of “twisted” tetris, if you will), <a href="http://simogo.com/games/device6/">Device 6 </a> is a work-of-art adventure game, <a href="http://rymdkapsel.com/">rymdkapsel</a> is one of the best strategy games I’ve ever played (despite its rudimentary, but aesthetically pleasing<sup id="fnref:2"><a href="#fn:2" class="footnote">2</a></sup> graphics), and <a href="http://blekgame.com/">Blek</a> is super smart and has a fun and original game mechanic. So, in other words, each of the games I’ve tested so far is a marvel. </p> <p>What perhaps is the most beautiful aspect of all these games is that they were developed by small, independent studios, sometimes even by one or two persons. Just like with games sold by <a href="https://www.humblebundle.com/">Humble Bundle</a>, I realize I enjoy these independent titles much more than big, blockbuster games these days, which means I’m either getting old, or that I’m seeking what Rothman calls “elegance” in gaming, which big titles seldom provide. </p> <p>Anyways, happy Christmas, and play some games when the family starts getting on your nerves. </p> <div class="footnotes"> <ol> <li id="fn:1"> <p>Mind you: The snobby New Yorker recommends <em>video games</em>. We live in interesting times. <a href="#fnref:1" class="reversefootnote">&#8617;</a></p> </li> <li id="fn:2"> <p>Like an Ikea table. <a href="#fnref:2" class="reversefootnote">&#8617;</a></p> </li> </ol> </div> What AI Should And What It Should Not Be 2013-12-10T00:00:00+00:00 http://piotrkazmierczak.com/2013/12/10/what-ai-should-and-what-it-should-not-be <blockquote> <p>“It depends on what you mean by artificial intelligence.” Douglas Hofstadter is in a grocery store in Bloomington, Indiana, picking out salad ingredients. “If somebody meant by artificial intelligence the attempt to understand the mind, or to create something human-like, they might say—maybe they wouldn’t go this far—but they might say this is some of the only good work that’s ever been done.”</p> </blockquote> <p>via <a href="http://www.theatlantic.com/magazine/archive/2013/11/the-man-who-would-teach-machines-to-think/309529/">The Man Who Would Teach Machines to Think</a>. </p> <p>A long and interesting read about AI’s most brilliant mind – <a href="http://en.wikipedia.org/wiki/Douglas_Hofstadter">Douglas Hofstadter</a> – his <a href="http://www.cogsci.indiana.edu">FARG</a> research group, and the current state of <em>mainstream</em> AI research. </p> <p>I must say I was rather conflicted reading the article. While I think <a href="http://en.wikipedia.org/wiki/Gödel,_Escher,_Bach">GEB</a> is probably the most important book I’ve ever read,<sup id="fnref:1"><a href="#fn:1" class="footnote">1</a></sup> and while Hofstadter is definitely a genius, I’m not entirely sure I agree with discrediting the “small steps” approach present in the article. Coming from a philosophy background into computer science I find that a lot of philosophical research in AI-related fields (like epistemology or logic) is somewhat wishy-washy or superfluous, as is “philosophically-inspired computer science” research.<sup id="fnref:2"><a href="#fn:2" class="footnote">2</a></sup> Then again I realize that the single most harmful threat to my own community of logics-for-AI or multi-agent-systems is creating various formalisms (algorithms, logics, diagrams…) solely because “we can”, and because it’s always better to have more theorems and proofs, even if no one knows what they’re for. The article linked above provides a somewhat fresh and broad perspective on what AI is today, while trying to answer a question of what AI should be. And these are the issues keynote speakers at big AI conferences should be addressing, trying to inspire people and make them contemplate on the big-picture issues; we don’t need another keynote on SAT solving and ILP.<sup id="fnref:3"><a href="#fn:3" class="footnote">3</a></sup></p> <div class="footnotes"> <ol> <li id="fn:1"> <p>Confession: I have never read the whole book. There is a partly interesting story behind it: I started reading it when I was a freshman at <a href="http://mish.uw.edu.pl">MISH</a>, but unfortunately there was only one copy on load at the <a href="http://www.buw.uw.edu.pl/en/">university library</a>, and I could only borrow it for a month. So I would borrow it, read a couple of chapters, return it within a month, wait until it’s available again (someone would always borrow it), and then go back to reading. After some time I got a bit tired of the routine and stopped reading GEB. I bought my own copy when I was finishing my masters, but my knowledge of AI and logic was broader by then, and I found some later chapters of GEB a tad boring, and thus never finished it. Still, GEB was the very main reason I wanted to work in AI. <a href="#fnref:1" class="reversefootnote">&#8617;</a></p> </li> <li id="fn:2"> <p>By “philosophically-inspired” CS I mean researchers in computer science who claim doing philosophically relevant work by attempting to capture certain notions in formal ways. Unfortunately, with very few exceptions, these attempts result in work that is philosophically shallow, and not applicable from an engineering/hard-AI point of view. (I feel I just made a lot of enemies by writing this footnote). <a href="#fnref:2" class="reversefootnote">&#8617;</a></p> </li> <li id="fn:3"> <p>There you go, now I won’t get a post-doc at <a href="http://www.ust.hk/eng/index.htm">HKUST</a>. Shit. <a href="#fnref:3" class="reversefootnote">&#8617;</a></p> </li> </ol> </div> New Zealand 2013-12-08T00:00:00+00:00 http://piotrkazmierczak.com/2013/12/08/new-zealand <p>Last week I came to New Zealand for <a href="http://coin2013-prima.tudelft.nl">COIN@PRIMA workshop</a> and <a href="http://prima2013.otago.ac.nz">PRIMA-13</a> conference. It’s the first time I’m on the southern hemisphere, and I have a couple of observations about New Zealand and the whole Oceania region I’d like to share. </p> <ol> <li> <p>First off, New Zealand is soooper far away from <em>everything</em>. It took me more than 45 hours to get here from Bergen,<sup id="fnref:1"><a href="#fn:1" class="footnote">1</a></sup> and I just talked to a Kiwi friend who told me Wellington is <a href="http://en.wikipedia.org/wiki/Extreme_points_of_Earth#Remoteness">the most remote</a> capital city in the world, being furthest away from any other capital city. The feeling one has here is that while the country seems rather Western (lots of post-British architecture, English as the official language, lots of familiar products in the shops), it’s very exotic. You see Fiji Airways planes at the airports, and there are weird looking trees, birds and plants everywhere. Also, New Zealanders seem to often (implicitly) refer to Australia as the “big world”. Australia’s where the big cities are, it’s where you go to do your post-doc or PhD, and it’s where many people transfer for intercontinental flights. Still, from a European point of view, Australia is the end of the world in many ways – it’s vast, sparsely populated,<sup id="fnref:2"><a href="#fn:2" class="footnote">2</a></sup> and very far away from the rest of the world.<sup id="fnref:3"><a href="#fn:3" class="footnote">3</a></sup> <!--more--></p> </li> <li> <p>New Zealand has remarkably beautiful nature, but… somewhat less impressive for someone coming from Norway. They have fiords and mountains like Norway, but in contrast to Norway they have nice, sandy beaches, and bush forests with much more biodiversity. You could say that most of New Zealand is geographically <em>perfect</em>: it has all the beauty of Norway, and at the same time the climate is so much better. Dunedin, where I am right now, is often described as rainy by the Kiwis I know, where in fact it receives half the amount of rainfall Bergen does. It is also significantly warmer, and it’s in the south of New Zealand’s South Island – North Island is even warmer. So there you go – geographic perfection. If only it was closer to the rest of the world…</p> </li> <li> <p>Traveling to New Zealand from Europe means crossing 12 time zones (UTC+13), which creates a rather weird kind of jetlag, because night and day swap completely. I got used to it much quicker than I thought, and it results in a somewhat optimal work/holiday environment – people in Europe sleep during my day, so I get all the email communication during the night, read my emails in the morning, reply to them, and am not disturbed all day until late evening when they wake up. </p> </li> <li> <p>On a related note, going to the souther hemisphere in December is a bit confusing, but in a very pleasant way. While my friends in Norway, Netherlands and Poland shiver from cold, I was enjoying a fantastic MTB ride in 23°C yesterday. I thought Christmas decorations in the summer looked silly, but I don’t mind anymore. </p> </li> <li> <p>It’s a surprisingly expensive country. Food/restaurant/beer prices are more or less comparable to Amsterdam. </p> </li> <li> <p>Finally, I’ve fallen in love with Dunedin. It seemed a bit dull at first, but after getting to know it better I really enjoy it. It’s compact, has lots of nice restaurants, it’s easy to get out and enjoy the mountains or the beach, and it has the most fantastic <a href="http://piotrandkarolina.wordpress.com/2013/12/04/dunedin-botanic-garden/">botanic garden</a> I’ve ever seen. </p> </li> </ol> <p>So that’s it. I’m writing this post on a Sunday afternoon (NZDT), and I leave on a plane to AKL-PVG-AMS-BGO tomorrow evening. I’m gonna miss you, New Zealand!</p> <p>p.s. For those of you who like photographs, you can take a look at many of the shots I took in New Zealand <a href="http://piotrandkarolina.wordpress.com/category/new-zealand/">here</a>. </p> <div class="footnotes"> <ol> <li id="fn:1"> <p>To be fair, you can get from BGO to DUD in less than that (I just had some unnecessarily long layovers), but it’s way more expensive, and you won’t go below ~35hrs anyway. <a href="#fnref:1" class="reversefootnote">&#8617;</a></p> </li> <li id="fn:2"> <p>Interesting factoid: I didn’t realize until now that Australia only has approximately 23 mln inhabitants. That’s about half the population of Poland, itself not a big country, spread over the area of 7,692,024 km<sup>2</sup>. <a href="#fnref:2" class="reversefootnote">&#8617;</a></p> </li> <li id="fn:3"> <p>And yes, technically the most remote capital is a tie between Wellington and, surprise surprise, Canberra. <a href="#fnref:3" class="reversefootnote">&#8617;</a></p> </li> </ol> </div> Switching Season 2013-08-22T00:00:00+00:00 http://piotrkazmierczak.com/2013/08/22/switching-season-report-2013-edition <blockquote> <p>Every couple years I get the urge to peek out of my Apple-furnished hole and survey the landscape of alternative devices and operating systems. I call this urge switching season […] I figure that the least I can do when the urge to switch strikes me is to share what I’ve learned in the hopes that it saves other people some time.</p> </blockquote> <p>via <a href="https://al3x.net/2013/08/12/switching-season-annual-report-2013.html">Alex Payne — Switching Season Report, 2013 Edition</a>.</p> <p>I have it exactly like Alex Payne – I’ve been living in the Apple-ecosystem for the last 3 years, and I am sorry to admit that the <a href="http://piotrkazmierczak.com/2011/03/17/macbook-pro-after-6-months/">2010 13’’ Macbook Pro</a> is hands-down the best computer I have ever used. It’s fast (especially after having an SSD upgrade last summer), silent, portable, has great keyboard, and its software is boring like hell – it doesn’t crash and I don’t have to tinker with it to make wifi work after resuming from suspend. Despite all that, whenever I see a nice Thinkpad,<sup id="fnref:1"><a href="#fn:1" class="footnote">1</a></sup> I’m immediately browsing <a href="http://allegro.pl">the best second-hand computer store in the world</a> searching for a used X201 or X220 in good condition. It’s partly nostalgia, partly the love of <a href="http://xmonad.org">XMonad</a>, and to a small extent dislike of Apple.<sup id="fnref:2"><a href="#fn:2" class="footnote">2</a></sup> And every time it happens, I’m performing an analysis similar to the one Alex Payne did, arriving at mostly the same conclusions: Android sucks, Linux on the desktop mostly sucks, Windows is not considered due to it not being unix-based, and Apple sucks least on all fronts.</p> <p>It’s all rather sad.</p> <div class="footnotes"> <ol> <li id="fn:1"> <p>A friend just recently bought a used X201 Tablet. He’s running Ubuntu on it and says everything’s fine and dandy. I love the way this machine looks. <a href="#fnref:1" class="reversefootnote">&#8617;</a></p> </li> <li id="fn:2"> <p>However, I am not pro-Dell, pro-HP or pro-Google either. All corporations are evil, <a href="http://www.logophile.org/blog/2013/08/07/whats-wrong-with-the-world/">it’s their duty</a>. <a href="#fnref:2" class="reversefootnote">&#8617;</a></p> </li> </ol> </div> Keith Jarrett Trio 30th Anniversary Tour at De Doelen, Rotterdam 2013-07-08T00:00:00+00:00 http://piotrkazmierczak.com/2013/07/08/keith-jarrett-trio-30th-anniversary-tour-at-de-doelen-rotterdam <p>Last Thursday I went to a Keith Jarrett Trio concert in Rotterdam. It was probably the best jazz concert experience I’ve ever had.</p> <p>The very first “contemporary” jazz<sup id="fnref:1"><a href="#fn:1" class="footnote">1</a></sup> album I’ve listened to was <a href="https://en.wikipedia.org/wiki/Standards_(Jarrett_album)">“Standards, Vol. 1” (ECM 1983)</a>. My dad bought it when I was a teenager and played it to me, because I wanted to know other kinds of jazz than swing and bebop. I didn’t like it at first. It seemed chaotic and difficult to listen to. The melodies I knew were lost somewhere, and I didn’t understand how is this interpretation better than good old big bands. The more I listened to it, though, the more I understood, and the more I liked it. You could perhaps say that Keith Jarrett Trio’s standards taught me most things I know about jazz. I learned a lot about how a jazz trio works, how the bass underlines the chords of the piano, and how the drummer keeps things in control. But most importantly, Keith Jarrett Trio’s records opened my mind to a whole new kind of music: contemporary improvisation.</p> <p>As I was growing up, I kept listening to all kinds of new jazz music. I bought some John Coltrane records and fell in love with hard-bop, only to discover Ornette Coleman some years later and enjoy the hell out of free jazz.<sup id="fnref:2"><a href="#fn:2" class="footnote">2</a></sup> I also kept reading about new artists, buying albums and even developed taste for some sorts of <em>avant-garde</em> music, but when it comes to classic jazz trio consisting of a grand piano, double bass and the drums, I kept coming back to Keith Jarrett’s band and always thought of it as the model trio. Sure, there are many great ones, Uri Caine’s and Marcin Wasilewski’s being among my favorites, but the level of mastery achieved by KJT seems unachievable by anyone else.</p> <p>When the concert ended, I realized that writing its “review” won’t be an easy task. Reviewing KJT’s concert is like talking about Velázquez’s paintings. Of course you enjoy them, otherwise you’re an idiot, and of course they’re perfect — everyone knows it and there’s no point in restating the obvious. The only 2 things that can possibly go wrong when it comes to KJT:</p> <ol> <li> <p>The condition of their leader, who, be it for mood- or health-related reasons, can sometimes underperform.<sup id="fnref:3"><a href="#fn:3" class="footnote">3</a></sup></p> </li> <li> <p>The sound engineers can potentially screw things up.</p> </li> </ol> <p>Last Thursday night it was definitely the latter, but I’ll get back to that in a minute. Let me first explain why would one want to “review” such an event.</p> <p>While I was listening to the concert, I realized it is rather hard to put in words why this particular trio is so awesome, and not, for example, Brad Mehldau Trio. “How is it better?”, I asked myself and tried to come up with an answer in my head.</p> <p>KJT is the very, very best jazz trio in existence primarily because of the novelty of interpretations. What I took for chaos and even noise as a teenager is indeed a number of sublime improvisations. Keith Jarrett, being a brilliant fucking pianist, wraps the themes and melodies we all know so well inside his twisted, complex and melodic improvisations like no one else. During Thursday’s performance it happened so many times that a known theme emerged out of nowhere, and the audience was left stunned: “Where did that come from? How the hell did he do that?” All jazz pianists improvise on melodies from <a href="http://en.wikipedia.org/wiki/Great_American_Songbook">The Great American Songbook</a>, but neither gets even close to Jarrett’s creativity and sensitivity.</p> <p>Secondly, KJT’s perfection comes from the level of connection between musicians that is hard to match. Some critics argue that Jarrett, Peacock and DeJohnette have been playing standards for too long<sup id="fnref:4"><a href="#fn:4" class="footnote">4</a></sup>, and that is somewhat true, but then again by doing so they have reached an absolutely perfect connection. No other trio has this.</p> <p>Thirdly, Keith Jarrett Trio is one of the few jazz bands (if not the only one) to be able to easily move between different types of jazz aesthetics in terms of improvisation style. They are equally good at traditional, straight-ahead and free jazz, and they are even able to mix these together during one concert.</p> <p>And finally, as you might have expected, there is the way they complement each other. Keith Jarrett plays almost like a classical pianist, and in fact many of his solos resemble something of a classical piano concert. His inclinations towards classical music are the signature of his sound.<sup id="fnref:5"><a href="#fn:5" class="footnote">5</a></sup> Then there is Gary Peacock on the bass, who’s role here is to do much more than your usual bass player does. Peacock is highly melodious, and his solos are very lyrical, especially for a bass player. Both Jarrett and Peacock are very <em>soft</em> and that’s why they need the big guy on the drums — Jack DeJohnette — who’s definitely the most aggressive element of the trio. DeJohnette’s style is still rather withdrawn compared to other drummers, but he’s the one who adds that chili pepper to the sauce.</p> <p>If I were to describe their style with one expression, I’d say they’re sound is that of subtle, gentle virtuosity. That’s what they are, and that is why they are so exceptionally good.</p> <p>Back to the concert: it was much longer than I expected, it lasted for more than 2 hours, and there were 3 encores. Jarrett seemed to be in great shape (given his age and health problems), and even though the drums were much too loud during the first part of the concert, sound engineers fixed the issue after the break and the second part was blissful. It was, as I mentioned in the first line of this post, the best jazz concert I’ve been to (Ornette Coleman Quartet I heard in Warsaw in the summer of 2007 is the 2nd best now).</p> <p><em>As a final note, I’d like to thank my girlfriend <a href="http://karolinakrzyzanowska.com">Karolina</a> who got the tickets and invited me to the concert. A fantastic experience I will probably never forget. Thank you.</em></p> <div class="footnotes"> <ol> <li id="fn:1"> <p>Sorry for the quotation marks, but does anyone really know what is contemporary jazz? <a href="#fnref:1" class="reversefootnote">&#8617;</a></p> </li> <li id="fn:2"> <p>Speaking of discovering artists, the funny thing is I got my hands on Miles Davis’ albums pretty late, and for whatever reason he never got the love he apparently deserves from me. I adore “Bitches Brew”, but not much more. (Weird). <a href="#fnref:2" class="reversefootnote">&#8617;</a></p> </li> <li id="fn:3"> <p>Calling Jarrett moody is actually an understatement. Go google him and you’ll see plenty of stories about his, hmm, erratic behavior. <a href="#fnref:3" class="reversefootnote">&#8617;</a></p> </li> <li id="fn:4"> <p>It is in fact their 30th anniversary tour! <a href="#fnref:4" class="reversefootnote">&#8617;</a></p> </li> <li id="fn:5"> <p>That is even more visible in his great solo concerts, the best example being <a href="https://en.wikipedia.org/wiki/Vienna_Concert">The Vienna Concert</a>. <a href="#fnref:5" class="reversefootnote">&#8617;</a></p> </li> </ol> </div> On Racing Bergen-Voss 2013-07-01T21:06:00+00:00 http://piotrkazmierczak.com/2013/07/01/racing-bergen-voss <p><img src="/images/bergen-voss-picture.jpg" alt="" /></p> <p>That’s me riding the final climb of Bergen-Voss 2013 race, the famous road from Granvin to Voss and its hairpins around <a href="http://no.wikipedia.org/wiki/Skjervefossen">Skjervsfossen</a>. It was the second time I did this race, and although I had a better time than last year, I’m still at the very end of the “top 4000” list. </p> <p>It’s a relatively easy, amateur race. The distance is about 165 km, but there is some climbing on the way (about 1800m), with 3 distinct climbs, one of which is rather serious:</p> <p><a href="/images/bergen-voss-map.png"><img src="/images/bergen-voss-map.png" /></a></p> <p>There are two types of reactions I get when I tell people I do Bergen-Voss:</p> <ol> <li>‘Ooh, you must be amazingly fit/strong! I would <em>never</em> be able to even finish such a race!’</li> <li>‘Why the hell would you do such a thing?’</li> </ol> <p>Ad 1): You’re wrong. Any healthy person can ride 165 km in under 10 hours. Yes, it requires some training and yes, it’s best if you have a racing bike (although there are people on mountain bikes, cyclocross and even city bikes too), but no, it does not require superhuman strength, endurance or spending 30000 NOK on gear. You can just do it, if you really want to. Remember <a href="http://www.velominati.com/the-rules/#5">Rule 5</a> and <a href="http://www.velominati.com/the-rules/#6">Rule 6</a>, and you’re good.</p> <p>Ad 2): Because I can, and because my job require little to no physical effort from me. I’m an academic, and this means (among many other things) that if I don’t teach, I don’t even have to leave my house. As a kid I was very bad at sports (I’m the classic case of a football player who plays for the team that picks last), and never really liked any physical activity, but these days, at the age of 28, I feel restless if I don’t bike or run a couple of days a week. <a href="http://karolinakrzyzanowska.com">Karolina</a> has the same.</p> <p>Also, when it comes to Bergen-Voss in particular, I do it because it’s an <em>amazing</em> experience. The route takes you through the mountains, valleys, and along the fantastic Hardangerfjord. Breath-taking nature, people ringing cowbells on the streets, and great atmosphere all the way. I wouldn’t regret it even if I came last.</p> <p>Next June I will probably no longer be living in Norway, and thus I probably won’t take part in Bergen-Voss again. You should, though. All you need is a roadworthy bike and some months of training. Riding all the way to Voss is not necessary, but doing a couple of 100km-long trips before the race is a good preparation. <a href="https://www.youtube.com/watch?v=2CTPLUcQAjk">Get on your bike and ride!</a></p> Coursera Improvisation Course (with Gary Burton) 2013-05-09T20:04:00+00:00 http://piotrkazmierczak.com/2013/05/09/coursera-improvisation-course-with-gary-burton <p>Today is the deadline for Assignment 1 of Coursera’s <a href="https://www.coursera.org/course/improvisation">Jazz Improvisation Course</a>, which I’m taking. I was about to drop out, because my violin technique isn’t good enough, and my music theory is rusty at best, but since it’s <a href="http://en.wikipedia.org/wiki/Ascension_Day">a public holiday today</a> here in Norway, I had a whole day to spend on playing. Here’s what I came up with:</p> <iframe width="100%" height="166" scrolling="no" frameborder="no" src="https://w.soundcloud.com/player/?url=http%3A%2F%2Fapi.soundcloud.com%2Ftracks%2F91446427"></iframe> <p>Yes, it’s faaar from perfect, and I missed some notes in the bridge, but I can’t stand recording yet another take, so this is the one I’m submitting. Also, I’m pretty satisfied with the theme that I open the solo with.<sup id="fnref:1"><a href="#fn:1" class="footnote">1</a></sup></p> <p>And by the way, what Coursera does here is absolutely magnificent. It enables me (and thousands of others) to do something I always wanted and never believed to be possible: to study jazz improvisation with no other than <a href="http://en.wikipedia.org/wiki/Gary_Burton">Gary Burton</a>, the greatest vibraphonist alive, and one the greatest improvisers in the world. And it’s for free. So then even if he kicks me out, I’ll have something to tell my grandchildren about.</p> <div class="footnotes"> <ol> <li id="fn:1"> <p>What I’m also unsatisfied with is the quality of the record. This is due to a couple of reasons. First of all, I’m using a 2010 MacbookPro, which only has one, combined input-output audio socket. Playing on <a href="http://no.yamaha.com/no/products/musical-instruments/strings/silentviolins/sv_200/?mode=model">a silent instrument</a> this means that I can either hear myself playing, or the trio, but not both. So then the way I do it is that I play the trio in iTunes on the laptop, and then independently record my violin through a NAD C715 stereo. This is the reason why the timing is sometimes a tad off – I simply can’t always hear the trio clearly (laptop speakers aren’t loud enough). I’ll buy an external soundcard tomorrow, so hopefully there won’t be any problems with the next recording. Secondly, I’m using GarageBand to mix the tracks, and it’s either poorly designed software, or I’m a dumb user. Aligning the tracks (there’s a delay of about 3-4 seconds between when I press “record” and when recording starts on my NAD…) took me 30 minutes or more. Oh and finally, the strings I’m currently using (Dominant) also contribute to unpleasant sound. <a href="#fnref:1" class="reversefootnote">&#8617;</a></p> </li> </ol> </div> What Happens When You Live Abroad 2013-04-18T16:18:00+00:00 http://piotrkazmierczak.com/2013/04/18/what-happens-when-you-live-abroad <blockquote> <p>The anxiousness that was once concentrated on how you’re going to make new friends, adjust, and master the nuances of the language has become the repeated question “What am I missing?”</p> </blockquote> <p>via <a href="http://thoughtcatalog.com/2012/what-happens-when-you-live-abroad/">What Happens When You Live Abroad</a>.</p> <p>Good post, good observations. As an ex-pat since around 2008 I’d like to add a few of my own.</p> <p>Firstly, something weird happens to my “national identity” sense. I feel Polish of course, and that means I’m interested in what happens in Poland, I read Polish <a href="http://wyborcza.pl" title="Im nie jest wszystko jedno!">newspapers</a> online, and I’m very much interested in Polish culture<sup id="fnref:1"><a href="#fn:1" class="footnote">1</a></sup>, but I no longer use Polish on a daily basis<sup id="fnref:2"><a href="#fn:2" class="footnote">2</a></sup>, I no longer feel that the political situation of my home country affects me in any way, and I really don’t see a situation in which I’d decide to move back to Poland. At the same time I hardly feel Norwegian, and I don’t really think I’d ever become one even if I lived here for 30 years. So I feel somewhat <em>stateless</em>. </p> <p>Secondly, I think the whole “mastering a local language” thing is a myth. Yes, when all the signs suddenly become meaningless and you can’t say if what you’re looking at in the grocery store is actually butter or margarine, it’s an obstacle of sorts. Most foreigners I know here in Norway attended courses of Norwegian as a foreign language (at least to some degree), but of all of them only <em>one</em> speaks Norwegian fluently (and it’s a somewhat special case, because this person wanted to stay in Norway permanently since he got here). The rest is able to have a basic conversation about how the weather is bad and how beer is expensive, but that’s it. Interestingly, it seems the amount of work put into studying matters little. While it’s obvious that I can’t speak Norwegian (finished only level 1, with a strong D), all my other friends that finished all the possible levels of the course still don’t speak the language (even if they’re German). Same goes for <a href="http://karolinakrzyzanowska.com">Karolina</a> – she completed all the levels of Dutch, but she still doesn’t speak it. We all use English because it’s so natural, convenient and easy. And there’s always someone around who doesn’t understand Norwegian at all, so what’s the point? That’s why I find the observation made by Thought Catalog so spot on: ex-pats gather in communities regardless of their origin. I hang out mostly with Norwegians, but at the same time with folks from India, Canada, Germany, The Netherlands, Slovakia, Ukraine, Russia, South Africa, Algeria and China<sup id="fnref:3"><a href="#fn:3" class="footnote">3</a></sup>, and we all speak English fluently. Perhaps this is what happens in Scandinavia simply because the average level of English fluency is so high, and I guess this wouldn’t happen in France, Spain, Italy or Germany (or any Eastern European country for that matter). Then again I’d still expect ex-pats from many different countries hanging out together, regardless of their country of origin. </p> <p>Finally, I wonder how different my experiences would be had I not stayed in academia. Academic environments are naturally diverse when it comes to nationalities, and unfortunately most contracts are short and tied to some grant money. This means most people won’t consider investing time and/or money in learning a new language. I’d expect this to look differently in the so-called industry. </p> <div class="footnotes"> <ol> <li id="fn:1"> <p>It is somehow sad, that whereas reading news, listening to the radio, buying CDs and books from Poland is fairly easy whilst abroad, watching new Polish movies is <em>very</em> hard. Foreign cinemas naturally seldom show them, and online services either don’t allow foreign IPs or don’t have new films. Since <a href="http://en.wikipedia.org/wiki/Polish_diaspora">there is approximately 20 mln Poles abroad</a>, I’d consider creating a paid online service a reasonable business idea. SV people, get it done (and cut me in for 30% if it works). <a href="#fnref:1" class="reversefootnote">&#8617;</a></p> </li> <li id="fn:2"> <p>I skype/facetime with <a href="http://karolinakrzyzanowska.com">Karolina</a> ~daily, that’s right, but given that she also uses much more English than Polish, our mother tongue is becoming a scary pidgin-like talk. Mind you, this is what happens after ~4 years of continuously living abroad in the age of Internet. It’s frightening to think what it was like two decades ago. <a href="#fnref:2" class="reversefootnote">&#8617;</a></p> </li> <li id="fn:3"> <p>There is of course something special about the Chinese: they <em>always</em> stick together. But then again, I suspect it’s simply because English is so hard for them. <a href="#fnref:3" class="reversefootnote">&#8617;</a></p> </li> </ol> </div> Debt 2013-02-02T20:47:00+00:00 http://piotrkazmierczak.com/2013/02/02/debt <p>David Graeber’s <em>Debt</em> is one of the best books I have read in my life.</p> <p>It is a thorough historical and anthropological investigation into the nature of money and, <em>nomen omen</em>, debt. Across about 400 pages Graeber analyzes all aspects of these: moral, economical and philosophical. He lays out a fresh and somewhat bold view that challenges classical economic theories, namely that debt has been the true essence of human economies for at least 5000 years now, and provides lots of compelling evidence to support this claim. His original analysis is very thought-provoking, and makes the reader wonder about the very foundations of our society, global economy, and certain aspects of human nature (like greed and love).</p> <p>To a reader unfamiliar with economics and anthropology (such as myself), Graeber’s book is also an eye-opener when it comes to explaining <em>how the world works</em>, and even more, <em>how it has been working</em> for the last couple of thousands of years. The author is a true erudite in how he manages to show numerous connections between religion, economy, history and human nature. And through last chapters, where he relates his historical presentation to present day and the financial crisis of 2007–2008, it is also a bit scary to read (again, to a poorly educated person such as myself) about how global economy ‘works’.</p> <p>I recommend this book to anyone interested in economics and history of money and markets, but also to those who’d like to read about the history of the world from a different perspective.</p> Gazelle 2013-01-03T16:58:00+00:00 http://piotrkazmierczak.com/2013/01/03/gazelle <p><img src="/images/gazelle.jpg" alt="" /></p> <p>I started adhering to <a href="http://www.velominati.com/the-rules/#12">Rule 12</a> and bought another bike. This time it’s a classic Dutch Gazelle from the 70s. Barely working drum brakes, beautiful brown paint-job with extra rust and a weight of <em>circa</em> 16 tons, but nothing beats the comfort of an <em>opafiets</em>. And you can get it all for only €40 (plus €20 in repairs) from certain philosophers in Groningen!</p> Previewing LaTeX symbols without preview-latex 2012-12-27T12:16:00+00:00 http://piotrkazmierczak.com/2012/12/27/previewing-latex-symbols-without-preview-latex <p>This blog’s most popular post is the <a href="http://piotrkazmierczak.com/2010/05/13/emacs-as-the-ultimate-latex-editor/" title="Emacs as the Ultimate LaTeX Editor">Emacs howto entry</a>, so I thought I’d share one more LaTeX-related tip for all your Emacs needs. Besides the traditional <code>preview-latex</code> way of generating TeX formulas inside Emacs buffer, there’s a faster and neater way to do this using Emacs’ unicode support. My friends Erik Parmann and Pål Drange made a simple <a href="https://bitbucket.org/mortiferus/latex-pretty-symbols.el">package</a> that turns many math symbols and Greek letters commands into corresponding unicode characters. Here’s a sample of how this looks:</p> <p><a href="/images/emacs-pretty-latex.png"><img class="small" src="/images/emacs-pretty-latex.png" /></a></p> <p>If you’re running Emacs 24, you can get the package from <a href="http://melpa.milkbox.net">MELPA</a> repository. Otherwise you can get it from <a href="https://bitbucket.org/mortiferus/latex-pretty-symbols.el">Erik’s bitbucket</a>, put it somewhere in your load path and load it with <code>(require 'latex-pretty-symbols)</code>. There, happy TeXing!</p> <p>(also, you can make similar tricks with <a href="https://github.com/haskell/haskell-mode">Haskell mode</a> and have all your lambdas displayed properly).</p> Blogging is hard 2012-11-06T00:48:00+00:00 http://piotrkazmierczak.com/2012/11/06/blogging-is-hard <iframe border="0" scrolling="no" width="78" height="17" allowtransparency="true" frameborder="0" style="margin-bottom: -3px; z-index: 1338; border: 0px; background-color: transparent; overflow: hidden;" src="http://www.instapaper.com/e2?url=http%3A%2F%2Fpiotrkazmierczak.com%2F2012%2F11%2F06%2Fblogging-is-hard%2F&amp;title=Blogging+is+hard"></iframe> <p>I started blogging quite a long time ago, in 2006. The first platform I used was Polish <a href="http://jogger.pl">Jogger</a> — a blogging engine centered around Jabber (aka <a href="http://xmpp.org">XMPP</a>) protocol. It was very cool (and unique) at the time, you could interact with your blog via IM (posting new entries, replying to comments), and it gathered a specific crowd of open-source/linux/free software enthusiasts which made for a nice community. My blog at the time was called <em>Das Nichts</em><sup id="fnref:1"><a href="#fn:1" class="footnote">1</a></sup>, and it was like most other blogs at that time — about <strong>everything</strong>. It was written in Polish and my audience were mostly friends from high school and college. <em>Das Nichts</em> later moved to Wordpress, and finally evolved into a <a href="http://dasnichts.tumblr.com">tumblr</a>, but in 2009 I stopped writing it, considering it too childish and wanting to switch to English. </p> <p>I did. I created <em>Sound and Complete</em>, a blog in English, and hosted it on <a href="http://wordpress.com">Wordpress.com</a>. I tried writing about more technical subjects (linux and free software and the like), but quickly realized there’s a ton and a half technical blogs on the internet written by people closer to interesting communities (in my case free software communities), with deeper knowledge, and more engaged into certain projects. Obviously I could have become one of those people, but I was just about to start a PhD in logic, so my efforts concentrated more on modal logic, model theory, recursion theory etc. I figured that perhaps I could write about academic subjects, but I ran into trouble. With academic subjects (and logic/mathematics especially) you can either write introductory posts about things you know/you’re learned (but that’s a bit boring and not really something people want to read; modal logic is not as exciting as quantum physics, so it’s hard to become Brian Cox), or you can try publishing posts about details of your work. The latter is definitely more tempting, but in practice not really feasible, because it requires looong texts, lots of technicalities and it’s best suited for academic papers. So I ended up writing about everything again, just like in college. And that’s in principle ok, as long as there aren’t as many social network users as there are today. </p> <p>The other day I took a good look at my blog’s archive and realized that out of a ~140 posts published here, about 15 is of decent quality.<sup id="fnref:2"><a href="#fn:2" class="footnote">2</a></sup> The rest are either links to other material on the web or personal entries that would work much better as Facebook updates or tweets. Linking to other sites is, as Guy English writes in <a href="http://the-magazine.org/1/fireballed">the 1st issue of The Magazine</a>, specialty of a certain well-known blog, and imitating it isn’t easy. <a href="http://marco.org">Some</a> <a href="http://thebrooksreview.net">tech</a> <a href="http://parislemon.com">bloggers</a> find their own formulas, but I wasn’t able find mine. I’ve tried many platforms, from WordPress through Posterous, <a href="http://octopress.org">Octopress</a> and Tumblr to Squarespace, and even <a href="http://medium.com">Medium</a><sup id="fnref:3"><a href="#fn:3" class="footnote">3</a></sup> or <a href="http://branch.com">Branch</a>, but it didn’t really matter — my blogging was never not good enough. </p> <p>I once asked my friend <a href="http://github.com/ryszard">Szopa</a> why he doesn’t blog anymore<sup id="fnref:4"><a href="#fn:4" class="footnote">4</a></sup>, and then he said something I remember very well — he said he doesn’t blog, because he wouldn’t read his own blog. Whereas I used to treat my own blogging very lightly for many years, I’ve recently tried looking at it the way I look at texts in The New Yorker, The Magazine<sup id="fnref:5"><a href="#fn:5" class="footnote">5</a></sup>, The Economist, or simply the harsh<sup id="fnref:6"><a href="#fn:6" class="footnote">6</a></sup> way I review academic papers. Szopa was right — I wouldn’t read my own blog if it wasn’t my own. </p> <p>This is not to say there were never any good entries here. No, <a href="http://piotrkazmierczak.com/2011/01/09/in-defense-of-the-phd/">some of them</a> I actually find insightful, others are <a href="http://piotrkazmierczak.com/2010/05/13/emacs-as-the-ultimate-latex-editor/">helpful</a>, and others <a href="http://piotrkazmierczak.com/2012/01/28/new-violin/">interesting even though personal</a>. That’s why I’m keeping them here, but there seldom will be any more posts, unless I really have something to say (i.e. more likely there’ll be something long-form). You might be wondering why wouldn’t I simply leave the blog as it is. Well, my website used Squarespace lately, and Squarespace is a paid service. That’s why I decided to simply move my homepage as a static html file, put it in a Github repository and leave some of the posts I find valuable here as static html as well. That’s not to say I won’t write anymore, but it does mean posts will appear only a couple of times a year. </p> <div class="footnotes"> <ol> <li id="fn:1"> <p>That’s due to my favorite TA in our Ontology class in the Institute of Philosophy, who’d notoriously ridicule Heidegger’s “das Nichts nichtet” quote (out of context of course). <a href="#fnref:1" class="reversefootnote">&#8617;</a></p> </li> <li id="fn:2"> <p>I found some more after trying to be really indulgent with myself. <a href="#fnref:2" class="reversefootnote">&#8617;</a></p> </li> <li id="fn:3"> <p>Even though still not fully open to the public, Medium seems like the most attractive and innovative publishing platform these days. I’m really looking forward to see it launch. <a href="#fnref:3" class="reversefootnote">&#8617;</a></p> </li> <li id="fn:4"> <p>He used to have 3 blogs if I correctly recall. <a href="#fnref:4" class="reversefootnote">&#8617;</a></p> </li> <li id="fn:5"> <p><a href="http://the-magazine.org">The Magazine</a> is actually something that deserves a blog post (<em>sic!</em>), because it’s a new type of a publication: a periodical distributed solely via Apple’s App Store for iOS Newsstand. Featuring texts by known tech bloggers it attempts to become a high-quality publication comparable to good old weekly magazines. Personally I applaud the idea, subscribe and read, but find that even though the texts are of relatively high quality, they’re nowhere near the quality of The Economist, The New Yorker or even The Atlantic. I am the worst kind of a critic, obviously, because I would never be able to produce anything even close to what <a href="http://arstechnica.com/author/john-siracusa/">John Siracusa</a> or <a href="http://www.marco.org">Marco Arment</a> write. <a href="#fnref:5" class="reversefootnote">&#8617;</a></p> </li> <li id="fn:6"> <p>Not really. <a href="#fnref:6" class="reversefootnote">&#8617;</a></p> </li> </ol> </div> Traveling 2012-09-16T20:35:00+00:00 http://piotrkazmierczak.com/2012/09/16/traveling <iframe border="0" scrolling="no" width="78" height="17" allowtransparency="true" frameborder="0" style="margin-bottom: -3px; z-index: 1338; border: 0px; background-color: transparent; overflow: hidden;" src="http://www.instapaper.com/e2?url=http%3A%2F%2Fpiotrkazmierczak.com%2F2012%2F09%2F16%2Ftraveling%2F&amp;title=Traveling"></iframe> <p>I travel <strong>a lot</strong>, and I mean a lot not only for a PhD student. Yes, I do travel to conferences, workshops, seminars and summer schools, but apart from that I visit family in Poland and friends in The Netherlands, which means I’m on an international flight at least once a month. It made me reflect on how I travel, how I feel about traveling and how many of my traveling habits changed.</p> <p>First of all, I don’t like traveling by plane. As most people, I hate security checks, the hassle it takes to get to/from many airports (taking trains, buses, taxis…), baggage allowances that most people abuse (it’s been a while since I was able to actually put any of my stuff in the overhead compartment), crowded gate entries, etc. I take high-speed trains whenever possible, but I always have to take a plane in order to get out of Bergen, since taking a train through Oslo and Sweden is expensive and very inefficient.<sup id="fnref:1"><a href="#fn:1" class="footnote">1</a></sup></p> <p>Then there’s the problem of language. As exciting as it is to be in a foreign country, after a number of trips the fact that you don’t know the local language and that not everyone speaks (fluent) English becomes annoying. Believe it or not, but I went to UK for the first time last weekend, and one of the best things I liked about it was that when I got off the train at Paddington, I approached a cab, told the driver “109 Camden Road!”, and we went. I didn’t need to repeat what I just said, didn’t need to have it written down somewhere, she simply understood. Brilliant.<sup id="fnref:2"><a href="#fn:2" class="footnote">2</a></sup></p> <p>And finally, these days I seldom take pleasure in sight-seeing. Traveling became a <em>standard</em> part of my life, and travel quite often means work. Many people think that visiting cool places for conferences, workshops or seminars is nothing but partying, but they couldn’t be more wrong. To me, such trips are always an opportunity to do <strong>more</strong> work, because I can meet my coauthors, discuss things that were unclear in emails, sketch plans for new projects, meet new people, comment on their papers and discuss them… All of this means that at the end of the day the last thing you want to do is to take the camera and a Lonely Planet guide, and be a tourist. The fact that your friends and family <em>expect</em> you to actually do that only makes things worse.<sup id="fnref:3"><a href="#fn:3" class="footnote">3</a></sup></p> <p>But don’t get me wrong, I’m not such a malcontent as it may seem after reading the first paragraphs. I would never want to change my job, and frequent travel is one of the reasons for that.</p> <p>There are of course positive aspects of frequent traveling. For example, I pack quickly and efficiently. Whenever I can I don’t take more than a <a href="http://missionworkshop.com/products/bags/backpacks/roll_top/medium_rambler.php">backpack</a>, and if I need a (small) suitcase, it takes me little time to pack it and I seldom forget to take anything important. Frequent flying means frequent flyer status, so I can skip queues and take more baggage for free if I need to, as long as I fly with SkyTeam.<sup id="fnref:4"><a href="#fn:4" class="footnote">4</a></sup></p> <p>Frequent traveling also means it’s very hard to get lost. Or actually, you do get lost every now and then, but you don’t panic, and you’ll find your way rather sooner than later. I recently realized that I became very relaxed about this, and I find myself often without a map in the middle of the night somewhere in a city I’ve never been to before. However weird it may sound, I kind of like these situations, but they would never happen a couple of years ago.</p> <p>Also, when I said I’m not doing any sight-seeing, it wasn’t exactly true. I very often skip touristy sights/places, at the same time trying to blend into the place I’m visiting as much as I can. This means I very often use <a href="http://airbnb.com">AirBnB</a> instead of hotels, to see how the locals live, and that I quite often pick places not very close to conference venues, to travel by metro/tram/bus with commuters in the morning, to see how their lives look like. I may not see all the old churches, monuments and museums, but I remember a lot of experiences from those trips.</p> <p>And finally, one thing that I consistently do ever since my earliest travels: I send postcards. I send around 10 on average, and I hope it’s as much fun receiving as it is buying, writing and sending them.</p> <p>Summing it all up, traveling <em>per se</em> is no longer exciting to me, or at least it isn’t as exciting as it used to be. A couple of years ago, every aspect of travel excited me a lot, from slightly different road signs, through different products available in grocery stores, different currency, different language, to different architecture, customs and culture. Now a lot of it is gone. There are still many aspects of traveling that I consider fun, but the sole process of traveling I no longer do. And that’s somewhat surprising.</p> <div class="footnotes"> <ol> <li id="fn:1"> <p>It can be <strong>very</strong> fun, though. A friend of mine came to <a href="http://infomedia.uib.no/deon2012">DEON</a> conference we organized here from Italy by train. Took him somewhere around 40 hours one way, but he said it was a great adventure. <a href="#fnref:1" class="reversefootnote">&#8617;</a></p> </li> <li id="fn:2"> <p>Actually, there’s one more funny thing about foreign languages, as my girlfriend Karolina pointed out today. When you travel a lot, you no longer care that you don’t know the local language. You know you can always get by with just English, and most of the time you’re right in thinking that way. Sure, there are places where English isn’t widely spoken, and it’s always nice to learn at least some basic phrases in a local language, but fluency in English will really get you far. Even in those places when it’s not widely spoken. <a href="#fnref:2" class="reversefootnote">&#8617;</a></p> </li> <li id="fn:3"> <p>Point of inquiry: is it my <em>duty</em> to learn something about the place I’m visiting, take pictures, visit museums and churches and all that? Many people would really love to travel as much as I do, but they don’t have either time or money, and perhaps it’s just my laziness that I should fight? Food for thought. <a href="#fnref:3" class="reversefootnote">&#8617;</a></p> </li> <li id="fn:4"> <p>Actually, even though this may come out as a free advertisement, I very much recommend SkyTeam airlines, especially <a href="http://www.klm.com">KLM</a>. <a href="#fnref:4" class="reversefootnote">&#8617;</a></p> </li> </ol> </div> How the iPad ruins my travel experience 2012-08-25T18:40:00+00:00 http://piotrkazmierczak.com/2012/08/25/how-the-ipad-ruins-my-travel-experience <p>I travel a lot, be it for work or pleasure, and one of the things I particularly enjoy when I’m transferring at my favorite Schiphol airport is visiting bookstores. I browse magazines, bestsellers and non-fiction, and usually buy an issue of The Economist, The New Yorker or a book. Or actually, I used to buy.</p> <p>Ever since I have the iPad<sup id="fnref:1"><a href="#fn:1" class="footnote">1</a></sup>, I stopped visiting bookstores. I no longer buy The Economist or The New Yorker, because <em>there’s an app for that</em>. Well, not only there are apps, but magazines are usually much cheaper if bought in “the newsstand” rather than in printed form. I no longer buy books there either, because I prefer using the Kindle app for reading while traveling (cuts the weight of the bag significantly). You might then say that there are no cons to this situation, and it is indeed a typical first world problem, but there are two observations I made today that I’d like to share here.</p> <p>First off, I realized I don’t really read magazines as much as I used to, even though I have them cheaper, everywhere, and whichever I like. It’s a typical paradox of oversupply, so often noticed by music enthusiasts — back in the age of CDs (especially when they were expensive and not so easily available) we used to listen to music more carefully, knowing each album’s track titles, reading booklets that were inserted into CD cases, etc. Nowadays if I want an album, I can click “buy” in the iTunes store, and I have it immediately, but I don’t spend as much time on each record as I used to.<sup id="fnref:2"><a href="#fn:2" class="footnote">2</a></sup> It’s the same with magazines on my iPad. I subscribe to a couple of them, but don’t have time to read every issue. Some issues I miss completely, unaware that they were downloaded automatically. Some weeks ago the situation was a tad better, because Polish magazines weren’t available in the App Store, but now I can get Gazeta Wyborcza, Polityka and even Uważam Rze there as well, so I don’t buy any paper issues of anything anymore, and, paradoxically, read less magazines.</p> <p>The second observation is that I truly miss walking around bookstores, browsing, looking at covers of books, reading abstracts and reviews on the back, and buying. It’s probably just an illusion, but I think I used to read more before I actually had the iPad. I might be reading more blog entries and things I save with <a href="http://www.instapaper.com">Instapaper</a>, but less magazines. And I actually don’t like reading books on the iPad, because of reflections, because the Kindle App’s poor design, and because they always ask me to switch it off for <em>taxi, takeoff and landing</em>. And I won’t buy an ebook reader, because the iPad is more useful for me in other areas, such as emailing, web browsing, and, most importantly, reading and reviewing academic papers.<sup id="fnref:3"><a href="#fn:3" class="footnote">3</a></sup></p> <p>So while thinking about all that and strolling around Schiphol this fine afternoon, I stepped into a bookstore and spent some time there. How lovely it was! I could browse the latest issue of The Economist (pointless, since I have it on my iPad, but still fun), laugh silently at people picking up Very Bad Books from bookshelfs, and finally wandering around the “non-fiction” section, and picking up two titles: <a href="http://www.guardian.co.uk/books/2011/nov/16/quantum-universe-cox-forshaw-review">one</a> that is supposed to teach me about modern(-ish) physics once again (never too much of that, quantum mechanics <strong>really</strong> is twisted), and <a href="http://en.wikipedia.org/wiki/The_Magic_of_Reality">another one</a><sup id="fnref:4"><a href="#fn:4" class="footnote">4</a></sup> that is supposed to convince me that Dawkins isn’t as silly as I’d like him to be.</p> <div class="footnotes"> <ol> <li id="fn:1"> <p>Kindly supplied by Høgskolen i Bergen’s Department of Computing, Mathematics and Physics! <a href="#fnref:1" class="reversefootnote">&#8617;</a></p> </li> <li id="fn:2"> <p>Not to mention certain Swedish websites that give music for free. <a href="#fnref:2" class="reversefootnote">&#8617;</a></p> </li> <li id="fn:3"> <p>I honestly haven’t printed out a single PDF ever since I got the iPad. <a href="#fnref:3" class="reversefootnote">&#8617;</a></p> </li> <li id="fn:4"> <p>Only now I read that this book is aimed at children and “young adults”. Oh well, buying wrong books is an important element of the whole physically-buying-books-in-a-bookstore experience. <a href="#fnref:4" class="reversefootnote">&#8617;</a></p> </li> </ol> </div> Fujifilm X10 review (kind of) 2012-07-23T23:19:00+00:00 http://piotrkazmierczak.com/2012/07/23/fuji-x10-review <iframe border="0" scrolling="no" width="78" height="17" allowtransparency="true" frameborder="0" style="margin-bottom: -3px; z-index: 1338; border: 0px; background-color: transparent; overflow: hidden;" src="http://www.instapaper.com/e2?url=http%3A%2F%2Fpiotrkazmierczak.com%2F2012%2F07%2F23%2Ffuji-x10-review%2F&amp;title=Fujifilm+X10+review+%28kind+of%29"></iframe> <p>I’m an amateur photographer, as I mentioned here a couple of times before, and even though not a good one, an enthusiastic one. I travel <strong>a lot</strong> and I love taking photographs of new places, and then spend a lot of time watching those photos, printing some and hanging them on my walls. In short: I like my photographs.</p> <p>But it’s worse, because <a href="http://twitter.com/karolina_helena">Karolina</a> likes taking photographs too, and we only have <a href="http://www.dpreview.com/reviews/nikond40">one camera</a>. We usually travel together, but since we live in different countries, after the travel is over only one gets to take the camera home. That was the first reason I started looking for a new camera.</p> <p>The other reason was portability. Yes, while the D40 is a very small DSLR, it is still a DSLR, and together with the Sigma 18-250 lens it becomes quite hefty. I recently realized that I haven’t been taking the camera with my quite often exactly because of its weight and size. I wanted something smaller. Micro four thirds were attractive, because they had interchangeable lenses and relatively compact bodies, but (AFAIK) none of the models available on the market offered a viewfinder (which I badly wanted), except maybe for the fantastic but a touch too expensive (and too big) <a href="http://www.dpreview.com/reviews/sonynex7">Sony NEX-7</a>. When it comes to compact(ish) cameras with interchangeable lenses, there was also the brand new <a href="http://www.dpreview.com/reviews/fujifilm-x-pro1/">Fujifilm X-Pro 1</a> — again, too expensive — and of course M-series Leicas, which were all very nice, but calling them <em>too expensive</em> is a big understatement. Also, the M9 together with a bright Summilux is not exactly compact or lightweight.</p> <p>So when it comes to compacts with fixed lenses, it seemed there’s only four reasonable choices:</p> <ul> <li>Canon S100, aka <a href="http://www.kenrockwell.com/canon/s100.htm"><em>World’s Best Pocket Camera</em></a>,</li> <li>Sony RX100 — very new, but <a href="http://www.nytimes.com/2012/06/28/technology/personaltech/a-pocket-camera-even-pro-photographers-can-love-state-of-the-art.html?pagewanted=all">promising</a>,</li> <li>Fujifilm X100 — according to some people the <a href="http://zackarias.com/for-photographers/gear-gadgets/fuji-x100-review/"><em>greatest camera ever made</em></a>,</li> <li>and the <a href="http://www.dpreview.com/reviews/fujifilm-x10/">Fujifilm X10</a>.<sup id="fnref:1"><a href="#fn:1" class="footnote">1</a></sup></li> </ul> <p>Canon S100 is brilliant, because at 2853 NOK it’s the cheapest of all three, offers decent image quality, GPS tagging and is truly pocketable. It doesn’t have the viewfinder though (nor is it possible to connect an external one), and its sensor is relatively small. Sony RX100 seems brilliant too, but at 5199 NOK it’s ridiculously expensive, and there’s also no chance to connect any viewfinder too it. Fujifilm X100 was very tempting, because the image quality is superb, the hybrid viewfinder gorgeous, build quality premium, but the fixed 35mm equiv. lens seemed not-so-versatile, and the price tag of 7985 NOK a tad too high. So I was left with the X10.</p> <p><img class="small" src="/images/fuji1.jpg" /></p> <p><em>(Also, this post is not be a proper review of the camera, go to <a href="http://www.dpreview.com/reviews/fujifilm-x10">DPReview</a>, <a href="http://www.kenrockwell.com/fuji/x10.htm">Ken Rockwell</a> or <a href="http://www.stevehuffphoto.com/2011/11/08/the-fuji-x10-digital-camera-review-a-look-at-the-baby-brother-of-the-x100/">Steve Huff</a> for more professionally written texts. I will simply make a few comments about this camera, from a perspective of a non-professional enthusiast photographer, and a long-time owner of a (D)SLR.)</em></p> <p>First off, the build quality and body design. The X10 has “Made in Japan” proudly printed on the back of the body and I have to say the build quality is spectacular. The magnesium body feels sturdy and perfectly well made. My Nikon D40 feels like a cheap toy in comparison. The zoom ring of the lens moves swiftly, the control rings on the top give a reassuring resistance, and the whole thing reminds me of old film cameras, “back in the day when cameras were made for photographers”. Yes, that’s exactly how this camera feels: like it’s been made for a photographer. Also, Fujifilm X10 is the only compact(ish) camera in which you control the zoom of the lens by moving the zoom ring and not some W/T switch.</p> <p>It’s not exactly a pocket-sized camera, but it’s <em>much</em> smaller and lighter than a DSLR. I was recently walking up Fløyen and had my wallet, phone and the X10 with me. Didn’t feel I was carrying a camera at all, yet I was able to take some really nice photos, like this one:</p> <p><a href="/images/fuji2.jpg"><img src="/images/fuji2.jpg" alt="" /></a></p> <p>or this one:</p> <p><a href="/images/fuji3.jpg"><img src="/images/fuji3.jpg" alt="" /></a></p> <p>As you can see in the images above, the X10 produces crisp, vivid images. Mind you, both photos above are JPGs straight from the camera — no lightrooming here. The X10 features a very bright and sharp 7.1-28.4mm (28-112mm equiv) f/2.0-2.8 lens, which makes shooting in low light very easy. It also has a great Fujifilm <a href="http://www.dpreview.com/reviews/fujifilm-x10/9">EXR</a> sensor, which, when used properly, generates images with a higher dynamic range than you would expect from a compact camera. It’s still nowhere close a full-frame or even APS-C both in terms of dynamic range and depth of field<sup id="fnref:2"><a href="#fn:2" class="footnote">2</a></sup> control. But again, given its compact size, the lens is fantastic — bright and sharp — and that’s all you need in a compact camera. It’s even possible to make decent portraits using it. Take a look at a portrait of my fellow logician Sjur:</p> <p><a href="/images/fuji4.jpg"><img src="/images/fuji4.jpg" alt="" /></a></p> <p>There’s no proper bokeh, but I’d say it’s more than acceptable for a compact camera. Also, when it comes to image quality, the noise seems to be under control (for a small sensor), and the f/2.8 at 112mm equiv. allows for relatively good shots under low light conditions:</p> <p><a href="/images/fuji5.jpg"><img src="/images/fuji5.jpg" alt="" /></a></p> <p>Again, the above photo is a JPG straight from the camera. To achieve similar results with my D40, I’d have to shoot RAW and fight the noise in Lightroom.</p> <p>Moving on, I have to mention the viewfinder. This was one of the reasons I chose X10 over Sony’s RX100,<sup id="fnref:3"><a href="#fn:3" class="footnote">3</a></sup> and even though the optical viewfinder has a number of shortcomings, I still feel it’s good to have it. The first problem with the it is that it doesn’t display <em>any</em> information at all. For example, when the camera is in <em>silent mode</em> (which I guess most people prefer) and doesn’t make the <em>beep</em> when it focuses, it’s easy to make an out-of-focus photo, since there’s no indication of focus in the viewfinder. Below is an example photo of my friend Puja:</p> <p><a href="/images/fuji6.jpg"><img src="/images/fuji6.jpg" alt="" /></a></p> <p>Furthermore, the lens can sometimes be seen in the viewfinder, and it covers about ~85% of the frame. Still, it’s bright and useful, but having a hybrid viewfinder like the X100 has would be fantastic.</p> <p>Finally, some other aspects of X10 that I particularly like. It has a hot shoe so it’s possible to connect an external flashlight (not many compacts have a hot shoe these days), and the shutter release button is threaded, so it can be released with a mechanical cable — old school! The X10 also has a lot of buttons (some of which are configurable) and dials, so accessing the menu is seldom necessary. And it has some <em>auto</em> features that are useful, like 180° or 360° panorama mode, film emulation (Provia, Velvia (<strong>yes!</strong>), Astia and B&amp;W) and of course bracketing (ISO, exposure, film emulation and dynamic range), so expect lots of tacky HDR photos soon.</p> <p>The big question that remains, however, is should you pay 3999 NOK for this camera, when you can have a Nikon D3100 with a kit lens for 3270 NOK or Canon EOS 1100D kit for 2906 NOK? Yes and no.</p> <p>If you’re after image quality alone, then definitely no. Even an entry level DSLR paired with <a href="http://www.kenrockwell.com/nikon/35mm-f18.htm">a cheap bright lens</a> will deliver better quality images, especially if you shoot RAW and know your Lightroom. What Fuji X10 will be better at, however, is the quality of JPGs straight from the camera. If you master EXR dynamic range modes and exploit the quality of the lens, it’s going to be difficult to reproduce similar results with a DSLR in this price range. DSLR’s, however, are extensible, and with more expensive lenses (which you don’t have to immediately buy) can deliver spectacular images. The X10 will still be, of course, way lighter and more portable, which makes it a perfect second camera.</p> <p>Some might ask, then, if it’s not better to get a micro four thirds camera, and in my opinion it isn’t. To me, micro four thirds cameras are half-measures. They won’t deliver APS-C image quality because of their small sensors, they usually don’t come with viewfinders (although you can buy external viewfinders for some models), and unless you attach a pancake lens, they’re not exactly portable, and by no means pocketable. In my opinion, if you’re carrying a micro four thirds camera, you might as well be carrying a small DSLR. But, as they say, YMMV.</p> <p>So yes, if you’re in a market for a relatively small camera that delivers decent images, has lots of manual controls and features a relatively versatile, fast and sharp lens, then the Fujifilm X10 is a perfect choice. If the lack of a viewfinder isn’t a deal breaker for you, go for the Sony RX100. If you have a bit more money and don’t need the zoom, buy the X100.</p> <p>Finally, if you’re rich, want awesome image quality but don’t want to be carrying a heavy full frame DSLR, have some skills and want extra points for style, get the new <a href="http://www.dpreview.com/previews/leica-m-monochrom/">M-Monochrome</a> and <a href="http://www.stevehuffphoto.com/2009/12/09/the-leica-50-noctilux-f-0-95-lens-review/">a bright lens</a>.</p> <div class="footnotes"> <ol> <li id="fn:1"> <p>Yes, there are also some nice Ricoh compacts and Canon G1 X, and probably some more. <a href="#fnref:1" class="reversefootnote">&#8617;</a></p> </li> <li id="fn:2"> <p>In terms of depth of field, X10’s f/2.8 is actually equivalent to f/11 on a full-frame camera. <a href="#fnref:2" class="reversefootnote">&#8617;</a></p> </li> <li id="fn:3"> <p>The other reason was the price, but then again I’m almost Norwegian, so I’m basically rich and I don’t care about money. <a href="#fnref:3" class="reversefootnote">&#8617;</a></p> </li> </ol> </div> My Diablo III Experience 2012-05-15T22:52:00+00:00 http://piotrkazmierczak.com/2012/05/15/my-diablo-iii-experience <iframe border="0" scrolling="no" width="78" height="17" allowtransparency="true" frameborder="0" style="margin-bottom: -3px; z-index: 1338; border: 0px; background-color: transparent; overflow: hidden;" src="http://www.instapaper.com/e2?url=http%3A%2F%2Fpiotrkazmierczak.com%2F2012%2F05%2F15%2Fmy-diablo-iii-experience%2F&amp;title=My+Diablo+III+Experience"></iframe> <p>I’m not a big gamer, I seldom buy and play computer games. There aren’t many titles that engage me for more than a couple of days, but those that do, however, I keep coming back to for years. That’s the case with my favorite games, such as <a href="http://www.adom.de/">ADOM</a>, Starcraft, Counter-Strike, Half-Life, Grand Theft Auto series (only in 3D) and Neverwinter Nights. I was told that Diablo is a similar kind of game, the one that you keep coming back to, so since the long awaited Diablo III premiered last night, I figured I could give it a try.</p> <p>I also figured that it’s a bad idea buying and downloading the game last night, since everyone will be trying to do that and the servers will go down. This indeed happened, and anyway I didn’t have time to play last night, I was working until very late at night/early in the morning.</p> <p>Today I had a pretty tough day (possibly due to a sleepless night), so I thought it wouldn’t hurt to slay a couple of demons and zombies. I bought the game, downloaded the OS X<sup id="fnref:1"><a href="#fn:1" class="footnote">1</a></sup> client, downloaded 9+ gigabytes of files and… never even managed to play single-player campaign.</p> <p><img class="small" src="/images/diablo.png" /></p> <p>The message above, or some of its variants, keeps popping up, and I’m either unable to login with my Battle.net account, or get kicked out of the game after ~5 minutes of playing. I can’t resume the game, because <em>the server awaits other party members</em> (wtf?), and after quitting it and relaunching I’m usually not able to login again. I had what Blizzard installer called a <em>playable</em> game on my hard drive since about 6:00 p.m., it’s 12:24 a.m. now and I’m still unable to play. There are two observations one can make about it.</p> <ol> <li>Blizzard made a <strong>huge</strong> boo boo. They are known for releasing very few games, just one title every few years, but when they do release one, it’s usually revolutionizing the genre. Their games are polished, produced with a huge attention to detail and attract enormous amounts of players. They are highly anticipated, Diablo fans waited for the latest version of their favorite game for over 12 years. So when I see that it’s past 24 hrs after the game was released<sup id="fnref:2"><a href="#fn:2" class="footnote">2</a></sup>, and people still aren’t able to play it, I imagine someone at Blizzard must be getting mad (not to mention how mad must Diablo fans be right now, especially those that payed those €59,99 some weeks ago when the game went on pre-sale). So in short, Blizzard, please fire some people. Preferably a lot.</li> <li>It baffles me as a 27 year old male why I can’t play a single-player campaign of a game that I already paid for because of server-related problems. Are Battle.net servers down? <strong>I don’t know, why should I care?</strong> Where are the times when you could buy a new, DRM-free computer game and simply play it? Is it only possible today via <a href="http://www.humblebundle.com/">Humble Indie Bundle</a> and, paradoxically, Apple’s Mac App Store these days?</li> </ol> <p>Of course you could say that it’s no biggie, that it’s just a computer game and that if I’m not able to play it today I will (probably) be able to play it tomorrow, etc., and you’d be right, except that because of how my whole Diablo III experience is, I no longer want to play the game. I no longer give a shit, and I’m pretty sure there are others like me, and the fault is Blizzard’s entirely. One, because they couldn’t prepare for the hype they themselves created, and two, because their stupid DRM-restricted Battle.net ruins the whole gaming experience. It’s just so sad that even though we have better graphics and sound, and all the bells and whistles in modern computer games, playing the old ones is simply more fun.</p> <div class="footnotes"> <ol> <li id="fn:1"> <p>Actually, this deserves a note because it’s really a nice touch that Blizzard games are available for OS X. Not only that, they’re available for Macs at the same time the Windows version is released. Thanks, Blizzard. <a href="#fnref:1" class="reversefootnote">&#8617;</a></p> </li> <li id="fn:2"> <p>Blizzard actually made one good move here offering the game for download prior to its release. You could have all the files on your hdd and simply activate the game via Battle.net once it’s released. I understand that the idea behind such solution was to reduce the strain on the servers during the release. Unfortunately, it apparently didn’t work out. <a href="#fnref:2" class="reversefootnote">&#8617;</a></p> </li> </ol> </div> New Violin 2012-01-28T23:00:00+00:00 http://piotrkazmierczak.com/2012/01/28/new-violin <iframe border="0" scrolling="no" width="78" height="17" allowtransparency="true" frameborder="0" style="margin-bottom: -3px; z-index: 1338; border: 0px; background-color: transparent; overflow: hidden;" src="http://www.instapaper.com/e2?url=http%3A%2F%2Fpiotrkazmierczak.com%2F2012%2F01%2F28%2Fnew-violin%2F&amp;title=New+Violin"></iframe> <p>I’ve been playing violin since I was 7. I went to music school in my hometown, Skierniewice, and spent six years there, finishing what is called a <em>1st stage</em> music school in Poland. I did not continue to a <em>2nd stage</em> school and never became a <em>professionally</em> trained musician, but I’ve spent many years playing in different orchestras, first in Skierniewice, later in Warsaw. I enjoyed improvising jazz<sup id="fnref:1"><a href="#fn:1" class="footnote">1</a></sup> with my friends in high school, but that ended when I moved out from Skierniewice. Ever since then my only contact with the instrument was through weekly orchestral rehearsals, some practice in between those, and occasional concerts. And when I moved out from Poland in 2008, I left my violin there and did not play since then.</p> <p>Having an electric instrument was always a dream. I enjoyed listening to <a href="http://www.ponty.com/">Jean-Luc Ponty’s</a> old albums, I was<sup id="fnref:2"><a href="#fn:2" class="footnote">2</a></sup> a big fan of <a href="http://www.myspace.com/matmaneri">Mat Maneri’s</a> avant-garde free jazz, and of course I loved (and still love) the very best jazz violinist of all time, <a href="http://en.wikipedia.org/wiki/St%C3%A9phane_Grappelli">Stéphane Grappelli</a><sup id="fnref:3"><a href="#fn:3" class="footnote">3</a></sup>. At some point a very good friend of mine (whom I spent many years in a couple of orchestras with) bought herself a <a href="http://www.fender.com/en-PL/products/search.php?partno=0950030232">Fender electric violin</a>, I even had a chance to play them, but did not think of buying an electric instrument for myself back then.</p> <p>Why have I stopped playing violin after so many years of practice? I guess the main reason was I did not have much time, and I no longer had an orchestra or any other kind of band I could play with. Also, at some point playing violin became a very frustrating experience. Not necessarily because my technical abilities worsened, I feel I’m more or less at the same level of playing technique as I was a couple of years ago, but because my expectations significantly outgrew what I was able to play. I kept listening to a lot of records, and each time I tried playing a piece, I was so disappointed by how bad my performance is that I simply hid the instrument back in the case and played some CDs instead. ‘I am not a professional musician’, I would tell myself, ‘it’s not my job, I shouldn’t be wasting my time on this.’</p> <p>Then during one of my visits to Groningen, I met Karolina’s friend Tim. Karolina is a cello player<sup id="fnref:4"><a href="#fn:4" class="footnote">4</a></sup>, and Tim sometimes plays oboe. Every second weekend or so, they meet at one’s apartment and play music. (Karolina, Tim, if you’re reading this, please skip this paragraph.) Neither is a professional musician, and, seriously speaking, neither plays good. They’re often out of tune, they miss some bars every now and then, and they make a number of other mistakes. Still, their performances are what I’d call <em>decent</em>, or what my friend Erik would probably call <em>adequate</em>. While listening to them I realized it doesn’t really matter if they don’t play like pros, because playing music together and having <em>live</em> music at home is simply an <em>enormous</em> joy. I also realized I miss that. I wanted to go back in the game, wanted to go back to playing music.</p> <p>There was a problem with an instrument though. Of course I had my old violin back at my parents’ house in Poland, but the instrument was in bad shape (years of neglect) and it actually never was particularly good. One could say that you don’t really need a great instrument if you’re a crappy musician, and that’s one way of looking at it, but then again a bad instrument doesn’t really help if you’re having difficulties playing harmonics or double stops. And then I also recalled that I always dreamed of having an electric violin. I checked the balance of my savings account, looked at how cheap the euro is, went on to <a href="http://thomann.de">http://thomann.de</a>, ordered a <a href="http://no.yamaha.com/no/products/musical-instruments/strings/silentviolins/sv_200/?mode=model">Yamaha SV-200 silent electric violin</a>, a carbon bow, a good rosin, a decent (or adequate) <a href="http://www.kunrest.com/">shoulder rest</a>, and a <a href="http://www.jakob-winter.de/">lightweight case</a>, pressed ‘buy’ and waited.</p> <p>Before I tell you how the whole setup feels and sounds, let my give a few words of justification: why this violin and not other?</p> <ol> <li>First off, a <em>silent</em> violin allows me to practice technically whenever I want. While unplugged from an amplifier the instrument produces a hardly audible sound, unnoticeable to anyone in another room, allowing me to play late at night using headphones.</li> <li>Secondly, this instrument has a line-out socket, which makes recording multiple parts of a string quartet possible without the need of an expensive microphone (cheap mics + violin = the sound of slaughtering a cat). I always wanted to play Shostakovich’s 1st string quartet, but never had a quartet to play it with. This is no longer a problem.</li> <li>The SV-200 can sound any way I want. If I’m practicing Wieniawski’s caprices, I can make it sound like an ordinary acoustic violin. If I want to imitate Ponty, it produces a full-blown 70s fusion sound.</li> <li>And finally, some practical considerations. It seems it’s much more difficult to damage this instrument than an acoustic violin. It’s less fragile and less sensitive to temperature or humidity.</li> </ol> <p>So now, how does it feel? A bit weird. The fingerboard seems to be a tad <em>shorter</em> than on my acoustic violin. The strings (D’Addario Zyex) seem to be easier to press (the difference is not as big as between an acoustic guitar and an electric one, but still), and of course the sound highly depends on the amplifier. The instrument doesn’t feel at all heavier than an acoustic violin, although according to technical specs it is \~100 grams heavier. I haven’t used a Kun shoulder rest before, but it seems to be better than my old Wolf Forte Secondo. The strings I’ll probably need to replace, I don’t like the sound. In fact I plan on buying a set of Dominants and some Pirastro, and compare which one sounds better. Also, I’ve tested recording a couple of minutes into Garage Band, and it sounded pretty good.</p> <p>But most important of all, I played some parts of The Four Seasons together with Karolina today. We played together for the first time in many years. It was by all measures musically terrible. But it was an awful lot of fun, too.</p> <div class="footnotes"> <ol> <li id="fn:1"> <p>I suppose calling what we played <em>jazz</em> is a bit of an insult to any serious jazz musician, but that’s how we thought about it back then. <a href="#fnref:1" class="reversefootnote">&#8617;</a></p> </li> <li id="fn:2"> <p>It’s not that I don’t like his music anymore, but I guess I wouldn’t consider myself a fan. <a href="#fnref:2" class="reversefootnote">&#8617;</a></p> </li> <li id="fn:3"> <p>Now that I think about it, I’m not sure if Grappelli ever played an electric violin. Still, his violin sounded electric enough on some records. <a href="#fnref:3" class="reversefootnote">&#8617;</a></p> </li> <li id="fn:4"> <p>She’s as amateurish as I am. In fact, we met in the <em>1st stage</em> music school in my hometown, and played in an orchestra together — me as the 1st violin, she as 1st cello. Doesn’t get any more romantic and cheesy than this. <a href="#fnref:4" class="reversefootnote">&#8617;</a></p> </li> </ol> </div> Disabling a minor-mode on a per-file basis 2012-01-17T23:00:00+00:00 http://piotrkazmierczak.com/2012/01/17/disabling-a-minor-mode-on-a-per-file-basis <p>I like <code>auto-fill-mode</code> and even have it customized for <code>LaTeX-mode</code> in my Emacs configuration. However, while working with other people via a distributed version control system, like I do with my friends, <code>auto-fill-mode</code> can be a real pain if not everyone uses it. Whenever the ones that do commit any code, others are annoyed because it’s difficult to see the changes in the diff file, since <code>auto-fill-mode</code> reformats paragraphs (hence producing ‘more’ changes).</p> <p>The most straightforward solution is to put some local variables into the file, like <code>(auto-fill-mode -1)</code>, but today at StackOverflow I saw <a href="http://stackoverflow.com/questions/6669373/disabling-auto-fill-mode-on-a-per-file-not-filetype-basis">a much neater solution</a>: one can put a function that searches for a specific string inside a file and sets minor-modes accordingly. So now there’s a <em>coauthors search</em> function in my <code>.emacs</code>:</p> <div class="highlight"><pre><code class="language-cl" data-lang="cl"><span class="c1">; auto-fill is enabled for TeX...</span> <span class="p">(</span><span class="nv">add-hook</span> <span class="ss">&#39;LaTeX-mode-hook</span> <span class="ss">&#39;turn-on-auto-fill</span><span class="p">)</span> <span class="c1">; ...unless I work with the gang</span> <span class="p">(</span><span class="nb">defun</span> <span class="nv">my-auto-fill-disabling-hook</span> <span class="p">()</span> <span class="s">&quot;Check to see if we should disable autofill.&quot;</span> <span class="p">(</span><span class="nv">save-excursion</span> <span class="p">(</span><span class="nb">when</span> <span class="p">(</span><span class="nb">or</span> <span class="p">(</span><span class="nv">re-search-forward</span> <span class="s">&quot;truls&quot;</span> <span class="mi">1000</span> <span class="no">t</span><span class="p">)</span> <span class="p">(</span><span class="nv">re-search-forward</span> <span class="s">&quot;sjur&quot;</span> <span class="mi">1000</span> <span class="no">t</span><span class="p">)</span> <span class="p">(</span><span class="nv">re-search-forward</span> <span class="s">&quot;erik&quot;</span> <span class="mi">1000</span> <span class="no">t</span><span class="p">))</span> <span class="p">(</span><span class="nv">auto-fill-mode</span> <span class="mi">-1</span><span class="p">))))</span> <span class="p">(</span><span class="nv">add-hook</span> <span class="ss">&#39;find-file-hooks</span> <span class="ss">&#39;my-auto-fill-disabling-hook</span><span class="p">)</span></code></pre></div> Typesetting a document with lots of code listings using Emacs, Org-mode, Minted and LaTeX 2011-11-18T21:49:00+00:00 http://piotrkazmierczak.com/2011/11/18/typesetting-a-document-with-lots-of-code-listings-using-emacs-org-mode-minted-and-latex <p>Say you have a document full of code listings that you want to typeset comfortably and enjoy an awesome quality output at the same time. You won’t use a WYSIWYG word processor, because these don’t offer good quality output. And you wouldn’t want to use LaTeX for this, because typesetting code listings in TeX is tedious (to be frank, typesetting <strong>anything</strong> in TeX is tedious). What should you do, then?</p> <p>The answer is same as usual: run Emacs and open up an <a href="http://soundandcomplete.com/2011/09/15/org-mode-as-an-ideal-note-taking-solution/" title="Org-Mode As An Ideal Note-taking Solution">Org-Mode</a> file.</p> <p>Org is obviously great for any sort of documents, but for those that have a lot of code listings it’s particularly awesome. Whenever you need to embed a listing, just put it between <code>#+begin_src &lt;language&gt;</code> and <code>#+end_src</code>. The default behavior while exporting to LaTeX is to use the <code>listings</code> package, but if you find it lacking (as I do), you can use the far better option that is <a href="http://code.google.com/p/minted/">Minted</a>.</p> <p>In order for Org to use Minted by default, you can put the following <code>elisp</code> code into your <code>.emacs</code>:</p> <div class="highlight"><pre><code class="language-cl" data-lang="cl"><span class="c1">; minted latex export</span> <span class="p">(</span><span class="k">setq</span> <span class="nv">org-export-latex-listings</span> <span class="ss">&#39;minted</span><span class="p">)</span> <span class="p">(</span><span class="k">setq</span> <span class="nv">org-export-latex-minted-options</span> <span class="o">&#39;</span><span class="p">((</span><span class="s">&quot;frame&quot;</span> <span class="s">&quot;lines&quot;</span><span class="p">)</span> <span class="p">(</span><span class="s">&quot;fontsize&quot;</span> <span class="s">&quot;\footnotesize&quot;</span><span class="p">)</span> <span class="p">(</span><span class="s">&quot;linenos&quot;</span> <span class="s">&quot;&quot;</span><span class="p">)))</span></code></pre></div> <p>and then use the Minted package for LaTeX export:</p> <pre><code>#+LaTeX_HEADER: usepackage{minted} #+LaTeX_HEADER: usemintedstyle{emacs} </code></pre> <p>With the sample configuration above you get your listings parsed through <a href="http://pygments.org/">Pygments</a> and Minted every time you export your document to PDF via pdfLaTeX, and enjoy both the convenience and power of Org-Mode, as well as beautifully rendered LaTeX output.</p> <p>Use Org-Mode, folks!</p> A eulogy for Maemo/MeeGo 2011-10-24T18:11:00+00:00 http://piotrkazmierczak.com/2011/10/24/a-eulogy-for-maemo-meego <iframe border="0" scrolling="no" width="78" height="17" allowtransparency="true" frameborder="0" style="margin-bottom: -3px; z-index: 1338; border: 0px; background-color: transparent; overflow: hidden;" src="http://www.instapaper.com/e2?url=http%3A%2F%2Fpiotrkazmierczak.com%2F2011%2F10%2F24%2Fa-eulogy-for-maemo-meego%2F&amp;title=A+eulogy+for+Maemo%2FMeeGo"></iframe> <p>A long, long time ago, when I was still very enthusiastic about desktop linux and free software in general, an idea of a linux-based cellphone or a ‘palmtop’, as they were called back in the day, was something the FLOSS community dreamed of. There were numerous software and hardware projects (does anyone still remember <a href="http://en.wikipedia.org/wiki/Openmoko">OpenMoko</a>?), and one of them, <a href="http://www.android.com/">Android</a>, was acquired by Google in 2005, and later became one of the most popular operating systems for mobile devices in the world.<sup id="fnref:1"><a href="#fn:1" class="footnote">1</a></sup></p> <p>I never liked Android. Not because I didn’t like the interface or the phones, or the logo, or Google – no. I didn’t like Android because it was a fork of the linux kernel and a linux distribution that didn’t (and from what I know still doesn’t) support the full set of standard GNU libraries or X window system.<sup id="fnref:2"><a href="#fn:2" class="footnote">2</a></sup> And because there was a much <em>better</em> alternative developed by some Gnome project programmers and Nokia, called <a href="http://maemo.org/">Maemo</a>, that already in 2005 provided a nice touch-based interface, supported many well-established linux technologies (X.org, Gtk+, ESD, etc.), and was actually used by a device you could buy, namely Nokia’s <a href="http://en.wikipedia.org/wiki/Nokia_770_Internet_Tablet">N770 Internet Tablet</a>. Granted, it wasn’t a phone, but the software was mature compared to Android at that time (first Android devices available to the public were offered in late 2008), and was much more hacker-friendly and linux-friendly. It was easy for desktop linux programmers to integrate their apps with Maemo and to write Maemo software. At least that’s the way I thought about it back in 2006.</p> <p>In 2009 Nokia released the first smartphone that ran Maemo – the <a href="http://en.wikipedia.org/wiki/Nokia_N900">N900</a>. But that was 2009, and Android already had an established user base, and new Android phones were released every couple of months. I’ve seen many N900 phones at FOSDEM in 2010, free software hackers really loved them. I remember everyone being excited about the potential Maemo had, but people also seemed to begin to realize that the battle was lost. Nokia was late, Android was good (or good enough) and popular, and the N900 remained a smartphone good for hackers and hackers only.</p> <p>However, in February 2010 Nokia’s Maemo and Intel’s Moblin <a href="http://www.techradar.com/news/phone-and-communications/mobile-phones/intel-and-nokia-merge-moblin-and-maemo-to-form-meego-670302">merged</a>, creating <a href="https://meego.com/">MeeGo</a><sup id="fnref:3"><a href="#fn:3" class="footnote">3</a></sup>, and then in June Nokia <a href="http://www.reuters.com/article/2010/06/24/nokia-idUSLDE65N14720100624">announced</a> that all its smartphones will run MeeGo. There was hope, but not for long. In February 2011 Nokia <a href="http://www.bbc.co.uk/news/business-12427680">changed its mind</a>, and decided to team up with Microsoft, and have its new smartphones run the new Windows Phone 7.</p> <p>It therefore saddens me to read the <a href="http://www.engadget.com/2011/10/22/nokia-n9-review/">review</a> of the latest MeeGo-based smartphone, the fantastic N9. It seems like a terrific device, both hardware- and software-wise. Engadget sums the software up in the following way:</p> <blockquote> <p>MeeGo 1.2 <a href="http://www.engadget.com/tag/Harmattan/">Harmattan</a> is such a breath of fresh air it will leave you gasping – that is, until you remember that you’re dealing with a dead man walking. It’s impossible to dismiss what’s been achieved here – a thoroughly modern, elegant, linux-based OS with inspired design that’s simple and intuitive to use, all developed in house by Nokia.</p> </blockquote> <p>That’s exactly how things are with N9: it’s awesome in so many ways, but so fundamentally flawed because it’s a dead platform. Dead to most people, that is, because hackers will definitely find ways to upgrade the software, they’ll write apps if they need to, and will be happy to use the wonderful hardware that N9 features. The rest probably won’t even notice such a phone existed, because Nokia said it will not release the N9 in US, UK, Japan, Germany or Canada.</p> <p>And I will shed a tear, because what seems to be the most innovative and fresh mobile platform today is being buried alive. And why? Probably even people at Nokia do not know.</p> <p><a href="http://news.ycombinator.com/item?id=3162429">Discussion on HackerNews</a>.</p> <div class="footnotes"> <ol> <li id="fn:1"> <p>Actually Canalyst <a href="http://www.canalys.com/newsroom/google%E2%80%99s-android-becomes-world%E2%80%99s-leading-smart-phone-platform">reported</a> that right now (October 2011) Android is the best selling operating system for smartphones. <a href="#fnref:1" class="reversefootnote">&#8617;</a></p> </li> <li id="fn:2"> <p>I don’t think it’s necessarily a good thing for an operating system for smartphones to support all that any more. But in 2005 things looked a bit different. <a href="#fnref:2" class="reversefootnote">&#8617;</a></p> </li> <li id="fn:3"> <p>It’s easy to get lost. Now MeeGo merged with some other projects and became <a href="https://www.tizen.org/">Tizen</a>. <a href="#fnref:3" class="reversefootnote">&#8617;</a></p> </li> </ol> </div> B&W Zeppelin Air — A Short (sort of) Review 2011-09-04T18:43:00+00:00 http://piotrkazmierczak.com/2011/09/04/bw-zeppelin-air-a-short-review <p><img src="/images/zeppelin1.jpg" alt="" /></p> <iframe border="0" scrolling="no" width="78" height="17" allowtransparency="true" frameborder="0" style="margin-bottom: -3px; z-index: 1338; border: 0px; background-color: transparent; overflow: hidden;" src="http://www.instapaper.com/e2?url=http%3A%2F%2Fpiotrkazmierczak.com%2F2011%2F09%2F04%2Fbw-zeppelin-air-a-short-review%2F&amp;title=B%26W+Zeppelin+Air+%E2%80%94+A+Short+%28sort+of%29+Review"></iframe> <p>B&amp;W Zeppelin is one of those devices that really catch one’s eye. It can’t remain unnoticed, but it doesn’t make a good impression. When we saw it in a store today, our initial thought was that it’s a beautiful toy for people willing to spend too much money (€600!) on what basically is just a fancy iPod docking station. Didn’t expect to cycle through the narrow streets of downtown Groningen holding my left hand on a shaky old handlebar of a borrowed <em>oma fiets</em>, and another one on a big white ‘Bowers &amp; Wilkins’ box semi-attached to the rear rack an hour later. That hour was filled with discussions between me and Karolina whether it makes sense to spend such an amount of money on such a small ‘thingy’, and whether the sound really is that good. Well, as everyone probably already expects, it actually is <em>that</em> good.</p> <p>Of all the iPod docking stations I’ve ever listened to the Zeppelin offers by far the best sound quality. I’m sitting in front of the device while writing this post, and still can’t believe how great the sound is. For such a small device it creates a really big scene. The sound is rich, detailed and dynamic. And it’s difficult to believe how deep the bass goes.<sup id="fnref:1"><a href="#fn:1" class="footnote">1</a></sup> The thing really sounds <em>awesome</em>.</p> <p>And what’s funnier, its design is brilliant. The Zeppelin looks like a creature from outer space. It’s small, but relatively heavy for its size, has only three buttons (power/stand by, volume up, volume down) and a single diode on the front panel which glows in a different color depending on the source. And now here’s the fun part: besides the mini-jack aux input and a standard USB socket, the new Zeppelin features AirPlay-compatible streaming, so once you configure it for the local wireless network it can be accessed via iTunes or iPod app on the iPhone, and the audio can be streamed to it directly.</p> <p>There’s also a funny little pilot in the box that comes in handy when you’re sitting on the couch with your girlfriend sipping that Italian wine and enjoying the sound of Leszek Możdżer’s piano.</p> <p><img src="/images/zeppelin2.jpg" alt="" /></p> <p>And finally, the Zeppelin has a composite video output socket that can stream the video from an iPod/iPhone to a TV, but this feature we couldn’t test because we don’t own a TV set.</p> <p>So in the end it all boils down to the question: why wouldn’t you simply buy a nice micro hi-fi system, with separate loudspeakers? Well for one, the Zeppelin is much more portable, and given that Karolina moves statistically 3 times a year since she moved to the Netherlands, it’s pretty important for her to avoid having unnecessary items. In addition, the AirPlay feature is really convenient, especially if you live inside the Apple ecosystem (and we both do). And finally, for this price there aren’t that many micro systems with sound comparable to the Zeppelin.</p> <div class="footnotes"> <ol> <li id="fn:1"> <p>Just to be clear here: the sound obviously isn’t as good as what a <em>proper</em> micro-system produces. Even a low-end Piano Craft plays better, but it’s more expensive and is simply a different kind of a device. <a href="#fnref:1" class="reversefootnote">&#8617;</a></p> </li> </ol> </div> The world is a funny place 2011-05-04T19:01:00+00:00 http://piotrkazmierczak.com/2011/05/04/the-world-is-a-funny-place <p><img src="/images/funnyplace.jpg" alt="" /></p> <p>So there I was having a lunch at ‘Shanghai Dumpling’ at Taipei 101, when suddenly one of the girls sitting at the table next to mine said: ‘Hey, you’re welcome to eat our dumplings if you want to, because they’re too sweet for us, and we’re quite full anyways’. ‘Thanks!’, I quickly replied, because no one needs to sell me on eating more dumplings, especially if they’re sweet. We started talking about what I’m doing in Taipei, and then it turned out they were Japanese. But there’s noting unusual in meeting two Japanese girls in Taiwan. What’s unusual is to discover one of them speaks a bit of Polish, because she used to study some bit of contemporary European literature, particularly Gombrowicz, and that made her sign up for a Polish language course (of course she didn’t last long, but still).</p> <p>The world really is a funny place.</p> Macbook Pro After 6 Months 2011-03-17T20:54:58+00:00 http://piotrkazmierczak.com/2011/03/17/macbook-pro-after-6-months <iframe border="0" scrolling="no" width="78" height="17" allowtransparency="true" frameborder="0" style="margin-bottom: -3px; z-index: 1338; border: 0px; background-color: transparent; overflow: hidden;" src="http://www.instapaper.com/e2?url=http%3A%2F%2Fpiotrkazmierczak.com%2F2011%2F03%2F17%2Fmacbook-pro-after-6-months%2F&amp;title=Macbook+Pro+After+6+Months"></iframe> <p>Some readers of this blog probably know that for a very long time (ca. 1998– 2010) I’ve been a devout linux user. I’ve been using this system exclusively on all the computers until the Fall last year, when I decided to give Macbook Pro a try (mainly for hardware-related <a href="http://soundandcomplete.com/2010/08/07/growing-linux-frustration/">reasons</a>). I’ve written about it a <a href="http://soundandcomplete.com/2010/09/26/confessions-of-a-linux-to-mac-convert-week-1/">couple</a> of <a href="http://soundandcomplete.com/2010/10/10/confessions-of-a-linux-to-mac-convert-%e2%80%94-week-3/">times</a> already, but it’s still a subject I keep thinking about, and about which I’m being asked by my friends constantly. ‘Why have you bought a Mac?’, they ask, ‘how is it any better? Don’t you miss <em>freedom?</em> Don’t you miss Gnome?’</p> <p>Yes and no. But let me elaborate on that.</p> <p><em>(This is a rather long post, so if you’re not interested in the topic or simply don’t want to read the same old rants over and over again, let me offer you a one-sentence wrap-up of what’s written here: Linux is cool, Mac is uncool, but then again Mac is also cool or even cooler.)</em></p> <p>I miss the <em>freedom of choice</em> I love so much. When you’re running <a href="http://www.ubuntu.com">Ubuntu</a> or <a href="http://www.fedoraproject.org">Fedora</a>, or any other linux distro for that matter, and you’re annoyed/bored by your current graphical interface, you can just switch it to something else. Don’t like <a href="http://www.gnome.org">Gnome</a>? Give <a href="http://www.kde.org">KDE</a> a try. Don’t like either? Go for <a href="http://lxde.org/">LXDE</a>, <a href="http://openbox.org/">Openbox</a>, <a href="http://fluxbox.org/">Fluxbox</a>, <a href="http://windowmaker.org/">WindowMaker</a>, <a href="http://www.xfce.org/">Xfce</a>, <a href="http://www.enlightenment.org">Enlightenment</a>, <a href="http://www.fvwm.org/">FVWM</a>, <a href="http://awesome.naquadah.org/">Awesome</a>, <a href="http://xmonad.org/">Xmonad</a> – you name it! I know that tweaking and playing with your computer’s operating system kills productivity, but that’s just the way I am: I like to be able to change things a bit. Here on Mac OS X it’s either the Apple way, or the highway.</p> <p>Furthermore, it seems like I’m a man of habits, and I can’t get used to some OS X-specific features. For example, the distinction between applications and windows. Let me tell you how this works: in OS X, if you’re running Mail.app (a default e-mail client) and you’re having the main program window open plus you’re composing a new email (that’s another window), you can’t switch between these two with Cmd+Tab keyboard shortcut. Cmd+Tab will switch you to another application you’re running, for example Firefox. If you want to switch between windows within the same application, you need to press Cmd+, and there’s no way around it. You can’t disable it, you can’t force OS X to cycle through all the windows of all the apps with Cmd+Tab. I understand some rationale behind the distinction, I sort of see the point, but… I hate it. If I’m writing this post in Firefox now, and I want to switch to another window which is within another application and it’s not in the foreground, I need to first Cmd+Tab and then Cmd+. In Gnome or KDE it’s just one shortcut. Also, if you minimize a window with Cmd+M, you cannot switch to it either with Cmd+Tab or Cmd+, you have to click on it’s minimized icon in the Dock, or invoke <a href="http://en.wikipedia.org/wiki/Expos%C3%A9_(Mac_OS_X)">Exposé</a>. It may be clean in terms of design and logic, but it’s all just terribly impractical.</p> <p>Ok, let’s get to the hardware now. The aluminium unibody Macbook Pro is incredible. It’s sturdy, lightweight, compact, beautiful and absolutely noiseless (unless you’re playing Half-Life 2, but then it doesn’t really matter because the noise coming from your shotgun drowns all the other sounds). It has a fantastic backlit keyboard, and its screen produces a crisp, vivid image. But: the super-duper-magic-buttonless touchpad is just bad.</p> <p>Some features of the touchpad are actually nice. It’s nice that it’s so big, and I like the inertial scrolling. But it’s imprecise, way less precise than a proper <a href="http://en.wikipedia.org/wiki/Pointing_stick">trackpoint</a>. Also, I don’t usually use the gestures, which are so <em>revolutionary</em>. They’re neat if you want to show off to some friends who don’t have a Macbook, but in daily use I find them… difficult to perform. Perhaps it’s just something wrong with my hands, or my fingers – I don’t know. It’s just not comfortable. It’s funny that what I was initially afraid of hardware-wise was the super glossy screen, but I actually got used to it. But not the touchpad.</p> <p>And it would be even ok if the touchpad sucked – they all do – if OS X was better suited for keyboard control, but it’s not. Many, many things require mouse usage. You can’t open up a terminal and do an <code>apt-get update &amp;&amp; apt-get dist-upgrade</code>. You can update your Macports from the terminal, but any other updates you want to perform (via OS X’s internal system’s update mechanism or via the Mac App Store) require a mouse. Finder (a file manager and a shell for OS X user interface) is ok, but again – you have to click everything, you can’t use the keyboard for most tasks (or at least I don’t find it as comfortable as moving around the filesystem using Gnome’s Nautilus). There is no built-in interface that allows you to run an arbitrary command in OS X, like Alt+F2 that invokes a “Run program” window in Gnome/KDE. Sure, there are great 3rd party apps like <a href="http://qsapp.com/">Quicksilver</a>, <a href="http://www.obdev.at/products/launchbar/index.html">Launchbar</a> or <a href="http://www.alfredapp.com/">Alfred</a>, but only Quicksilver is free, and its development is rather stagnant (maybe not when compared to <a href="http://do.davebsd.com/">Gnome-Do</a>, but definitely when compared to <a href="http://userbase.kde.org/Plasma/Krunner">Krunner</a>). Managing windows sucks. <a href="http://soundandcomplete.com/2011/01/31/sizeup/">There’s no way to maximize a window with a keyboard shortcut other than using a 3rd party application</a>. Keyboard shortcuts are sometimes inconsistent amongst even standard apps that Apple ships with OS X, for example I’m never sure whether it’s Cmd+F or Cmd+Shift+F that I should hit to enter fullscreen mode. Oh and one last thing: in Gnome I can Alt+click any window in its arbitrary point, and then move it. This is very, very useful, and you can’t do it under OS X.</p> <p>It’s not all that bad, obviously. The biggest strength of the Mac is the way the apps are integrated. You can drag and drop everything into/onto anything. OS X is also very fast compared to Ubuntu+Gnome on a similar (or even faster…) hardware. Apple of course makes some other devices than computers these days (well who knew, huh?) and if you happen to have one of those, you’re living in an ecosystem where everything stays in sync. Your email (and not only Gmail-based), your contacts, your photos, music, videos, calendars (and not only Google Calendar!), notes, todos, and what have you. The iPhone can be a remote for your iTunes, and it can also be a remote for your presentation if you’re using <a href="http://www.apple.com/iwork/keynote/">Keynote</a>. It’s being constantly backed-up every time you sync it.</p> <p>Another enormous advantage over the FOSS world here are the applications themselves. Sure, I’m just a PhD student and not a graphics designer, and it’s true that most of the time I use free tools available for both platforms, such as Emacs, TeX, <a href="http://www.mendeley.com/">Mendeley</a>, Firefox, etc. But if you like photography, then no matter how amateur your skills are you will probably prefer using iPhoto rather than any photo management program for linux. Be it <a href="http://f-spot.org/">F-spot</a>, <a href="http://www.digikam.org/">Digikam</a> or <a href="http://yorba.org/shotwell/">Shotwell</a>, they’re no match for <a href="http://www.apple.com/ilife/iphoto/">iPhoto</a>. And there really isn’t any app available for linux you could compare to <a href="http://www.apple.com/aperture/">Aperture</a> or <a href="http://www.adobe.com/products/photoshoplightroom/">Adobe Lightroom</a>. It’s not all about graphics-related software, there are tons of great productivity apps, like <a href="http://culturedcode.com/things/">Things</a>. And if you hate OpenOffice as much as I do, you will definitely appreciate the speed, polish and overall neatness of <a href="http://www.apple.com/iwork/">iWork</a> (which is very, very cheap these days). The App Store has a terrible interface, but it’s very easy to buy programs using it, and most of these programs are cheap and good (quite often they’re brilliant). And in contrast to linux there are even games available for Macs. I know, there aren’t many, but then again compared to the linux market I feel overwhelmed (not that I buy or play any of these games, but the sole possibility of buying and downloading CoD feels good). It’s also funny that some of the free apps I know from linux actually run better on a Mac. Mendeley is more stable here. LyX is faster (probably due to better 2D graphics support).</p> <p>And finally, OS X is stable like hell. Ok, this may not be the best comparison, but let’s just say it’s very stable. I reboot it only when I travel by plane, because I’m a very paranoid and obedient person, and when the flight attendant asks to switch all electronic equipment off, I do actually switch my Macbook <em>off</em>. Other than that, it’s always on or suspended, or hibernated, or whatever. I don’t care about the uptime, and I’m never worried about any system crashes or colorful artifacts on my screen after I open up the display lid. Ubuntu 10.04 I’m using on my now-office-based HP EliteBook is generally also stable, but it likes to crash every now and then, especially after resume. My previous laptop, Dell Latitude D430 liked to crash as well, especially with the newer versions of Ubuntu. And my Thinkpad T40 was, how to put it, un-suspendable. I always had to shut it down if I wanted to close the lid, and then boot it up again.</p> <p>Ok, so why have I written it all down in such a lengthy post?</p> <p>First and foremost to show to my dear friends at the Dept. of Computer Engineering, that I’m not yet as much of an Apple fan boy as, for example, my supervisor is.</p> <p>Secondly, I wanted to put my thoughts in order, and blogging works miracles for me in this manner. You see, for me being part of the whole FOSS community was an important part of my life. The decision of going to Eplehuset, entering my PIN, confirming and leaving with a white paper box and a gayish computer inside it wasn’t an easy one. When I came back home I felt pretty sad, no excitement about the new hardware whatsoever (that is of course until I finally unpacked it). It took me a couple of months to convince myself that this was the right decision, and I had to share this with everyone who reads my blog, because (a) that’s the way I am and (b) because <em>what is written is properly confirmed in existence</em>.</p> <p>And finally, I wrote this post as a last of the <em>I bought a Mac, look how (un)cool it is</em> series. There will be no posts about these matters, and I don’t want to hear any more questions about it. Cheers.</p> Dagstuhl Seminar 11101: 'Reasoning about Interaction: From Game Theory to Logic and Back' 2011-03-13T16:19:04+00:00 http://piotrkazmierczak.com/2011/03/13/dagstuhl-seminar-11101-reasoning-about-interaction-from-game-theory-to-logic-and-back <p>I’m back in Bergen after another trip, this time to <a href="http://www.dagstuhl.de/en/about-dagstuhl/">Dagstuhl</a>, Germany, where I attended a seminar on logic and game theory. It was overall a very nice experience, especially due to the fact that Dagstuhl is a very nice place, and because it’s in the middle of nowhere it forces seminar attendees to be there all the time, hence talking to each other, exchanging ideas and experiences, and planning future projects together. I myself am still a small player when it comes to research, especially compared to most people that attended the seminar, but still through listening to talks and discussions, and then continuing those over numerous bottles of wine, I gained a lot and I bet I wouldn’t have so much ideas/knowledge exchange during an ordinary conference. I might even write some papers together with people I met in Dagstuhl, which I guess is the whole point of such meetings.</p> <p>I seriously recommend going to Dagstuhl if you’re invited there. It’s a place very well known (and prestigious) amongst researchers working in computer science, but not as much amongst those working in logic or game theory. Therefore if you’re wondering if it’s worth going to this remote castle somewhere in the woods of Saarland, hesitate no more. It definitely is.</p> <p>And just to finish this short post off, here’s <a href="http://www.flickr.com/photos/king_pest/sets/72157626249950488/">a link to some photos</a> I took during our trip to Bernkastel-Kues.</p> Philosophy of Social Sciences and Norwegian Mountains 2011-02-20T12:32:50+00:00 http://piotrkazmierczak.com/2011/02/20/philosophy-of-social-sciences-and-norwegian-mountains <p>I’m back in Bergen after a week spent literally in the middle of nowhere, or simply at <a href="http://www.vatnahalsen.no/index_eng.html">Vatnahalsen hotel</a>. I was attending a PhD course in “Philosophy of Social Sciences” and let me tell you a little bit about it.</p> <p>But first of all, why would I even attend such a course? After all, I’m not an anthropologist or a sociologist, but for some weird reasons I do belong to the Faculty of Social Science. Why? Because my supervisor doesn’t work at the Department of Computer Science, but at the Department of Information Science, which then belongs to the aforementioned faculty. Even though my work has nothing to do with social sciences, and even though I work at the Department of Computer Engineering (HiB), due to my affiliation with Information Science and in order to fulfill all the silly requirements of my PhD programme, I had to take this course. So how was it? Very good on one hand, and terrible on the other.</p> <p>The bad part was that during the lectures I hardly learned anything new. Even if they were thought provoking and somewhat inspiring (oh right, did I mention that I have to write a <em>philosophical essay</em> in order to pass this course?), the lectures simply established the truth I already know: that <em>continental</em> (i.e. non-analytic) approach to philosophy is either fundamentally flawed, or that I am completely unable to understand it (I prefer the former). I felt like I’m back in the 3rd year of my philosophy studies, listening about Foucault, Horkheimer, Habermas, Hegel, Derrida and Carl Schmitt. <a href="http://www.southasia.ox.ac.uk/staff_a-z_directory/staff2/srankin2">Faisal Devji</a>’s lecture about Gandhi (among other things) was a nice touch, but other than that I mainly listened to all the stuff I disliked most during my undergrad philosophy training. So that was the bad part.</p> <p>Since we are asked to write some philosophical essays relating our own research to philosophy of social sciences and/or ethics, we had some group sessions organized. What they did is they put 4-5 people from different departments into each group and asked us to discuss our research dilemmas. I have to tell you that before the Vatnahalsen course I was a typical <a href="http://xkcd.com/793/">physicist</a> – completely ignorant about what anthropologists, historians, economists and political scientists do, and obviously arrogant about how my solid (<em>cough</em>), formal research is substantially better than any other. Turns out these group sessions were the best part of the course, a true eye-opener. Both the suggestions from other discussion participants and listening about their projects were very beneficial for me.</p> <p>Apart from the substantial part of the course, we also had some free time and an opportunity to take the <a href="http://en.wikipedia.org/wiki/Flam_Line">Flåm railway</a> all the way down. For anyone visiting Norway as a tourist this is a must see, because the trip is breathtaking even when everything is covered in snow, so one can only imagine how beautiful it must be during the summer. I took <a href="http://www.fl ickr.com/photos/king_pest/sets/72157625957069613/with/5456233141/">some photos</a> with my phone but due to bad weather and due to the fact that iPhone 4 is not the best camera (despite what people say on the internet) they definitely don’t do any justice.</p> <p>Another intriguing element of the course is that it was held, as I mentioned already, in Vatnahalsen. Vatnahalsen is a hotel in the mountains, in a very remote place. It’s about 100 meters from a Vatnahalsen Flåmsbana station, and about 2kms from Myrdal, which means that in the winter the only way to get there is by train (from Myrdal or Flåm) or… by ski. Apart from the hotel, there’s nothing there. No internet connection, flaky GSM reception, and in case of any heating or water problems you need to wait one day for a plumber (probably from Voss or Geilo). We were the only guests in the hotel, there was lots of snow everywhere, and the place was built in the XIX century as a hospital for tuberculosis patients, so one could feel like <a href="http://en.wikipedia.org/wiki/The_Magic_Mountain">Hans Castorp</a> or <a href="http://en.wikipedia.org/wiki/The_Shining_(novel)">Jack Torrance</a>. Besides, even the nearest settlement, Flåm, can hardly be called a town – there’s about 320 people living there (plus approximately 1 million tourists every year). The nearest civilization is probably Voss, about 90 kms to the southwest.</p> <p>So, to wrap up this a bit too long and way too chaotic entry:</p> <ol> <li> <p>Stay away from continental philosophy (as a matter of fact, stay away from any philosophy if you can);</p> </li> <li> <p>Read about research people do in fields other than yours; trust me, they do interesting research;</p> </li> <li> <p>Go to Myrdal and take a train to Flåm if you haven’t done it yet.</p> </li> </ol> <p><strong>update:</strong> As one of my friends mentioned, I forgot about one thing: beer. What would be a week-long seminar in the mountains without a good beer, right? So if you happen to be in Flåm, visit <a href="http://aegirbryggeri.no"><em>Ægir Bryggeri</em></a> – a micro-brewery close to the train station. It’s owned by an American guy who’s been a bank manager in California and at some point of his life decided to quit the job, pack his stuff, go to Flåm, and start brewing beer. The business is going well, <em>Ægir Bryggeri</em> is the 2nd biggest micro-brewery in Norway now (I believe that the 1st one is <a href="http://www.nogne-o.com/"><em>Nøgne Ø</em></a>, but I’m not sure), and they do make some damn good beers. My personal favorite is the <em>India Pale Ale</em>, but you can’t buy it at the brewery (it’s 6,5 alc. so you can only buy it in a pub or at some Vinmonopolet), so just treat yourself with <em>Bøyla Blonde Ale</em> once you’re there. And for those outside Norway there’s good news: <em>Ægir Bryggeri</em> plans to start exporting its beers to the US, Belgium, The Netherlands and Germany (if I remember correctly).</p> Extracting audio from a DVD with mplayer — Mac OS X version 2011-01-23T21:19:35+00:00 http://piotrkazmierczak.com/2011/01/23/extracting-audio-from-a-dvd-with-mplayer-mac-os-x-version <p>I wrote about this problem <a href="http://soundandcomplete.com/2009/12/26/extracting-audio-from-a-dvd-with- mplayer/">some time ago</a>: say you have a concert DVD (<em>Depeche Mode: Touring the Angel Live in Milan</em> in my case) and would like to extract audio from the dvd, to use on a portable player for example. Furthermore, you’re picky and you don’t want any mp3 or AAC, only a lossless format. Well, luckily there’s a simple bash script for doing this:</p> <div class="highlight"><pre><code class="language-sh" data-lang="sh"><span class="k">for</span> f in <span class="sb"></span>seq <span class="m">1</span> 23<span class="sb"></span><span class="p">;</span> <span class="k">do</span> mplayer dvd://5 -chapter <span class="s2">&quot;${f}&quot;</span>-<span class="s2">&quot;${f}+1&quot;</span> -aid <span class="m">162</span> -ao pcm:file<span class="o">=</span><span class="s2">&quot;${f}&quot;</span>.wav:fast -vo null -vc null<span class="p">;</span> <span class="k">done</span></code></pre></div> <p>Unfortunately, it’s more difficult to make it actually run on OS X, but it’s possible. Here are the necessary steps to make it work:</p> <ol> <li> <p>Get <a href="http://www.mplayerhq.hu">mplayer</a>. I suggest getting it via <a href="http://www.macports.org/">MacPorts</a>, and preferably the <a href="http://trac.macports.org/browser/trunk/dports/multimedia/mplayer-devel/Portfile">mplayer-devel</a> package (supposedly less stable, but pulls much less dependencies, so it compiles faster).</p> </li> <li> <p>Get a <a href="http://www.askdavetaylor.com/step_through_count_numeric_values_bash_shell_script.html">script</a> that resembles the <code>seq</code> unix command, since OS X doesn’t have it.</p> </li> </ol> <p>And that’s it! After you have the .wav files you can turn them into whatever format you prefer with <a href="http://tmkk.pv.land.to/xld/index_e.html">XLD</a>. Enjoy!</p> In Defense Of The PhD 2011-01-09T16:49:00+00:00 http://piotrkazmierczak.com/2011/01/09/in-defense-of-the-phd <iframe border="0" scrolling="no" width="78" height="17" allowtransparency="true" frameborder="0" style="margin-bottom: -3px; z-index: 1338; border: 0px; background-color: transparent; overflow: hidden;" src="http://www.instapaper.com/e2?url=http%3A%2F%2Fpiotrkazmierczak.com%2F2011%2F01%2F09%2Fin-defense-of-the-phd%2F&amp;title=In+Defense+Of+The+PhD"></iframe> <p>Recently there’s been a lively discussion on why do people pursue PhD studies, is it good (for them and for the society), is it optimal (for the society and for the universities), and so on. The whole topic is by no means new, but since The Economist’s <a href="http://www.economist.com/node/17723223">recent publication</a>, <a href="http://pipeline.corante.com/archives/2011/01/07/the_phd_problem.php">other</a> <a href="https://twitter.com/irowan/status/23506930576138240">people</a> expressed their opinions.</p> <p>I’m 25, I’m a full-time PhD student, and I’d like to put in my oar now.</p> <p>First off, while The Economist’s article has a number of valid points, it’s very US- and UK-centric. Even though the author refers to some case-studies outside the Anglo-Saxon world, like Germany, Slovakia or Belgium, some of its arguments do not apply at all to most European countries. For example:</p> <blockquote> <p>One thing many PhD students have in common is dissatisfaction. Some describe their work as “slave labour”. Seven-day weeks, ten-hour days, low pay and uncertain prospects are widespread. You know you are a graduate student, goes one quip, when your office is better decorated than your home and you have a favourite flavour of instant noodle. “It isn’t graduate school itself that is discouraging,” says one student, who confesses to rather enjoying the hunt for free pizza. “What’s discouraging is realising the end point has been yanked out of reach.”</p> </blockquote> <p>We all read the <a href="http://www.phdcomics.com/comics.php">PhD Comics</a> and we all hear about how many hours of coursework or admin-duties a typical US grad student has. I don’t know how does it look like in other countries, but in Norway, Denmark, Holland and Belgium this is definitely <strong>not</strong> the case. At some Dutch universities, even if PhD students want to teach, they can’t do that (e.g. because there’s too many of them, or because they are considered underqualified, or whatever). My contract clearly states that I have to spend 25% of my time on teaching, and that’s exactly what I do. One quarter of my overall work time is not much, yet I still gain valuable teaching experience, so it’s a win-win. I know many of my friends who are PhD-students work as TAs for courses taught by their promoters, and that’s usually also not too much work. Apart from all that, a little bit of teaching looks good in your CV, especially if you want to apply for post-doc or other academic positions after finishing a PhD.</p> <blockquote> <p>There is an oversupply of PhDs. Although a doctorate is designed as training for a job in academia, the number of PhD positions is unrelated to the number of job openings.</p> </blockquote> <p>There probably is an oversupply of PhDs in the US and in the UK, fair point, but there isn’t one in Norway, and as far as I know not in any of the Nordic countries. Maybe it’s a peculiar situation here, but then again I hear that there’s too many PhD students in The Netherlands, yet all of my friends who recently graduated managed to get post-doc positions in the same country (yes, in some cases it took a while, but still).</p> <p>So let’s talk about the subject that generates most controversy: money.</p> <blockquote> <p>But universities have discovered that PhD students are cheap, highly motivated and disposable labour. With more PhD students they can do more research, and in some countries more teaching, with less money. A graduate assistant at Yale might earn $20,000 a year for nine months of teaching. The average pay of full professors in America was$109,000 in 2009—higher than the average for judges and magistrates.</p> </blockquote> <p>Again: US is not the whole world. I’m not going to quote numbers here, but a PhD student in Norway gets a very decent salary, even compared to industry salaries in technology sector. I’m not saying I earn more than a senior programmer at Google, but the money is more than good enough to rent a nice flat (not shared with anyone), eat out from time to time, travel virtually wherever I want and still being able to save some of my monthly pay. The article fails to understand a basic thing behind PhD students’ motivations, though: we’re not after the money. If we were, we wouldn’t be studying philosophy, logic, theoretical computer science or quantum physics. We’d go for an MBA, law or something similar, only to end up working our asses off for McKinsey, Boston Consulting, E&amp;Y or PWC. That is simply not our goal, and while many PhD candidates like to whine about how little cash they have, they either lie, or they simply shouldn’t be doing a PhD at all.<sup id="fnref:1"><a href="#fn:1" class="footnote">1</a></sup></p> <blockquote> <p>One OECD study shows that five years after receiving their degrees, more than 60% of PhDs in Slovakia and more than 45% in Belgium, the Czech Republic, Germany and Spain were still on temporary contracts. Many were postdocs. About one-third of Austria’s PhD graduates take jobs unrelated to their degrees. In Germany 13% of all PhD graduates end up in lowly occupations. In the Netherlands the proportion is 21%.</p> </blockquote> <p>Right, but the OECD study doesn’t show how many people without a PhD are on temporary contracts in Slovakia five years after receiving their degrees, be it bachelor or master’s.</p> <p>A major thing the article fails to understand is that most PhD students pursue an academic career for two reasons: because it’s their passion, and because they don’t seem to be able/willing to do anything else. Take a philosophy graduate for example, with a master’s thesis on German, late 18th century idealism. This person has two choices: either he goes for a <em>lowly occupation</em>, as the OECD study puts it, or enroll in a PhD program. Statistics suggests that our poor philosopher might still end up working for the man, somewhere in a call center selling insurance to people who don’t want to buy it, but going for a PhD is still better, because he can have 3-4 years of joyful academic life and then try his luck getting a tenure track job after a couple of years. Even if he fails, at least he tried.</p> <p>PhD students/graduates are usually lousy at finding jobs outside the universities not because they have a PhD degree, but because they’re <em>different</em>. Normal people don’t study philosophy, and if they’re into computer science, they don’t care whether P≠NP – they just learn Java, Objective-C, Python or whatever else they find useful for becoming a successful software engineer.</p> <p>And then finally, there’s one last thing everyone seems not to understand: once you finish your PhD, get done with the damn post-doc contract, and become a tenure-track researcher, you’re in the best job there is. You’re doing what you love, you have most of the time a flexible schedule, you supervise master’s and/or PhD students, you go to conferences all over the world. You write papers others comment on, and at some point you might even write a book (or co-author one). How amazingly cool is that? Oh you’re saying I’m a dreamer, and that simply never happens? Well what about those thousands of internet start-up companies? They <em>waste</em> their time as well, trying to become another Facebook or another Google. Yet they still do it, because it’s their dream to pursue.</p> <p>And so is academic career ours.</p> <p><a href="http://news.ycombinator.com/item?id=2085629">Discussion on HackerNews. </a></p> <div class="footnotes"> <ol> <li id="fn:1"> <p>Of course poor fellas trying to earn their degree with no scholarships in countries like Poland, Ukraine, etc. are excluded, but then again salaries in other professions are way lower in these countries, as are costs of living. <a href="#fnref:1" class="reversefootnote">&#8617;</a></p> </li> </ol> </div> Why I Can't Stick To One Web Browser 2011-01-02T19:19:00+00:00 http://piotrkazmierczak.com/2011/01/02/why-i-cant-stick-to-one-web-browser <p>Because they <strong>all suck</strong>.</p> <p>I think <a href="http://www.opera.com">Opera</a> is my favorite browser. I’ve been using it for many years, it’s fast, cross-platform, it was the first browser to support tabs, <a href="http://en.wikipedia.org/wiki/Features_of_the_Opera_ web_browser#Speed_Dial">speed dial</a> (with keyboard shortcuts – very useful!), and it’s always easy to block an arbitrary item of a website with Opera. However, among all the browser I’ve been using, Opera had problems with the biggest number of websites. Be it banks, Google Picasaweb, or some other sites – I can’t use Opera as my only browser. It always needs a helper program to handle the sites it doesn’t display properly, and that sucks. Especially that it’s always been a problem with this browser, which, given its other fantastically well designed features and its maturity as a software product (it’s been initially released in 1996!), doesn’t stop to amaze (and sadden) me.</p> <p>Then there’s <a href="http://www.mozilla.com/en-US/firefox/">Firefox</a>, which I’ve first tried when it was still called <a href="http://en.wikipedia.org/wiki/History_of_Mozilla_Firefox#Naming">Phoenix</a>. Firefox, upon its initial release, appealed to me because it was “like Opera, but more compatible”. Unfortunately, even early Phoenix builds seemed slow and bulky, and current versions are perhaps not as slow, but you can’t call them <em>fast</em> either. Another flaw of Mozilla’s flagship product is the variety of versions, and incompatibility of extensions from version to version. It happened to me many times, that after upgrading the package or the whole linux distro I was using at a time, some or all of my extensions in <code>$HOME/.mozilla</code> stopped working and didn’t want to upgrade. After one of the upgrades, FF didn’t even want to start, forcing me to erase all my personal settings, and, in consequence, to stop using it.</p> <p>And then a couple of years ago the almighty Google released its Chromium-based browser: <a href="http://www.google.com/chrome">Chrome</a>. Chrome is cool, because it’s fast, renders most websites properly, supports extensions, has something similar to speed dial (although doesn’t support keyboard shortcuts, which is a bad, bad thing), and it’s manufactured by Google, which makes it the trendiest browser among geeks and hipsters. But jokes aside, Chrome really is a great browser. The problem I’m having with Chrome it is that its tabs freeze quite often. Or even if they don’t freeze, their behavior is very often… erratic. I can’t explain it any better, and I really can’t think of any other reason not to like Chrome, but when I end up with 12 tabs that suddenly become unresponsive, I’m mad.</p> <p>So then I can switch to Apple’s browser – <a href="http://www.apple.com/safari">Safari</a>. I bought a Mac a couple of months ago, and an iPhone<sup id="fnref:1"><a href="#fn:1" class="footnote">1</a></sup> followed, so it’s kind of neat having all this synchronization, speed and… power efficiency (seriously, my Macbook Pro’s power estimates rise significantly when I’m running on battery and I quit Chrome and start Safari; seems quite reasonable to think that Safari is very well optimized for Mac OSX). However, Safari doesn’t run on linux and it probably never will, which is a major problem since I’m still using Ubuntu on my office computer (and I’m not willing to stop it). Furthermore, there are these small annoyances, like the fact that you can’t tell Safari to remember tabs’ contents from session to session, or that it doesn’t support keyword- based search queries in the address bar (or at least I don’t know how to make either of these features work). Oh, and when Safari crashes, or suddenly eats all the CPU and memory, and I have to kill it, there’s no way to recover anything from the lost session. And no dialog window asking if I want to submit a crash report either. Weird. Then again <a href="http://www.quakelive.com">Quakelive</a> supports Safari, and that’s crucial for my PhD.</p> <p>So here I am: a web-browser-hopper. Frustrated by flaws of one browser and tempted by advantages of another one, I keep changing them every now and then. And I sometimes wonder: why isn’t there one browser I could simply use all the time? Or is it something wrong with me?</p> <p><em>(I apologize my readers for more than 2 months of silence here; blogging is about writing in regular units of time, but I was a little bit busy lately; hopefully a hiatus that long will not happen again)</em></p> <div class="footnotes"> <ol> <li id="fn:1"> <p>I was actually about to write a post about my iPhone acquisition and related topics, but I realized that writing about how awesome iPhone is would be kinda lame. I might still write something about it at some point, but not today. <a href="#fnref:1" class="reversefootnote">&#8617;</a></p> </li> </ol> </div> Confessions of a linux-to-mac convert — week 3 2010-10-10T20:25:38+00:00 http://piotrkazmierczak.com/2010/10/10/confessions-of-a-linux-to-mac-convert-e28094-week-3 <p>This post is about why this great computer sucks (a little). Here we go:</p> <ul> <li> <p>First of all: the keyboard. It’s not MBP’s or Apple’s fault, it’s just that I’m using a normal (non-Apple) keyboard at work, and I still cannot get used to the fact that Gnome and OSX do not use the same keyboard shortcuts. I keep hitting Ctrl instead of Cmd, and I don’t like the fact that F1–F12 have to be activated with Fn (it’s possible to switch that off, but then the Mac-specific function keys would require Fn to work, which would be even worse). I guess it wouldn’t be a problem if I used only OSX.</p> </li> <li> <p>Secondly: the touchpad. It’s neat, it supports multi-touch and it’s very fancy, but… it’s not very precise. There are some multi-touch features which I can seldom activate the first time I try, usually I have to try at least three times for the gestures to be recognized properly (that applies especially to four- and three-finger gestures). Also, I find myself clicking not the icon I want in my dock. As expected, nothing beats the old Thinkpad’s trackpoint.</p> </li> <li> <p>The ambient light sensor works flawlessly for the screen, adjusting the brightness properly when necessary, but it doesn’t work as well for the keyboard. It usually lids the keyboard up to full brightness when in bright environment, and dims it when it’s dark – looks like it’s just one sensor for both screen and keyboard.</p> </li> <li> <p>I terribly miss apt-get and Debian repositories. Getting software and having it up-to-date all the time can’t be easier than that.</p> </li> <li> <p>I also miss the focus-follows-mouse feature that is implemented in <strong>every</strong> linux window manager I know, but is not supported by OSX.</p> </li> <li> <p>I still can’t get used to the windows vs. applications division, so I find it very annoying that I can’t cycle through all my windows with Cmd+Tab. Also, I’m using a Norwegian keyboard layout which places the ‘’ key right next to left shift – it’s really uncomfortable to use Cmd+ to switch windows within one program.</p> </li> <li> <p>Oh did I already mention that you can’t assign a keyboard shortcut to a basic window manager action such as ‘maximize window’? This is <strong>very</strong> annoying.</p> </li> </ul> <p>But even though the list above seems long, the Macbook Pro has one fantastic advantage: <em>it works</em>. Nothing crashes, the display doesn’t <em>lose</em> its resolution, the system doesn’t greet me with a kernel panic after I resume it from suspend and it remains noiseless even under stress. All in all, I still think it’s the best computer I’ve ever owned.</p> Confessions of a linux-to-mac convert — week 1 2010-09-26T17:56:57+00:00 http://piotrkazmierczak.com/2010/09/26/confessions-of-a-linux-to-mac-convert-week-1 <p>First of all, a word about the hardware. Simply speaking, the unibody Macbook Pro 13’’ is the most sturdy and well-made computer I’ve ever owned (or at least that’s my impression after a week of usage). The keyboard is brilliant (and backlit!), the touchpad feels great, the display, although awfully glossy, is very, very bright, and produces a crisp and vivid image (and what’s very nice, it’s the first display where the ambient light sensor which automatically adjusts screen and keyboard brightness actually works properly – not a case for HP EliteBook or Dell D430), and of course the unibody enclosure has no flex whatsoever. This computer is also the fastest one I’ve ever had, although it’s only an entry-level MBP with the slowest available processor and a 5400 rpm hdd. But comparing technical specifications of computers makes no sense with a Mac. If we take only tech specs of my HP EliteBook into account, it should be a faster machine, but in fact it’s not. Neither <a href="http://nepomuk.kde.org/">Nepomuk</a> nor <a href="http://projects.gnome.org/tracker/">Tracker</a> (I intentionally omit <a href="http://beagle-project.org/Main_Page">Beagle</a>, which is even slower than the two aforementioned ones) were ever able to fully index my home directory’s content without rendering the laptop unusable, even though the hdd on the HP is 7200 rpm. <a href="http://en.wikipedia.org/wiki/Spotlight_(software)">Spotlight</a> on the other hand indexed everything in a completely effortless way – I didn’t even know there was some indexing going on.</p> <p>Apart from its speed I also admire MBP’s weight and battery life. It does weigh more than it looks (as with all Apple laptops), but it’s still perfectly good. I’m writing this post on an airplane from Spain, where I’ve been carrying it in my bag everyday (together with a Nikon D40 and some other stuff), and the bag never felt too heavy. Not a case for my HP, which technically is only 1/2 kg heavier, but requires a bulky brick-like battery charger. And that’s where we reach the hot topic of battery life.</p> <p>People keep asking me if it’s true that the MBP has juice for 10 hrs, and I really don’t know. Power management usually reports an estimate of about 9 hrs after a full recharge (wifi on), but I don’t know if it’s true. Sometimes the estimate grows to more than 11 hrs if I dim the display, sometimes falls below 5 hrs if I import an SD card full of raw files into iPhoto, but what’s important to me is that I don’t have to worry about my battery at all. I literally don’t care, and I didn’t have to take a charger with me whenever I left the hotel in Valencia. I could surf as much as I needed, write long emails, and I often use the display at full brightness to avoid glare. That’s precisely what I wanted – I can finally stop thinking about battery life.</p> <p>So let’s move to the software now, shall we? In essence, it’s like Karolina once put it: Mac OS X feels like Ubuntu after 10 (or more) years of polish. It’s no secret that Gnome is in big part inspired by Aqua UI, but when you use OS X you see there are tons of little things that make it a lot, lot more polished. The level of integration between Mac OS apps is something I especially admire. If I want to insert a photo in my email (composed in Mail.app), I can browse regular files, but I can also choose from iPhoto albums. If on the other hand I want to tag faces in iPhoto with names, it will autocomplete names if they resemble entries in my address book. Calendar tasks integrate with Mail.app and other programs (Dashboard widgets, Spotlight). The interface of programs is consistent, so even if you’re new to Mac OS as I am, finding your way through most programs is not a problem, because things are where you’d expect them to be.</p> <p>But fear not, I haven’t turned into an Apple-fanboy (yet!), and I do find some things frustrating. First of all, the display. Yes, it’s crisp, bright, vivid, and you can actually get used to it (I’m nearly there), but if I could have a matte option for the 13’’ model I wouldn’t hesitate for a second. Secondly, every window manager available for linux beats the WM Aqua uses. It doesn’t support the “focus follows mouse” feature, it doesn’t allow to move windows with Alt+Left mouse button (this moves a window if clicked in arbitrary point in Gnome), and I still haven’t got used to the difference between hiding applications (Cmd+h) and minimizing windows (Cmd+m), or switching between applications (Cmd+Tab) and windows within an application (Cmd+). Oh, and one last big pain: there is no way you can assign a keyboard shortcut to maximize a window in OS X – very annoying.</p> <p>One last thing that I’d like to share with my readers after a week of using my Mac – don’t criticize it unless you try it. I used to be one of the Arrogant Linux Elitists, saying that Mac is a terrible choice without actually ever trying it. Don’t do that. Go give it a try, and if you really don’t like you can always return it to the shop (although I’ve heard you can’t do it in Norway for some reason, but you should be able to do it in Poland, and you can do it for sure in UK and the US. Also, I’d like to thank the person whose arguments convinced me to try a Mac – <a href="http://www.marco.org/about">Marco Arment</a>. Go <a href="http://www.marco.org/26335880">read his posts</a>, it’s worth it.</p> <p>(stay tuned for more linux-to-mac conversion confessions!)</p> 100 prisoners and a light bulb 2010-08-20T14:32:41+00:00 http://piotrkazmierczak.com/2010/08/20/100-prisoners-and-a-light-bulb <p>There are days when I feel particularly proud of myself, and today is one of those days.</p> <p>It’s Friday the 20th of August, that is the last day of <a href="http://esslli2010cph.info">ESSLLI 2010</a>. The morning lecture was the last lecture of <a href="http://personal.us.es/hvd/">Hans van Ditmarsch’s</a> <a href="http://plato.stanford.edu/entries/logic-epistemic/#3">DEL</a> course, and at the end of it he presented a “100 prisoners and a light bulb” puzzle, asking us for the solution.</p> <p>Unexpectedly, I’ve found the solution, but didn’t dare saying it aloud, since I was convinced it was wrong. Once prof. van Ditmarsch told everyone what it was, I was still convinced it can’t be true, and even Karolina (who understood everything very well) wasn’t able to convince me that it actually works. That’s a perfect example how <a href="http://en.wikipedia.org/ wiki/Epistemic_modal_logic#The_positive_introspection_axiom">positive introspection</a> doesn’t apply to some agents (i.e. me).</p> <p>Here’s the puzzle (taken directly from Hans van Ditmarsch’s slides), go on and try to figure out a solution:</p> <blockquote> <p>A group of 100 prisoners, all together in the prison dining area, are told that they will be all put in isolation cells and then will be interrogated one by one in a room containing a light with an on/off switch. The prisoners may communicate with one another by toggling the light-switch (and that is the only way in which they can communicate). The light is initially switched off. There is no fixed order of interrogation, or interval between interrogations, and the same prisoner may be interrogated again at any stage. When interrogated, a prisoner can either do nothing, or toggle the light-switch, or announce that all prisoners have been interrogated. If that announcement is true, the prisoners will (all) be set free, but if it is false, they will all be executed. While still in the dining room, and before the prisoners go to their isolation cells (forever), can the prisoners agree on a protocol that will set them free?</p> </blockquote> Growing linux frustration 2010-08-07T14:07:07+00:00 http://piotrkazmierczak.com/2010/08/07/growing-linux-frustration <p>I’ve already mentioned my linux-related laptop problems <a href="http://soundandcomplete.com/2009/11/09/how-ive-stopped-being-a-desktop- linux-enthusiast/">some time ago</a>. Some things changed since then. Canonical released a new version of Ubuntu, 10.04, which in my opinion is a huge improvement over 9.10, and I got a new laptop (kindly provided by <a href="http://www.hib.no">HiB</a>), an <a href="http://h10010.www1.hp.com/wwpc/no/no/sm/WF25a/321957-321957-6 4295-3955549-3955549-3688868.html">HP EliteBook 6930p</a>. Old problems are gone, but new have arisen.</p> <p>At first it all seemed ok. I’ve installed Ubuntu 10.04 and didn’t have to tweak anything. Wireless, bluetooth, suspend/resume – all worked automagically. Except graphics.</p> <p>My laptop has a built-in Intel 4500 graphics board. Most of the time it works fine, hardware acceleration and dual-display mode included. It’s also quite fast for my needs – flash videos work with no frame-dropping, HD films as well, and Quakelive works smoothly (the last one especially relevant to my research). But from time to time, completely randomly, weird annoying things happen.</p> <p>First weird annoying thing is the Non Existing Display problem (which we shall henceforth refer to as NED). It goes like this: I power on the machine, the kernel boots, plymouth loads, and the GDM screen… well, it also loads, because I can hear the bongos, but it’t not visible. The thing is, GDM login window is being displayed on the NED. If I simply press enter and put my password, it will log me in, and in most cases I will see my desktop. If not, I can use Gnome-Do to evoke the display configuration panel. Once it opens, the screen usually flickers and realizes that there’s only one display connected, or, ontologically speaking, that the NED indeed does <strong>not</strong> exist (as the name clearly suggests). If it can’t realize the obvious truth immediately, it will do it after a couple of clicks in the display configuration panel. If not after a couple, then after a couple more, but anyway after some time the display works correctly. That doesn’t mean Ubuntu won’t have any doubts as to the NED’s ontological status anymore, and that’s the most annoying part.</p> <p>The second weird annoying thing is the Proper Resolution Holding problem (which we shall henceforth refer to as PRH). Imagine a situation like this: you have your Emacs open and you’re working on some non-trivial piece of code. As any programmer will tell you, this requires utmost concentration. I often have situations like this, perhaps even more often than other people, because most programming problems are non-trivial for me, since I’m a bad programmer. Anyway, I have my Emacs open, and I’m thinking deeply about some problem. If I keep thinking for more than 9:59 without touching the mouse/keyboard, e.g. reading the algorithm description from a printed article, the screensaver will go on. And then <strong><em>boom!</em></strong>, the displays go crazy. Oh right, did I mention I’m using dual display configuration? I guess I didn’t, but I don’t think having an external display connected to your laptop is something fancy in 2010. Anyway, when the screensaver wants to switch on, X.Org turns the <em>mirroring mode</em> for my displays, and sets 1024x768 resolution on both screens. Unfortunately, the only way to solve this situation is to save any work I have, switch to a virtual console 1 with Alt+F1, execute <code>sudo service gdm restart</code> and hope for the best.</p> <p>Display problems occur randomly while trying to change laptop screen’s brightness too. And of course after resuming from suspend, but thankfully this happens really seldom, like one in fifty suspends. When it does, however, the only way to bring your display back to work is to forcibly reboot the laptop.</p> <p>There are more problems, like the silent microphone (no matter what I do it’s just too quiet for most people to hear me via voip), short battery life (i.e. much shorter than on windows), and terribly bad trackpoint/touchpad support (i.e. much worse than on windows), but these problems I could live with. The graphics related annoyances are just too much. And the worst thing is that I no longer know which graphics board should I recommend to people who want the best linux experience. Nvidia? Yes, but only with closed-source drivers, although some people claim that nouveau work well. Ati? Well, I remember both mine and Karolina’s problems with our Radeons, so that’s a no. Intel? As far as I recall everyone always told me that Intel chipset based products (graphics, wifi, ethernet) are always best for linux, but ever since the introduction of <a href="http://en.wikipedia.org/wiki/Mode-setting#Linux">KMS</a>-enabled drivers this is apparently no longer true. By the way, my case is nothing compared to a case of a new PhD student in our department. He’s new, so he’s got a newer laptop. Good for him? Not quite. Not a single linux distro supports his brand new Intel HD graphics.</p> <p>Now the obvious question is: did I try to fix my problems? Yes and no. Yes, I’ve searched the forums, and yes, I’ve tried some solutions. None of them worked. There probably are some new tips, new kernel releases I could compile, new patches I could apply, but no – thanks, I don’t want to. I’m too old. With all my previous computers it was tuning and tweaking all the time. Thinkpad T40 needed a custom TuxOnIce-patched kernel for suspend to disk to work (suspend to ram made no sense, the battery was too old and I was loosing too much power even during suspend). Dell Latitude D430 had huge problems with newer Intel graphics drivers. There was always something I needed to tune. It’s like this joke about Lancia owners – <em>they like tinkering with their cars in a garage</em>, which is only a nice way of saying that their cars won’t work <em>unless</em> tinkered with.</p> <p>I’ve been a linux user since about 1999, and during that time I’ve been using linux exclusively on all my computers. First it was <a href="http://arstechnica.com/linux/reviews/1q99/suse-1.html">SuSE 6.0</a> and RedHat Manhattan (was it 5.1?). Then different RedHat versions for a short while, then Slackware for a long time, then Debian, Gentoo, Arch, and finally Ubuntu, since somewhere around 2005. In fall 2010 I’ll stop using a linux-based operating system on my home computer, and I don’t mean switching to some BSD (huh, been there!). I need a second computer, so I won’t have to carry my laptop in a rucksack all the time (I moved to Fyllingsdalen and I work at HiB – everyone who knows Bergen sees the reason). It will be some Windows 7 based computer, or a product of one Cuppertino-based company.</p> <p>Either way, I feel sad.</p> Continuous list enumeration throughout the document with LaTeX 2010-06-28T13:23:11+00:00 http://piotrkazmierczak.com/2010/06/28/continuous-list-enumeration-throughout-the-document-with-latex <p>Karolina asked me today to create a macro for having a continuous list enumeration throughout the whole document, i.e.</p> <blockquote> <p>This is the first list:</p> <ol> <li>Item; </li> <li>Another item;</li> </ol> <p>And here goes the second list:</p> <ol> <li>Third item; </li> <li>And yet another item.</li> </ol> </blockquote> <p>You can obtain an effect like that by using LaTeX counters and a custom definition of your own enumerate environment. First, we need to <code>\usepackage{enumerate}</code>, and then define the following counter and an environment in the preamble:</p> <div class="highlight"><pre><code class="language-latex" data-lang="latex"><span class="k">\newcounter</span><span class="nb">{</span>enumi<span class="nb">_</span>saved<span class="nb">}</span> <span class="k">\newenvironment</span><span class="nb">{</span>myenumerate<span class="nb">}</span> <span class="nb">{</span> <span class="k">\begin</span><span class="nb">{</span>enumerate<span class="nb">}</span><span class="k">\setcounter</span><span class="nb">{</span>enumi<span class="nb">}{</span><span class="k">\value</span><span class="nb">{</span>enumi<span class="nb">_</span>saved<span class="nb">}}}</span> <span class="nb">{</span><span class="k">\setcounter</span><span class="nb">{</span>enumi<span class="nb">_</span>saved<span class="nb">}{</span><span class="k">\value</span><span class="nb">{</span>enumi<span class="nb">}}</span><span class="k">\end</span><span class="nb">{</span>enumerate<span class="nb">}}</span></code></pre></div> <p>After that, you can use <code>myenumerate</code> and you’ll have a continuous enumeration in the whole document.</p> <p>Oh and some credits: I wouldn’t come up with a solution if I haven’t read <a href="http://texblog.wordpress.com/2007/07/25/counters-in-latex/">this</a> post, and <a href="http://www.f.kth.se/~ante/latex.php">this</a> website. Huge thanks to the authors for their tips!</p> On Haskell 2010-05-23T13:00:26+00:00 http://piotrkazmierczak.com/2010/05/23/on-haskell <iframe border="0" scrolling="no" width="78" height="17" allowtransparency="true" frameborder="0" style="margin-bottom: -3px; z-index: 1338; border: 0px; background-color: transparent; overflow: hidden;" src="http://www.instapaper.com/e2?url=http%3A%2F%2Fpiotrkazmierczak.com%2F2010%2F05%2F23%2Fon-haskell%2F&amp;title=On+Haskell"></iframe> <p>Although I’ve always wanted to become a professional programmer, I never became one. I studied philosophy and went into a PhD programme in computer science because of my interest in formal logic. I like computers very much, I have professional experience in UNIX administration, and I’ve done a lot of Perl/Bash/Tcsh scripting, but I’ve never actually written any non-trivial piece of programming code. Whether you want to model something, verify, or check your proofs, being able to write a computer program that helps you with some task really comes in handy. And then there’s this question: what programming language should a person interested in logic/mathematics (without any CS background) learn?</p> <p>The first obvious choice for people interested in logic is <a href="http://en.wikipedia.org/wiki/Prolog">Prolog</a>. It’s relatively easy to learn, but after some time playing with it we discover that it’s quite limited, and not too efficient. Java is faster, easy as well and more versatile, but for <em>very high-level</em> programming (theorem provers, model checkers) it takes a lot of time to implement ideas, especially when compared to Prolog. Then there are other nice suitable languages like Python (very generic), LISP/Scheme (rather old, yet still very powerful), and finally Haskell.<sup id="fnref:1"><a href="#fn:1" class="footnote">1</a></sup></p> <p>Haskell is a general purpose <a href="http://en.wikipedia.org/wiki/Static_types#Static_typing">statically- typed</a> <a href="http://en.wikipedia.org/wiki/Purely_functional">purely functional</a> programming language. It supports <a href="http://en.wikipedia.org/wiki/Lazy_evaluation">lazy evaluation</a>, <a href="http://en.wikipedia.org/wiki/Type_class">typeclasses</a> and <a href="http://en.wikipedia.org/wiki/Type_polymorphism">type polymorphism</a>. It provides an enormous set of tools for the programmer, while being far more efficient and flexible than, say, Prolog. Due to its nature it also imposes some discipline on the programmer (for example, static typing prevents a number of errors on the level of compilation), making programming more rigorous and efficient. ESR <a href="http://esr.ibiblio.org/?p=1796">recently wrote</a> about Haskell:</p> <blockquote> <p>Haskell is built around a handful of powerful primitive concepts and a <em>pons asinorum</em>. The most pervasive of these, purely functional programming without side effects or variables, is generally described in introductions to Haskell as the most difficult barrier for most programmers arriving from conventional imperative or OO languages like C, C++, and Python. And yes, if your mental model of programming is all about for-loops and static variables — or, for that matter, objects! — learning to think in Haskell is going to be quite a wrench. There are reasons to make the effort. Haskellers (Haskellites? Haskellians? Haskellators? Haskelletons?) maintain that imperative programming relies heavily on side effects that push proving the correctness of programs to somewhere between impractically difficult and impossible. They also like to point out that side effects make programs difficult to automatically parallelize across multiple processors, an increasingly important consideration as multicores become the rule rather than the exception.</p> </blockquote> <p>That’s true, Haskell is not a trivial language to learn. I’ve been learning it for a while now, and I’m still far from saying that I actually <em>know</em> Haskell. Lazy evaluation and purely functional approach make it especially hard to switch from imperative way of thinking in the beginning. It’s difficult to learn, but the effort is worth taking. “Discrete Mathematics Using a Computer” justifies the effort like this:</p> <blockquote> <p>Pure functional languages like Haskell, as well as mathematics itself, are demanding in that they require you to think through a problem deeply in order to express its solution with equations. It’s always possible to hack an imperative program by sticking an assignment in it somewhere in order to patch up a problem, but you cannot do that in a functional program. On the other hand, if our goal is to build correct and reliable software — and this should be our goal! — then the discipline of careful thought will be repaid in higher quality software.<sup id="fnref:2"><a href="#fn:2" class="footnote">2</a></sup></p> </blockquote> <p>I can also add that Haskell forces a programmer to study some aspects of theoretical computer science in a way other languages don’t. It’s a bit like with LISP – you have to know something about lists, trees, recursion, higher- order functions, etc., otherwise you won’t be able to learn it. On the other hand I’d risk saying that it’s possible to learn for example Perl without getting into theory of programming too much (but perhaps I’m wrong here).</p> <p>So if it’s all so hard, how should one learn Haskell? That very much depends on your level of programming literacy (in general, not necessarily functional programming literacy), amount of time you want to spend, and your motivations behind learning Haskell. I once told my PhD supervisor that I actually know of 3,5 good books on Haskell programming:</p> <ol> <li> <p>“<a href="http://learnyouahaskell.com">Learn you a Haskell for great good</a>” – not a book really, rather an online tutorial with lots of funny pictures; among the free tutorials it’s the best one I know;</p> </li> <li> <p>“<a href="http://book.realworldhaskell.org">Real world Haskell</a>” – currently the most famous Haskell book I guess; it’s a bit like Seibel’s “<a href="http://www.gigamonkeys.com/book/">Practical Common Lisp</a>”, only on Haskell; even if you’re not into web development or databases, this book is the best introduction to Haskell and functional programming I found; oh, and it’s free for online reading, but you can always grab a printed copy for ~$50;</p> </li> <li> <p>“<a href="http://www.dcs.gla.ac.uk/~jtod/discrete-mathematics/">Discrete Mathematics Using a Computer</a>” – this is definitely a must read for anyone interested particularly in using Haskell for solving logical and/or mathematical problems; it’s really great and focuses on logic, recursion, set theory and so on, and still provides a good introduction to Haskell;</p> </li> <li> <p>“<a href="http://homepages.cwi.nl/~jve/HR/">The Haskell Road to Logic, Maths and Programming</a>” – another book focusing mainly on logical and mathematical applications; it’s good, but I found it very difficult and although authors say they don’t assume any background in functional programming, they actually do assume quite a lot (at least that was my impression).</p> </li> </ol> <p>All the books listed above are good, but I think the order in which I put them corresponds to their difficulty level. Not exactly, though: “Real World Haskell” can get pretty dense, but it introduces everything quite gently. “The Haskell Road to Logic…” on the other hand is in my opinion difficult throughout its whole length.</p> <p>I strongly recommend everyone (especially to fellow logicians) to at least give Haskell a try, it’s definitely worth it. And if you happen to live in Bergen and would like to meet to discuss some Haskell-related stuff, there’s an informal group of people, consisting of me and three of my friends. Let us know if you’d like to join us in <em>haskelling</em>.</p> <div class="footnotes"> <ol> <li id="fn:1"> <p>Let me make one thing clear here. This post is not <em>against</em> other programming languages. I acknowledge Java, Python and Prolog’s usefulness. The post is just about emphasizing Haskell’s pros. No war intended. <a href="#fnref:1" class="reversefootnote">&#8617;</a></p> </li> <li id="fn:2"> <p>O’Donnell/Hall/Page, <em>Discrete Mathematics Using a Computer</em>. <a href="#fnref:2" class="reversefootnote">&#8617;</a></p> </li> </ol> </div> Emacs as the Ultimate LaTeX Editor 2010-05-13T13:01:00+00:00 http://piotrkazmierczak.com/2010/05/13/emacs-as-the-ultimate-latex-editor <iframe border="0" scrolling="no" width="78" height="17" allowtransparency="true" frameborder="0" style="margin-bottom: -3px; z-index: 1338; border: 0px; background-color: transparent; overflow: hidden;" src="http://www.instapaper.com/e2?url=http%3A%2F%2Fpiotrkazmierczak.com%2F2010%2F05%2F13%2Femacs-as-the-ultimate-latex-editor%2F&amp;title=Emacs+as+the+Ultimate+LaTeX+Editor"></iframe> <p>Everyone knows, that <a href="http://www.gnu.org/software/emacs/">GNU Emacs</a> is <a href="http://www.dina.dk/~abraham/religion/">THE Best Programmer’s Editor</a>. Not everyone knows, though, that when you combine it with <a href="http://www.gnu.org/software/auctex/">AUCTeX</a> macros, it also becomes <strong>THE</strong> Best Editor for LaTeX.</p> <p>The biggest problem with Emacs is that it’s not a particularly intuitive piece of software, to say the least, hence many users flee after their first encounter with it. Emacs has its complicated keyboard shortcuts, enormous documentation and config files written in a Lisp dialect (called <a href="http://en.wikipedia.org/wiki/Emacs_lisp">Emacs lisp</a>), so at first it might seem very unpleasant using it. However, once <em>tamed</em>, it becomes your best friend.</p> <p>I’d like to present some tips that customize Emacs making it a perfect and very sophisticated editor for LaTeX. Most of these ideas are taken from various config files, howtos and other resources found on the web. Some of them are mine, but I can no longer tell which.</p> <p>First things first: you need to get Emacs and AUCTeX, and get it running.</p> <p>Every major linux distro comes with both Emacs and AUCTeX available via package systems. In Ubuntu, you just type <code>sudo apt-get install emacs23 auctex</code> and you’re laughing. Emacs is also <a href="http://ftp.gnu.org/gnu/emacs/windows/">available</a> for Windows, and AUCTeX website has <a href="http://www.gnu.org/software/auctex/download-for-windows.html">instructions</a> on how to set it up with Windows systems. Mac users have a choice of setting up either <a href="http://homepage.mac.com/zenitani/emacs-e.html">Carbon Emacs</a> (a version closer to original GNU Emacs) or <a href="http://aquamacs.org/">Aquamacs</a> (an Emacs variant supporting tabs and other nice tweaks; preferred Emacs package by all Mac users I know, Karolina included). Full comparison of Mac Emacs variants is available <a href="http://aquamacs.org/feature-matrix.shtml">here</a>, so you can make your own choice. Both Carbon Emacs and Aquamacs come with AUCTeX bundled, so there’s no need to download additional packages.</p> <p>After running Emacs and loading a TeX file (<code>C-x C-f file_name.tex</code>), AUCTeX should load itself automatically. If it doesn’t happen, you can invoke it with <code>M-x tex-mode</code>, or you can put the following into your <code>$HOME/.emacs</code> file:</p> <div class="highlight"><pre><code class="language-cl" data-lang="cl"><span class="p">(</span><span class="k">setq</span> <span class="nv">TeX-auto-save</span> <span class="no">t</span><span class="p">)</span> <span class="p">(</span><span class="k">setq</span> <span class="nv">TeX-parse-self</span> <span class="no">t</span><span class="p">)</span> <span class="p">(</span><span class="k">setq</span> <span class="nv">TeX-save-query</span> <span class="no">nil</span><span class="p">)</span> <span class="c1">;(setq TeX-PDF-mode t)</span></code></pre></div> <p>The options above will make sure, that AUCTeX macros are loaded every time a TeX file is opened. The last option, <code>;(setq TeX-PDF-mode t)</code>, is commented (all lines beginning with <code>;</code> are a comment in Emacs Lisp), but you can uncomment it if you want to have PDFLaTeX mode enabled by default for all documents.</p> <p>AUCTeX has a number of nice features, the two I use most often are:</p> <ul> <li>automatic formatting of a section: <code>C-c C-q C-s</code>;</li> <li>section preview: <code>C-c C-p C-s</code>; (see the screenshot on the right)</li> </ul> <p><img src="/images/emacs-latex-preview.png" class="small" /></p> <p>Preview function is very nice, because you can <em>see</em> the commands that are <em>behind</em> preview images, edit the code, apply preview again and see the results — no need to parse the whole file too often, and most importantly no need to switch to a PDF/PS viewer to see if your math formula/xypic tree is formatted correctly. Trust me, this saves a lot of time.</p> <p>AUCTeX has many many more features, and you can always consult its <a href="http://www.gnu.org/software/auctex/documentation.html">documentation</a> if you want to learn more. It’s a little bit overwhelming, but learning it is a very good investment, especially if you work with TeX a lot. But there are more packages that provide features which make your life easier.</p> <p><a href="http://flymake.sourceforge.net/">Flymake</a> is one of those packages. It enables Emacs to check the syntax of your TeX file on-the-fly. To turn it on, put the following code in your <code>$HOME/.emacs</code>:</p> <div class="highlight"><pre><code class="language-cl" data-lang="cl"><span class="p">(</span><span class="nb">require</span> <span class="ss">&#39;flymake</span><span class="p">)</span> <span class="p">(</span><span class="nb">defun</span> <span class="nv">flymake-get-tex-args</span> <span class="p">(</span><span class="nv">file-name</span><span class="p">)</span> <span class="p">(</span><span class="nb">list</span> <span class="s">&quot;pdflatex&quot;</span> <span class="p">(</span><span class="nb">list</span> <span class="s">&quot;-file-line-error&quot;</span> <span class="s">&quot;-draftmode&quot;</span> <span class="s">&quot;-interaction=nonstopmode&quot;</span> <span class="nv">file-name</span><span class="p">)))</span> <span class="p">(</span><span class="nv">add-hook</span> <span class="ss">&#39;LaTeX-mode-hook</span> <span class="ss">&#39;flymake-mode</span><span class="p">)</span></code></pre></div> <p>Beware, though — flymake consumes quite a lot of CPU power, especially when used with large files (and paradoxically large files make it most useful).</p> <p>On the other hand, spell-checking while you type isn’t so cpu consuming, and you can turn it on with:</p> <div class="highlight"><pre><code class="language-cl" data-lang="cl"><span class="p">(</span><span class="k">setq</span> <span class="nv">ispell-program-name</span> <span class="s">&quot;aspell&quot;</span><span class="p">)</span> <span class="c1">; could be ispell as well, depending on your preferences</span> <span class="p">(</span><span class="k">setq</span> <span class="nv">ispell-dictionary</span> <span class="s">&quot;english&quot;</span><span class="p">)</span> <span class="c1">; this can obviously be set to any language your spell-checking program supports</span> <span class="p">(</span><span class="nv">add-hook</span> <span class="ss">&#39;LaTeX-mode-hook</span> <span class="ss">&#39;flyspell-mode</span><span class="p">)</span> <span class="p">(</span><span class="nv">add-hook</span> <span class="ss">&#39;LaTeX-mode-hook</span> <span class="ss">&#39;flyspell-buffer</span><span class="p">)</span></code></pre></div> <p>Another nice package is the <a href="http://www.gnu.org/software/emacs/manual/html_node/emacs/Outline-Mode.html">Outline Mode</a>. It allows the user to <em>hide</em> some parts of the text file, which makes working with large files much easier. To enable it, put the following in <code>$HOME/.emacs</code>:</p> <div class="highlight"><pre><code class="language-cl" data-lang="cl"><span class="p">(</span><span class="nb">defun</span> <span class="nv">turn-on-outline-minor-mode</span> <span class="p">()</span> <span class="p">(</span><span class="nv">outline-minor-mode</span> <span class="mi">1</span><span class="p">))</span> <span class="p">(</span><span class="nv">add-hook</span> <span class="ss">&#39;LaTeX-mode-hook</span> <span class="ss">&#39;turn-on-outline-minor-mode</span><span class="p">)</span> <span class="p">(</span><span class="nv">add-hook</span> <span class="ss">&#39;latex-mode-hook</span> <span class="ss">&#39;turn-on-outline-minor-mode</span><span class="p">)</span> <span class="p">(</span><span class="k">setq</span> <span class="nv">outline-minor-mode-prefix</span> <span class="s">&quot;\C-c \C-o&quot;</span><span class="p">)</span> <span class="c1">; Or something else</span></code></pre></div> <p>Now you can <em>fold</em> sections, subsections, chapters, or the whole document. To hide all the contents of your current section, use <code>C-c C-o C-l</code>. You can apply it to a chapter, subsection, etc. You can also move to a next <em>unit</em> of your document with <code>C-c C-o C-n</code>, or to a previous one with <code>C-c C-o C-p</code>. If you’re lost and want to see the whole document again, use <code>C-c C-o C-a</code>.</p> <p>Folding and unfolding parts of the text might be confusing, though, but there’s another way to navigate through a big TeX file, and you can use <a href="http://www.gnu.org/software/auctex/reftex.html">Reftex</a> mode for it. Reftex is a mode that helps with managing references (<a href="http://www.gnu.org/software/auctex/manual/reftex.index.html">full documentation</a>), but it can also be used to create a table of contents for a TeX file and to navigate using it. Here is my configuration for Reftex from my <code>.emacs</code> file:</p> <div class="highlight"><pre><code class="language-cl" data-lang="cl"><span class="p">(</span><span class="nb">require</span> <span class="ss">&#39;tex-site</span><span class="p">)</span> <span class="p">(</span><span class="nv">autoload</span> <span class="ss">&#39;reftex-mode</span> <span class="s">&quot;reftex&quot;</span> <span class="s">&quot;RefTeX Minor Mode&quot;</span> <span class="no">t</span><span class="p">)</span> <span class="p">(</span><span class="nv">autoload</span> <span class="ss">&#39;turn-on-reftex</span> <span class="s">&quot;reftex&quot;</span> <span class="s">&quot;RefTeX Minor Mode&quot;</span> <span class="no">nil</span><span class="p">)</span> <span class="p">(</span><span class="nv">autoload</span> <span class="ss">&#39;reftex-citation</span> <span class="s">&quot;reftex-cite&quot;</span> <span class="s">&quot;Make citation&quot;</span> <span class="no">nil</span><span class="p">)</span> <span class="p">(</span><span class="nv">autoload</span> <span class="ss">&#39;reftex-index-phrase-mode</span> <span class="s">&quot;reftex-index&quot;</span> <span class="s">&quot;Phrase Mode&quot;</span> <span class="no">t</span><span class="p">)</span> <span class="p">(</span><span class="nv">add-hook</span> <span class="ss">&#39;latex-mode-hook</span> <span class="ss">&#39;turn-on-reftex</span><span class="p">)</span> <span class="c1">; with Emacs latex mode</span> <span class="c1">;; (add-hook &#39;reftex-load-hook &#39;imenu-add-menubar-index)</span> <span class="p">(</span><span class="nv">add-hook</span> <span class="ss">&#39;LaTeX-mode-hook</span> <span class="ss">&#39;turn-on-reftex</span><span class="p">)</span> <span class="p">(</span><span class="k">setq</span> <span class="nv">LaTeX-eqnarray-label</span> <span class="s">&quot;eq&quot;</span> <span class="nv">LaTeX-equation-label</span> <span class="s">&quot;eq&quot;</span> <span class="nv">LaTeX-figure-label</span> <span class="s">&quot;fig&quot;</span> <span class="nv">LaTeX-table-label</span> <span class="s">&quot;tab&quot;</span> <span class="nv">LaTeX-myChapter-label</span> <span class="s">&quot;chap&quot;</span> <span class="nv">TeX-auto-save</span> <span class="no">t</span> <span class="nv">TeX-newline-function</span> <span class="ss">&#39;reindent-then-newline-and-indent</span> <span class="nv">TeX-parse-self</span> <span class="no">t</span> <span class="nv">TeX-style-path</span> <span class="o">&#39;</span><span class="p">(</span><span class="s">&quot;style/&quot;</span> <span class="s">&quot;auto/&quot;</span> <span class="s">&quot;/usr/share/emacs21/site-lisp/auctex/style/&quot;</span> <span class="s">&quot;/var/lib/auctex/emacs21/&quot;</span> <span class="s">&quot;/usr/local/share/emacs/site-lisp/auctex/style/&quot;</span><span class="p">)</span> <span class="nv">LaTeX-section-hook</span> <span class="o">&#39;</span><span class="p">(</span><span class="nv">LaTeX-section-heading</span> <span class="nv">LaTeX-section-title</span> <span class="nv">LaTeX-section-toc</span> <span class="nv">LaTeX-section-section</span> <span class="nv">LaTeX-section-label</span><span class="p">))</span></code></pre></div> <p>Once Reftex is loaded, you can invoke the table of contents buffer with <code>C-c =</code></p> <p><img src="/images/emacs-reftex-toc.png" class="small" /></p> <p>All right, enough. If I mention any more packages, I guess it will scare off those who aren’t already scared. I know that Emacs is a bit <em>peculiar</em> with its complicated keyboard shortcuts, enormous documentation and thousands of modes. It’s not easy to learn, but definitely worth it. I remember that switching from Vim to Emacs for LaTeX editing wasn’t easy, but I never regretted that, and I hope whoever’s going to switch under the influence of this post will not regret it either.</p> Norway in the eyes of a foreigner 2010-04-17T21:41:10+00:00 http://piotrkazmierczak.com/2010/04/17/norway-in-the-eyes-of-a-foreigner <iframe border="0" scrolling="no" width="78" height="17" allowtransparency="true" frameborder="0" style="margin-bottom: -3px; z-index: 1338; border: 0px; background-color: transparent; overflow: hidden;" src="http://www.instapaper.com/e2?url=http%3A%2F%2Fpiotrkazmierczak.com%2F2010%2F04%2F17%2Fnorway-in-the-eyes-of-a-foreigner%2F&amp;title=Norway+in+the+eyes+of+a+foreigner"></iframe> <p>After a long period of searching for a PhD scholarship I finally got a great offer from <a href="http://www.hib.no">Bergen University College</a>, and in the 2nd half of March I’ve joined the staff of <a href="http://www.hib.no/avd_ai/data/index.htm">Department of Computer Engineering</a> as a member of <a href="http://prosjekt.hib.no/distech/">DISTECH</a> research group. This means a lot has changed in my life, because apart from changing a job/school I’ve also moved to another country. This country happens to be Norway and I have some thoughts about it I’d like to share.</p> <ul> <li> <p>It’s <strong>expensive</strong>, but in a peculiar way. Let me explain what I mean. Coming from a relatively poor country that Poland is (at least by European standards) to Belgium last year was difficult, especially when Euro was so strong. But Belgium (and Leuven especially) is not a very expensive place to live. Coming to Bergen I expected to pay 200% of Belgian prices for everything, but it’s not like this. To my surprise, Norwegian prices are only a little higher than Euro zone prices, at least for the most basic products like food or clothes. But mind you: this applies only to the food you buy in a supermarket. Once you want to go out and have a lunch in a restaurant, expect to pay extra. And if you happen to like beer or alcohol in general, expect to pay even more. I’m a beer enthusiast myself and I remember the great choice of fantastic beers in Leuven — you could hardly find one that would cost more than, say, 5 EUR for a bottle. Anything above this price would either be very rare, or served in an expensive bar. In Bergen, you can easily pay 8 EUR for a bottle of beer in a bar, and the prices go up (sometimes much higher). What’s peculiar is that the structure of product prices is different. The food is generally expensive, but clothes, furniture, high-tech (computers, electronics, good bicycles) and home equipment isn’t. I’ve seen more iPhones and people wearing good quality headphones on the bus here in Bergen than in Brussels. So to sum up: an average Norwegian is able to afford a newest smartphone without any problems, but he will think twice before having a dinner in a restaurant.</p> </li> <li> <p>One other thing about costs of living and money in general that is specific in Norway is that there are no big differences in salaries. For example, a person working as a researcher in my school doesn’t get much more money than a janitor (or at least that’s what my Norwegian friends told me). Still it doesn’t mean that researchers aren’t paid good money; in fact my salary as a PhD student is bigger than that of my colleagues in western Europe. And even though the cost of living here is much higher, I see that a PhD student in Norway is generally able to afford more than a PhD student in Belgium. Sure, the <em>flat</em> structure of wages has its disadvantages, but you hardly see any poor people on the streets here (not a case for Brussels).</p> </li> <li> <p>Also, one last point about the money: having a salary paid in Norwegian kroner makes every other country cheap. And that’s a big advantage if you’re travelling a lot.</p> </li> <li> <p>Ok, let’s get to some more important matters: The Nature. To say that Norway is stunningly beautiful is not enough. I’m about a month here so I haven’t seen much, but every time I go anywhere outside Bergen I keep staring at the mountains with my jaw dropped. Heck, I don’t even have to leave Bergen — the mountains are everywhere, I can see them through the windows of my office, I can just walk outside and start climbing them anytime. But when you head northeast it gets even better; we went to <a href="http://www.myrkdalen.org/om_myrkdalen/Spraak/engelsk.html">Myrkdalen</a> by car last week and I had my face pressed up against the window all the time, with only one thought in my head — how to get a permanent residence permit and how to buy a house here.</p> </li> <li> <p>Norway seems like a homogeneous society. Perhaps you don’t see it if you’re in Oslo, or if you’re working for some international company, but in my school, where there aren’t too many international students, blending into Norwegian society is a must. What it means in practice is that it’s hardly possible living four years here without learning Norwegian. I know it’s possible not to know a word in Dutch while living in The Netherlands or Belgium, but it would be very hard here. Not because Norwegians don’t speak English, in fact everyone here does it really well, but since there aren’t that many foreigners there’s not much practical information in English — bus company websites, banks, festivals, newspapers, etc. — it’s all in Norwegian. Not a case for Belgium, where most things are presented in four languages (NL/FR/DE/EN).</p> </li> <li> <p>Oh, by the way, some of my friends asked me if it’s true that Norwegians are generally shy and quiet. I don’t know where this came from, but they’re <strong>definitely</strong> not shy. And let’s just leave it like this without getting into details.</p> </li> <li> <p><strong>[updated 18.04]</strong> Just one more thing I forgot about yesterday: Norwegians are carnivores. Being a vegetarian here is virtually impossible. I’m not a veggie myself, but I try to eat as little meat as possible. Fish are easy to get of course, and cheap, but I remember ordering a pizza last Friday, and among 20 different pizza types there was only one vegetarian. And not only do Norwegians eat meat, they eat a lot of fat meat. And sheep heads in Voss (literally sheep heads — with eyes and everything). If you’re a vegetarian, either don’t move here or stop being one.</p> </li> </ul> <p>I guess I should also write about my research, but there’s not much to write about yet. I still have a lot to learn, the most important thing is that I can learn things that really interest me, and that I have great support from my promoter and my colleagues.</p> <p>Stay tuned for more Norway-related posts!</p> I can't read fiction anymore 2010-02-12T22:40:11+00:00 http://piotrkazmierczak.com/2010/02/12/i-cant-read-fiction-anymore <p>Every day I consume thousands of words. I read essays (like the ones published in <em>The New Yorker</em> magazine, <em>The Atlantic</em>, etc.), news (usually just Slashdot, HN and Reddit), blogs, comments, emails, tweets and status updates. Apart from that, I read scientific articles, technical books (<em>Haskell road to maths, logic and programming</em>, anyone?) and sometimes documentation. But I can’t read fiction anymore.</p> <p>When I was in high school, I used to read at least a couple of novels every month. Now whatever I pick up, I’m either quickly bored with, or stop reading for another reason. Some novels I find too depressing (Coetzee’s <em>Dusklands</em>), others secondary (Pilch’s <em>Wyznania twórcy pokątnej literatury erotycznej</em>), and the rest simply bad. I tried many different types of novels, yet the only ones I’ve read during the last few years were crime/mystery novels (Mankell, Krajewski, Marinina), and I really have enough of those since they’re all basically the same. I even tried going back to science-fiction, which I used to be a fan of, but the results were even worse – after reading 250 pages of Dukaj’s <em>Black Oceans</em> I gave up.</p> <p>The problem is not that I don’t read novels, but that it doesn’t give me any pleasure (and it used to give). I came up with a number of theories that explain this situation:</p> <ol> <li> <p>I read too much serious/difficult non-fiction literature and hence am not able to make an effort of reading 300 pages filled with fiction (rather unlikely, since I don’t read that many scientific articles);</p> </li> <li> <p>I spend too much time browsing the internet which creates a habit of reading relatively short content (even the longest essays usually don’t exceed 3000 words);</p> </li> <li> <p>I simply can’t find an appropriate novel.</p> </li> </ol> <p>Explanation no. 3 seems most plausible, therefore I ask my readers: any suggestions? I’m able to read in Polish and English, please go ahead and recommend me some fiction to read. I still have at least 2 weeks before starting a PhD, and I’d really like to read something interesting until then. Thanks in advance!</p> On the subjective hi-fi quality 2009-12-30T21:34:42+00:00 http://piotrkazmierczak.com/2009/12/30/on-the-subjective-hi-fi-quality <p>Every now and then different people ask me about an opinion on buying hi-fi components. Be it headphones for their portable mp3 players, amplifiers or mini-systems, I’m a local authority (a proud one, I must add). Perhaps it’s because I’m a nerd obsessed with sound quality, or perhaps I’m judging people by their hi-fi systems, anyways I thought I’d share a few general advices for everyone.</p> <p>First of all, let me remind everyone one more time, that buying hi-fi is by no means similar to buying computer hardware. There seldom happens a situation, when one can compare e.g. two amplifiers and say that the former is better than the latter in every aspect. Bad components happen, very bad happen as well, but the majority of hi-fi produced nowadays is at least good. Some of them are very good, and few are exceptionally fantastic, but those devices that occupy the last two categories are amongst most controversial, since not everybody likes the same sound.</p> <p>The most apparent example is with vinyl vs. laser discs. There is a significant number of people, who claim that a good turntable <em>outperforms</em> (whatever this means) every CD player. These people hold this view even though they know about obvious limitations of a gramophone record, and I respect them the same way I respect insane people. However, I am able to acknowledge that someone may just <em>like</em> a sound of an LP rather than a CD. And that’s the way it works.</p> <p>I’m an insane person too, in a way, i.e. I claim that <a href="http://en.wikipedia.org/wiki/Electrostatic_loudspeaker">electrostatic loudspeakers</a> are superior to any other loudspeaker technology. They’re expensive, they lack bass, they demand a big room (or rather: they can’t stand right next to a wall) and can be dangerous (especially if you have kids or keep animals at home), but the sound they give in return is so amazing that no traditional construction can match them. It’s my opinion, though, and I don’t intend to force it on anyone. The same goes for transistor vs. valve, integrated vs. separated amplifiers or CD players, and so on. Bear that in mind before you ask me once again what is better, or if you once again try to convince me that gramophones are the best source for a hi-fi system.</p> <p>Now shortly, a number of <em>tips</em> that I’d give to anyone asking me for advice.</p> <ul> <li> <p>If you’re not willing to spend too much money on a hi-fi system, don’t expect huge differences amongst different amplifiers or loudspeakers. You might pick a terribly sounding component, but the chances are low.</p> </li> <li> <p>Keep in mind that among budget hi-fi manufacturers there are some which are usually a safe bet, i.e. their products will sound at least decently, and that includes some European companies (NAD, Creek, Cambridge Audio) and some Japanese (Rotel, Marantz).</p> </li> <li> <p>Don’t be cheap on the loudspeakers, their quality is very important. Also, when it comes to cables, don’t use the <em>default</em> ones. You don’t have to spend hundreds of euros for Van den Hul, but get an entry-level Monster or Ixos, and you’ll certainly hear the difference.</p> </li> <li> <p>If it’s the first time you’re buying hi-fi, you might want to read some reviews. British “<a href="http://www.whathifi.com">What Hi-Fi</a>” and “<a href="http://www.hifichoice.co.uk">Hi-Fi Choice</a>” are a start, but watch out – they tend to be very enthusiastic about most stuff they review. American “<a href="http://www.stereophile.com">Stereophile</a>” (personal favorite) on the other hand is usually very cautious.</p> </li> <li> <p>Reading the reviews you will probably end up with choosing the most <em>universally</em> sounding system, which is good for a start. Later, if you upgrade or replace it, you’ll know what sound you’re looking for, and the reviews will just be a bit of a guide, but nothing more.</p> </li> </ul> <p>Finally, always remember that it’s your call as a listener to choose a system. You’re your best advisor. Bear in mind that no hi-fi is 100% neutral (perhaps except for some insanely expensive hi-end systems), although theoretically that’s the goal. And lastly: remember that once you start searching for The Perfect Hi-Fi System, this search will probably never be over. Good luck!</p> Extracting audio from a DVD with mplayer 2009-12-26T12:32:53+00:00 http://piotrkazmierczak.com/2009/12/26/extracting-audio-from-a-dvd-with-mplayer <p>I <strong>love</strong> concert DVDs, but once I watch them, I’d like to have the sound extracted and cut into separate files, so that I can upload them to my portable music player and listen to the concert once again during my commute or wherever. Extracting audio, cutting it into pieces and compressing with <a href="http://en.wikipedia.org/wiki/Flac">FLAC</a> can be done with one bash command and <a href="http://www.mplayerhq.hu">mplayer</a>:</p> <div class="highlight"><pre><code class="language-sh" data-lang="sh"><span class="k">for</span> f in <span class="sb"></span>seq 19<span class="sb"></span><span class="p">;</span> <span class="k">do</span> mplayer -dvd-device /dev/scd1 dvd://1 -chapter <span class="s2">&quot;${f}&quot;</span>-<span class="s2">&quot;${f}+1&quot;</span> -aid <span class="m">160</span> -ao pcm:file<span class="o">=</span><span class="s2">&quot;${f}&quot;</span>.wav:fast -vo null -vc null<span class="p">;</span>flac <span class="s2">&quot;${f}&quot;</span>.wav<span class="p">;</span> rm -f <span class="s2">&quot;${f}&quot;</span>.wav<span class="p">;</span> <span class="k">done</span></code></pre></div> <p>There are few parameters above that matter. First, <code>seq 19</code> assumes you want to extract 19 chapters. <code>/dev/scd1</code> points to a specific device as a DVD drive in your system, so you might want to change it. Another important switch is <code>-aid</code>, which specifies the audio channel you want to have ripped. I’m listening to music generally using headphones, so I’m ripping the stereo channel (you can check other ids for other channels using mplayer’s <code>-identify</code> switch; bear in mind that converting AC3 or other multi-channel sound to stereo will result in tracks having different volume, so you’ll need to normalize them later). Also, I’m using FLAC since I like my audio files lossless, but you might as well use Lame for mp3 encoding. The rest is just to fill out some ID3 tags, and that’s all.</p> How I've stopped being a desktop linux enthusiast 2009-11-09T18:59:45+00:00 http://piotrkazmierczak.com/2009/11/09/how-ive-stopped-being-a-desktop-linux-enthusiast <p>It’s actually about “how I’m stopping to be a desktop linux enthusiast”, because I’m still using linux on my desktop/laptop, and I still think it’s a much better solution than any Windows OS. It’s just that I’ve been using various linux distributions for many many years (since 1998 I guess) on every computer I’ve owned and thought it is a nearly flawless system. It’s not, and in fact it’s getting on my nerves.</p> <p>It’s all about hardware, you know. I’ve never had any problems with a desktop computer running linux, but on all the laptops I’ve owned (all two of them), there’s always been some issues. When I was a teenager in high school, I could spend months recompiling the kernel, optimizing, patching, searching for solutions. But I’m an old man now, and I get really mad when something simply doesn’t work.</p> <p>I gave up on getting quite a basic feature of a modern laptop computer to work, namely on suspend/resume (I’ve tried really hard to get it working, but I just couldn’t manage). It works 9 out of 10 times, but when I open the lid up it’s always a lottery: will it work this time or will I see a kernel panic message? I also got used to the inefficient power saving, but what the heck – I’m not flying over the Atlantic ocean every week, so I guess I don’t need 6 hours of battery life.</p> <p>What I can’t get used to is the fact that my graphics card (<code>00:02.0 VGA compatible controller: Intel Corporation Mobile 945GM/GMS, 943/940GML Express Integrated Graphics Controller (rev 03)</code>) works slower and slower. After updating to the newest Ubuntu 9.10, Xorg keeps eating up to 50/60% of CPU, I can’t watch a movie without frame dropping (or wait, I can, but then I have to plug in the headphones, otherwise the fan gets so loud it drowns the sound of the speaker), and if I run _too many _applications at once (emacs, opera browser, email client, IM and one terminal instance open), the system slows down so much that it’s hardly usable.</p> <p>A linux enthusiast’s argument right now would either be, that I’m using <em>cheap, unsupported hardware</em>, and that I can’t blame anyone for that, or that I haven’t searched any forums/mailing lists for help. Well, unfortunately it’s not true. I’ve chosen my current laptop very carefully, precisely because I didn’t want to have any compatibility problems, and I’ve looked for help – I just couldn’t find it.</p> <p>Hopefully Ubuntu team will fix the issues with intel graphics with 10.04 Lucid Lynx release. Or hopefully I’ll soon get a job that will enable me to replace my current hardware with the one that has an apple logo on it (yes, I’m aware of the fact that I’m betting my soul here). Suddenly the highly glossy display of the new 13’’ Macbook Pro doesn’t seem so glossy anymore…</p> Encoding all .wav files in a directory with lame 2009-11-03T22:42:17+00:00 http://piotrkazmierczak.com/2009/11/03/encoding-all-wav-files-in-a-directory-with-lame <p>I just tried doing that and realized that <a href="http://lame.sourceforge.net/">lame</a> doesn’t support globbing. That’s where bash comes in:</p> <div class="highlight"><pre><code class="language-sh" data-lang="sh"><span class="k">for</span> f in *.wav<span class="p">;</span> <span class="k">do</span> lame --preset extreme <span class="s2">&quot;\${f}&quot;</span><span class="p">;</span> <span class="k">done</span></code></pre></div> <p>God I love unix.</p> Simple script for automatic backup using duplicity 2009-11-01T19:15:01+00:00 http://piotrkazmierczak.com/2009/11/01/simple-script-for-automatic-backup-using-duplicity <p>I’m paranoid about backups and I have good reasons for that. I’ve tested many open source tools for automatic backup available for linux, but none of them fulfilled all my requirements.</p> <p>I liked <a href="https://launchpad.net/deja-dup">Déjà-Dup</a> a lot, but it wasn’t able to abort a backup once the destination directory (portable hdd) wasn’t present (or rather: it did abort, but tried to prepare a backup anyway, consuming some cpu on the way). Second thing about Déjà-Dup I didn’t like is that it divides backup files into 5 megabyte archives — opening a directory containing 20 gigabytes of such archives takes a while (I understand the reason for such small volumes is handling Amazon S3, but for local backups it makes no sense), and finally, Déjà-Dup can’t make automatic backups more often than once a day (did I mention I’m a bit paranoid?). However, Déjà-Dup integrates with Gnome very nicely, and since it uses <a href="http://duplicity.nongnu.org/">duplicity</a> as a backend, I was able to come up with a simple script fixing all the problems in a couple of minutes.</p> <script src="https://gist.github.com/1551124.js"> </script> <p>The best way is to first configure Déjà-Dup according to your needs, then copy the duplicity command it uses while backing up (it’s visible in <code>STDOUT</code> once you set an environment variable <code>DEJA_DUP_DEBUG=1</code>), paste it into the script, tune it (I’ve changed the volume size), and simply put it to <code>crontab</code> — this way it’s easy to control how often your backups are done.</p> <p>Feel free to use the script if you need it, and if you’re better in unix scripting than I am (and I believe you are), send me any improvements and/or comments.</p> Call me master 2009-10-16T18:11:48+00:00 http://piotrkazmierczak.com/2009/10/16/call-me-master <p><img src="/images/master.png" /></p> <p>Master of Arts, to be exact. I wish I was a master of martial arts instead but hey, <em>you can’t always get what you want:)</em>.</p> I finished writing my thesis 2009-10-05T20:46:00+00:00 http://piotrkazmierczak.com/2009/10/05/i-finished-writing-my-thesis <p>Yup, it’s finally done. I’m not particularly satisfied with it, but if anyone’s interested, here’s the abstract:</p> <blockquote> <p>In the thesis we discuss modal logics and tableau methods. We focus on modal logic K and its deduction systems in the tableau style that can be used for verification of validity of K-formulas. We start with a brief philosophical and historical introduction on modal logics and tableau methods. We present tableau system for the classical propositional logic, then we discuss — well known in the literature — the non-deterministic tableau for the logic K. Next, we present new deterministic tableau system for K, we prove its soundness and completeness. Finally, we show the differences between these systems, discuss their potential applications, and draw conclusions.</p> </blockquote> <p>The joy of having the thesis completed didn’t last long, since now I have to fight the bureaucracy every day, and I still don’t know if I have the funding for <a href="http://icr.uni.lu">a PhD position in Luxembourg</a>. Luckily, if everything goes well, the defense will take place next Thursday, and it will finally be all over.</p>