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

<channel>
	<title>Not a Number</title>
	<atom:link href="http://brej.org/blog/?feed=rss2" rel="self" type="application/rss+xml" />
	<link>http://brej.org/blog</link>
	<description>I am an individual!</description>
	<lastBuildDate>Sat, 28 Aug 2010 11:38:37 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0.1</generator>
		<item>
		<title>Pub engineering</title>
		<link>http://brej.org/blog/?p=640</link>
		<comments>http://brej.org/blog/?p=640#comments</comments>
		<pubDate>Sat, 28 Aug 2010 10:40:33 +0000</pubDate>
		<dc:creator>Charlie Brej</dc:creator>
				<category><![CDATA[Personal]]></category>

		<guid isPermaLink="false">http://brej.org/blog/?p=640</guid>
		<description><![CDATA[Ever wondered what happens when engineers go to the pub? We get uncontrollable bridge building urges. We tried to build a bridge between two tables using the fewest beer mats. Before reading on, take a guess what we got it down to. Here is our original bridge, which was a corbel arch design. It consumed [...]]]></description>
			<content:encoded><![CDATA[<p>Ever wondered what happens when engineers go to the pub? We get uncontrollable bridge building urges. We tried to build a bridge between two tables using the fewest beer mats. Before reading on, take a guess what we got it down to.</p>
<p>Here is our original bridge, which was a <a href="http://en.wikipedia.org/wiki/Corbel_arch">corbel arch</a> design. It consumed about thirty beer mats.</p>
<p><a href="http://brej.org/blog/wp-content/uploads/2010/08/pub_30.jpg"><img class="alignnone size-medium wp-image-643" title="pub_30" src="http://brej.org/blog/wp-content/uploads/2010/08/pub_30-300x225.jpg" alt="" width="300" height="225" /></a></p>
<p>The green mats are shaped like a capital B, so they can be locked together. So we were down to twenty-ish.</p>
<p><a href="http://brej.org/blog/wp-content/uploads/2010/08/pub_20.jpg"><img class="alignnone size-medium wp-image-644" title="pub_20" src="http://brej.org/blog/wp-content/uploads/2010/08/pub_20-300x225.jpg" alt="" width="300" height="225" /></a></p>
<p>If you form the bridge into my &#8220;snake&#8221; design, you can get rid of the weights at the ends and reduce the mats used down to ten.</p>
<p><a href="http://brej.org/blog/wp-content/uploads/2010/08/pub_10.jpg"><img class="alignnone size-medium wp-image-645" title="pub_10" src="http://brej.org/blog/wp-content/uploads/2010/08/pub_10-300x225.jpg" alt="" width="300" height="225" /></a></p>
<p>That seemed like a good design, but actually having a weights works better as the bridge is straight and even. So we are now down to nine mats (it stayed up without my hand there).</p>
<p><a href="http://brej.org/blog/wp-content/uploads/2010/08/pub_9.jpg"><img class="alignnone size-medium wp-image-658" title="pub_9" src="http://brej.org/blog/wp-content/uploads/2010/08/pub_9-300x225.jpg" alt="" width="300" height="225" /></a></p>
<p>If you let the bridge sag a little and allow the ends to twist you can cut form it using eight.</p>
<p><a href="http://brej.org/blog/wp-content/uploads/2010/08/pub_8.jpg"><img class="alignnone size-medium wp-image-647" title="pub_8" src="http://brej.org/blog/wp-content/uploads/2010/08/pub_8-300x225.jpg" alt="" width="300" height="225" /></a></p>
<p>Martin then suggests flipping the direction of the B links half way across the bridge and we were down to seven.</p>
<p><a href="http://brej.org/blog/wp-content/uploads/2010/08/pub_7.jpg"><img class="alignnone size-medium wp-image-648" title="pub_7" src="http://brej.org/blog/wp-content/uploads/2010/08/pub_7-300x225.jpg" alt="" width="300" height="225" /></a></p>
<p>Some careful balancing and you can get it to be stable with just six mats.</p>
<p><a href="http://brej.org/blog/wp-content/uploads/2010/08/pub_6.jpg"><img class="alignnone size-medium wp-image-649" title="pub_6" src="http://brej.org/blog/wp-content/uploads/2010/08/pub_6-300x225.jpg" alt="" width="300" height="225" /></a></p>
<p>If you push the B links into each-other the mats will tear a little and lock together. This way you can alternate the links and make a bridge with five mats. Also in the photo is Andrew&#8217;s zipper double bridge.</p>
<p><a href="http://brej.org/blog/wp-content/uploads/2010/08/pub_5.jpg"><img class="alignnone size-medium wp-image-650" title="pub_5" src="http://brej.org/blog/wp-content/uploads/2010/08/pub_5-300x225.jpg" alt="" width="300" height="225" /></a></p>
<p>If tearing is allowed, I take it to the natural conclusion of locking the mats together with small cuts. Sudden leap forward as we have a three mat bridge.</p>
<p><a href="http://brej.org/blog/wp-content/uploads/2010/08/pub_3.jpg"><img class="alignnone size-medium wp-image-651" title="pub_3" src="http://brej.org/blog/wp-content/uploads/2010/08/pub_3-300x225.jpg" alt="" width="300" height="225" /></a></p>
<p>Tear each mat in two and link the parts to make a bridge with two mats.</p>
<p><a href="http://brej.org/blog/wp-content/uploads/2010/08/pub_2.jpg"><img class="alignnone size-medium wp-image-652" title="pub_2" src="http://brej.org/blog/wp-content/uploads/2010/08/pub_2-300x225.jpg" alt="" width="300" height="225" /></a></p>
<p>You can rip a single mat into a continuous strip which makes you rope bridge.</p>
<p><a href="http://brej.org/blog/wp-content/uploads/2010/08/pub_1.jpg"><img class="alignnone size-medium wp-image-653" title="pub_1" src="http://brej.org/blog/wp-content/uploads/2010/08/pub_1-300x225.jpg" alt="" width="300" height="225" /></a></p>
<p>Now that it is so lightweight, you can span the distance with half a mat. Martin is declared the winner.</p>
<p><a href="http://brej.org/blog/wp-content/uploads/2010/08/pub_1_2.jpg"><img class="alignnone size-medium wp-image-654" title="pub_1_2" src="http://brej.org/blog/wp-content/uploads/2010/08/pub_1_2-300x225.jpg" alt="" width="300" height="225" /></a></p>
<p>So that was our final design. Once you go into fractional beer mats, it gets a little hard to measure. We also created made a bit of a mess.</p>
<p><a href="http://brej.org/blog/wp-content/uploads/2010/08/pub_mess.jpg"><img class="alignnone size-medium wp-image-656" title="pub_mess" src="http://brej.org/blog/wp-content/uploads/2010/08/pub_mess-300x225.jpg" alt="" width="300" height="225" /></a></p>
<p>Thanks go to the <a href="http://www.tmtaylor.co.uk/ducie.htm">Ducie Arms</a> who supplied us with the mats and tidied up after we left.</p>
]]></content:encoded>
			<wfw:commentRss>http://brej.org/blog/?feed=rss2&amp;p=640</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>COMP20252: Mobile systems</title>
		<link>http://brej.org/blog/?p=570</link>
		<comments>http://brej.org/blog/?p=570#comments</comments>
		<pubDate>Fri, 27 Aug 2010 10:49:28 +0000</pubDate>
		<dc:creator>Charlie Brej</dc:creator>
				<category><![CDATA[COMP20252]]></category>

		<guid isPermaLink="false">http://brej.org/blog/?p=570</guid>
		<description><![CDATA[This year, I had a go at doing some teaching at the COMP20252 computer science course. I will try and record some of the things I tried so they may be useful to others. You may wish to jump directly to the summary before reading the body. Previous years This course has been running for [...]]]></description>
			<content:encoded><![CDATA[<p>This year, I had a go at doing some teaching at the COMP20252 computer science course. I will try and record some of the things I tried so they may be useful to others. You may wish to jump directly to the <a href="#summary">summary</a> before reading the body.</p>
<h2>Previous years</h2>
<p>This course has been running for 4 years now. I originally designed the lab element and have been involved in the labs to help with any issues, so I got to know the issues involved. I was most concerned with the lab element where the restriction on my in designing it was that they had to work in groups, having weekly meetings and many of the marks being awarded for group work. The idea behind this was that this would teach them to work in groups, like they would have to in real jobs. This is great in theory, but I felt this approach was very unsuccessful.</p>
<p>In the very first year of the course, the groups would consist of four students. In their first meeting, the students elected a manager and proceeded to implement the different parts of the task. The manager would do no coding and would just instruct the others. This was a recipe for disaster.The students quickly realised that their effort would be divided by four and shared to lazy collogues. In each group, about one student would switch course (they can do so within the first three weeks). This dropped most groups down to three, which they would use as an excuse for doing no work. The work was scattered with one student sitting at a computer and three sitting around them playing with their mobile phones. Students soon realised they were not necessary to the process and would stop attending. The morale was incredibly low and nearly all the questions in the labs, rather than being technical, begun with &#8220;this isn&#8217;t fair because&#8230;&#8221;.</p>
<h2>Things to learn</h2>
<p>There were a number of things that I learned from this about students that I wanted to solve.</p>
<h3>Students just want marks</h3>
<p>Turning up to labs is not something that many people would do voluntarily. Most students do turn up. Not because they are fascinated about the subject and they decided that the perfect time to satisfy their curiosity is at 9am on a miserable Thursday morning. They are there to do a job. And that is the way the lab component is described to them, &#8220;a job&#8221;. The job is to get up and receive their marks so they can go back to bed. They are interested in the most direct route to getting their points. After they get these, the work they have done is thrown away, so there is little desire to make the work expandable, tidy or correctly commented.</p>
<h3>Students hate each-other</h3>
<p>They will happily cut their noses off to spite their face and then present you with the said nose crying &#8220;look what <strong>they</strong> made me do&#8221;. When working in a group with one of two lazy individuals, students will simply refuse to work. Because they see the marks as the result of their work, giving these away to uncooperative colleagues feels wrong.</p>
<h3>Students look for excuses</h3>
<p>One of the most shocking things I noticed was many students putting a fantastic amount of effort to get compassionate marking. Interestingly, this was much more prevalent when it came to tasks in which they never faced before, yet could be performed very quickly. Boring tedious tasks were performed happily without any agitation. As a student, you quickly learn that you may get stuck for hours, maybe days on a problem and have little to show for your effort. This is difficult to appreciate as someone who understands how to do the task, but imagine picking up a 700 page reference manual for something you don&#8217;t really understand and be expected to get something working within a couple hours. So risking even trying for perform these tasks may be a huge waste of time. Finding an excuse gives much more consistent results and doesn&#8217;t damage your self respect.</p>
<h2>Preparation</h2>
<p>The lecture course was only using 12 of it&#8217;s 24 lecture slots expecting students to use the extra hour per week on personal study of the field (you can guess what happened). I asked Doug if I could give six extra lectures explaining the lab and he agreed. This was in December so I only had two months to prepare.</p>
<h3>Psychology</h3>
<p>I felt the majority of the challenge was psychological, so I downloaded a lecture course of developmental psychology (search torrent sites). These are 30 minutes per lecture, but <a href="http://en.wikipedia.org/wiki/Audio_timescale-pitch_modification">time stretching</a> these, you can get then down to about 18 minutes. I could do two lectures on my commute in to work and two on the way back. This way I listened to 20 lectures per week without it impacting my work time. Although many concepts are rather woolly and unscientific, I can wholeheartedly recommend these if you are trying to be a good educator or parent.</p>
<p>This is a massive field of study but for the purposes of this post I will try and summarise it. Developmental psychology examines the change of character that is necessary for individuals to progress though their different roles in life. Here I concentrated on <a href="http://en.wikipedia.org/wiki/Erik_Erikson">Erik Erikson&#8217;s</a> theory of <a href="http://en.wikipedia.org/wiki/Erikson%27s_stages_of_psychosocial_development#Competence:_Industry_vs._Inferiority_.28Childhood.2C_7_to_11_years.29">industry</a> and  <a href="http://en.wikipedia.org/wiki/Erikson%27s_stages_of_psychosocial_development#Fidelity:_Identity_vs._Role_Confusion_.28Adolescents.2C_12_to_19_years.29">identity</a>. It felt a bit silly using some approaches that should only be applicable on children 7-11 years olds, but these are very important as years of school grading, target chasing and little appreciation for extra effort, have regressed these people into grade producing zombies. Before you can get people to be motivated to work voluntarily, without the assurance of success and without a direct connection to a reward or punishment, several barriers must be broken.</p>
<ol>
<li>People feel worthless and unappreciated. Much of the effort on their part is not recognised.</li>
<li>People don&#8217;t identify their expertise as valuable. They dread being asked what they do as they think other people will think poorly of them.</li>
<li>People feel anonymous and hope they can fade into the background. There is always one correct answer to all questions, so thinking differently is usually punished.</li>
<li>People are afraid of decisions or committing effort in case they are wrong. Putting in effort into the wrong direction is usually punished which makes people afraid of commitment.</li>
</ol>
<h3>Subject</h3>
<p>The subject involved a lot of hard core mathematics. This is not only very hard, but many find it rather dull. This, I wanted to learn to a very deep degree beyond that what is useful in the lab exercises. Not because I was afraid of hard questions, but I wanted to find other uses for each element taught. Advanced mathematics is one of the subjects that has very little function in day to day life, so committing yourself to learn something of little practical use is somewhat hard.</p>
<p>I wanted to move the lab to use techniques implemented by current devices. This had a double use as students would believe they were learning something that was novel that would be practical, rather than academic. For example, Hamming versus Reed-Solomon error correction. Virtually every error correction system nowadays uses Reed-Solomon, while hamming remains an academic curiosity. When students see this, they know they are learning something they will be able to apply, rather than learning for the sake of learning.</p>
<h2>Lectures</h2>
<p>In total I presented six lectures. The structure of each lecture was the following</p>
<ul>
<li>5 minute subject motivation</li>
<li>40 minute content of subject</li>
<li>5 minute off-topic cool-down</li>
</ul>
<p>Many people would turn up a couple minutes late, so it is a good idea  to not to put something too important right at the start. Here I  presented why the subject talked about in that lecture is not just important, but also exciting.</p>
<p style="padding-left: 30px;"><em>Every area of computer science has gone though massive changes over a relatively short period of time. It is possible for people to come into a field and make great leaps of advancements which will be regarded as amazing by the community, and useful by millions of users. These advances were not done by people sitting in rooms and emulating each other, by but rather by people who decided to pick up the baton and run ahead. And if you want to be awesome and advance our civilization, then concentrate for the next 40 minutes and I will show you where the current frontier of knowledge is.<br />
</em></p>
<p>This only woks if you are leading to the most advanced systems out there. Following this with some ideas from the sixties would not work.</p>
<p>The body of the lecture was intense. I tend to do one slide per minute when talking to experienced researchers and they have problems keeping up. When doing these lectures, I went even faster, in the knowledge that if some parts were not understood, I would get feedback and explain them though other means. Getting the feedback was easy (I will explain below) and supplying any extra info using <a href="http://moodle.org/">moodle</a> seemed to work. The second element essential to cover a lot of material is good handouts. Slides make terrible handouts, and instead I went by my philosophy that every lecture can be summarised down to two sides of paper. Below are the handouts of one of the lectures. You may notice that unless you were there, they may not make sense. These provide a reminder of the ideas discussed  along with values which are useful when implementing the ideas in the lab. They are not even the same examples as ones presented in the lecture, so they serve as an exercise for people who think they understood the lecture.</p>
<p><a href="http://brej.org/blog/wp-content/uploads/2010/08/2-waves.png"><img class="alignnone size-medium wp-image-601" title="2-waves" src="http://brej.org/blog/wp-content/uploads/2010/08/2-waves-212x300.png" alt="" width="212" height="300" /></a><a href="http://brej.org/blog/wp-content/uploads/2010/08/2-waves2.png"><img class="alignnone size-medium wp-image-602" title="2-waves2" src="http://brej.org/blog/wp-content/uploads/2010/08/2-waves2-212x300.png" alt="" width="212" height="300" /></a></p>
<p>The cool-down is very important. If you have just sat though a 40 minute information blast and you feel grumpy, tired and you now want to forget everything, you need a reminder that whatever effort you make, will be appreciated. Here I would begin with a review of the lab progress (looking at the lines of committed code) followed by tips on how and why they could get this better. For the first couple weeks I talked about <a href="http://brej.org/blog/?p=583">coding discipline</a> showing how you can increase your productivity though self discipline.  Then moving onto how hard work will get you noticed. An interesting factoid is that several large companies pride themselves on hiring the top 5% of the graduates. If you look at the productivity of the 45 active students on the course you can see why. Below is a graph of the of the lines of code produced by week 4 for each student. The top 10% more work than the remaining 90%. So you can see why the companies do this (you get someone ten times more productive and you pay them say two times as much), and why you should work hard to get there. The companies who chase the students offer delicious carrots while working as a code monkey only gets you a regular beating with the motivating stick. If you want to be rewarded, then work hard without the threat of a stick. If you only work when threatened, then that&#8217;s what your employers will do.</p>
<p><a href="http://brej.org/blog/wp-content/uploads/2010/08/worth-it.png"><img class="alignnone size-medium wp-image-604" title="worth-it" src="http://brej.org/blog/wp-content/uploads/2010/08/worth-it-300x225.png" alt="" width="300" height="225" /></a></p>
<p>The next point is to say <em>&#8220;Do something!&#8221;</em>. If you want to show you are capable of working without threats, then <em>do something</em>. You don&#8217;t achieve anything by just sitting there being clever. Use your brain to <em>do something <strong>awesome</strong></em>. Computer science is <span style="text-decoration: underline;"><strong>the best subject in the world</strong></span>. There is no subject that comes close. The following needs to be shouted:</p>
<p style="padding-left: 30px;"><em>There are professors in English department saying if you study some course well you may be able to write a poem or something and someone might care about your pathetic worthless existence for another minute. In computer science you can, radically revolutionise the way everyone carries out everyday tasks. The people who created the processor or the software on your computer are producing more copies of their work than any book, song, movie or any other piece of work. If you want to change the world, here is where you start&#8230;</em></p>
<p>This then leads onto encouragement to try creating something using the skills they heave learned. There are so many open source projects out there that people can contribute to. Next time you meet someone you like at a party you could say &#8220;What web browser do you use? &#8230; Oh! I wrote parts of that!&#8221;. Next time you&#8217;re at a job interview, you can say &#8220;I&#8217;m not afraid of writing code, in fact your company already relies on things I have written&#8221;.</p>
<p><img class="alignnone size-medium wp-image-605" title="11th_grade" src="http://brej.org/blog/wp-content/uploads/2010/08/11th_grade-300x186.png" alt="" width="300" height="186" /> <a href="http://xkcd.com/519/">(cc) xkcd</a></p>
<h2>Labs</h2>
<p>The tasks in the lab remained the same. I couldn&#8217;t scrap the group system, but I could change the way the tasks were divided. This time there were groups of three, with each member being able to perform their portions independently.</p>
<h3>Make submit</h3>
<p>To make it easy for students to get help, I added a &#8220;submit&#8221; target in the makefile. This would create a tar file with their files and copy it into a write only directory in my home space, with their name, task name, time and date in the filename. Along with the source files, the tar would also contain the .make_dates file. Whenever the student would run make (every time they made a change), it would record the time and date in the file.</p>
<p>At my end, I had a series of scripts which made life easier. Every minute a <em>notify-send</em> call would tell me if there were submissions in the queue. When I was marking, a script would expand their submission into a marking code tree, and would compile everything to show me any compile errors. Secondly it would diff the current submission with the last submission in the old-submits directory. Finally it would open a Thunderbird write window with the address, subject and part of the body filled in.</p>
<p>I could then run the compiled program in valgrind or ddd, look at the diff and within seconds send back help or comments. The diff would also show the number and times of the compiles since the last submission which is useful to see how long someone has been struggling over a problem. About half the submissions were with erroring code. The majority of these were trivial issues they had never seen before and easy to explain. Some had bigger problems but lacked the knowledge of how to do deep debugging. Here I replied a series of commands I used to find the problem. I didn&#8217;t want to give away the answer, so sometimes I would get a reply saying they were still confused, which would return more details in the specific area they were lost in. Half of submissions had working code. I encouraged students to submit every hour of work or at every milestone in their program. They would do this and receive a reply saying what bits were good/bad, give tips and asking if they knew what they were going to do next. This was very useful as they would say what they were planning to do in the next hour, and then doing it. This helped them divide the problem up and gave them targets. Here they would also state any elements of the lectures they did not understand as they were about to implement something that they were unsure about. Most students had a unique misunderstanding, but when there was a series of problems, a moodle posting could clarify things.</p>
<p>When I timed myself, I could deal with most submissions in less than three minutes (trivial problems or just progress updates) and the average wait time was about five minutes. I kept this down to the absolute minimum as I knew that if students were stuck, they would walk away from the computer after ten minutes of frustration. This meant being on call pretty much all day and night. I was at the computer at those times anyway, so it was just a case of putting down what I was working for a few minutes. The graph below shows the number of times students ran make during the different hours of the day. The labs were 9-11, yet most work was done outside the labs. Also note that students do like to work quite late.</p>
<p><a href="http://brej.org/blog/wp-content/uploads/2010/08/times.png"><img class="alignnone size-medium wp-image-621" title="times" src="http://brej.org/blog/wp-content/uploads/2010/08/times-300x224.png" alt="" width="300" height="224" /></a></p>
<p>Memorizing the state of over 40 students&#8217; code is pretty hard, but it is worth it. They can see that every bit of effort they make is appreciated and noted. Secondly, they don&#8217;t feel like a chump who is working harder and later than others for nothing. You can clearly see this with the first submit they make in the late evening and upon receiving the reply almost instantly they are assured that working hard is normal. Also, a few simple words of praise work very well for increasing their morale. Follow these with a reassurance that they should be able to tackle the next large element, and they will believe you and go for it.</p>
<p>In total there were over 700 code submissions and 1000 sent emails for the first task.</p>
<h3>Code exchange</h3>
<p>In the first task each student was working on a different unrelated part. In the second task, they rotate their work and perform optimisation on another group members&#8217; code. To do this properly, they have to understand what their code does. Here the idea is that each student can proudly show their work to someone else. By this point they are hopefully comfortable in that their work is impressive and they are not shy about their accomplishments. Even after this initial explanation, the students would have to go to each-other to ask for help. Hopefully they would notice that if you want a colleague to help you, you have to be nice to them and writing good clear code would give them less work explaining things later.</p>
<p>Each optimisation patch had to first pass by the original coder, who would make sure it doesn&#8217;t damage the system. If it did, they would receive penalty marks for not testing thoroughly. This made people triple check code before sending it to the original coder, as their clumsiness may cost their friend some marks. Even a consistent indenting style was important (something few students bothered with until that point).</p>
<p>In this task there were over 400 code based email exchanges that I was a part of. Sadly the majority of these were in the last three days of the three week task. There was a slight deadlock as each group member was waiting for another to submit the first patch. Two groups that had an early patch exchange and these finished over a week before the deadline. A compulsory trivial patch exchange in the first week may have been a good idea to get rid of the fear of being the first to commit.</p>
<h2><a name="summary"></a>Summary</h2>
<ul>
<li>There was approximately a 100% increase in the number of hours students put in and a 200% increase in the amount of work they produced.</li>
<li>Last year the average student satisfaction questionnaires lecturing score was about 5/10 with most students complaining about being lost and confused. This year I received a score of over 9/10 with nearly every reply praising the course.</li>
<li>Last year the most advanced low latency codec was <a href="http://en.wikipedia.org/wiki/DPCM">differential</a> with <a href="http://en.wikipedia.org/wiki/Linear_extrapolation#Linear_extrapolation">linear extrapolation</a>. This year there were several with <a href="http://cplus.about.com/od/learningc/ss/lowlevel_10.htm">bitpacked</a> <a href="http://en.wikipedia.org/wiki/ADPCM">adaptive</a> <a href="http://en.wikipedia.org/wiki/Autocorrelation">autocorrelation</a> based <a href="http://en.wikipedia.org/wiki/Linear_prediction">linear prediction</a>.</li>
<li>Last year the most advanced vocoder codec was an unpacked amplitude based DCT cutoff. This year there were several with <a href="http://en.wikipedia.org/wiki/Psychoacoustics#Limits_of_perception">perception</a> and <a href="http://en.wikipedia.org/wiki/Auditory_masking">masking</a> based <a href="http://en.wikipedia.org/wiki/Psychoacoustics">psychoacoustic</a> filters using <a href="http://en.wikipedia.org/wiki/Window_function">overlapping window functions</a> and <a href="http://en.wikipedia.org/wiki/Data_compression#Lossy">lossy value packing</a>.</li>
<li>Last year the most advanced error corrector was a parity array. This year there were several <a href="http://en.wikipedia.org/wiki/Finite_field_arithmetic">finite field arithmetic</a> based <a href="http://en.wikipedia.org/wiki/Cross-interleaved_Reed-Solomon_coding">cross interleaved</a> <a href="http://en.wikipedia.org/wiki/Reed-Solomon_error_correction">Reed-Solomon</a> implementing both <a href="http://en.wikipedia.org/wiki/Reed-Solomon_error_correction#Error_locators_and_error_values">locating</a> and <a href="http://en.wikipedia.org/wiki/Erasure_code">erasure</a> based correction.</li>
</ul>
<p>I volunteered to work on this course, but I was only allowed to do this on the condition that it would not impact my day job. So the work was done in my spare time, while keeping up with my normal work up to date. This was well worth the effort to get the experience in management. Sadly I will not be doing this next year, so I hope some of the methods I described above are attempted by people. I am very proud of the effort that the students have put in. The strong students produced an exceptional amount of work, and many of the disaffected students started engaging and putting in real effort. The biggest failure was the lecturers putting the increase in  productivity down to their threats, encouraging weak students to go to another course at the beginning of the semester. I promised students recognition from the staff, and I somewhat failed to deliver on this.</p>
<p>I would like to thank all the students work working incredibly hard, and hope the skills they learned will come in useful. I am sure some individuals will go onto do great things.</p>
]]></content:encoded>
			<wfw:commentRss>http://brej.org/blog/?feed=rss2&amp;p=570</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Valgrind T-shirt</title>
		<link>http://brej.org/blog/?p=609</link>
		<comments>http://brej.org/blog/?p=609#comments</comments>
		<pubDate>Wed, 25 Aug 2010 10:22:00 +0000</pubDate>
		<dc:creator>Charlie Brej</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[Personal]]></category>

		<guid isPermaLink="false">http://brej.org/blog/?p=609</guid>
		<description><![CDATA[This morning I received an unexpected delivery. Someone bought me a Valgrind T-shirt. The bill doesn&#8217;t say who. I do love Valgrind but only a handful of people know that my obsession extends to the promise that I will name my first-born after it (Valgrind Brej may get bullied somewhat). To whoever it was that [...]]]></description>
			<content:encoded><![CDATA[<p>This morning I received an unexpected delivery. Someone bought me a <a href="http://www.freewear.org/?page=show_item&amp;id=FW0031">Valgrind T-shirt</a>. The bill doesn&#8217;t say who. I do love Valgrind but only a handful of people know that my obsession extends to the promise that I will name my first-born after it (Valgrind Brej may get bullied somewhat). To whoever it was that bought it, I would like to say <em>Thank You!</em> I shall wear it with pride.</p>
<p><a href="http://brej.org/blog/wp-content/uploads/2010/08/valgrind2.jpg"><img class="alignnone size-medium wp-image-613" title="valgrind with bill" src="http://brej.org/blog/wp-content/uploads/2010/08/valgrind2-300x225.jpg" alt="" width="300" height="225" /></a></p>
<p><a href="http://brej.org/blog/wp-content/uploads/2010/08/valgrind1.jpg"><img class="alignnone size-medium wp-image-610" title="valgrind unfolded" src="http://brej.org/blog/wp-content/uploads/2010/08/valgrind1-300x225.jpg" alt="" width="300" height="225" /></a></p>
<p>UPDATE: Mystery solved. Matt Horsnell was offered it for spotting and fixing a bug and he knew about my secret love.</p>
]]></content:encoded>
			<wfw:commentRss>http://brej.org/blog/?feed=rss2&amp;p=609</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Coding discipline</title>
		<link>http://brej.org/blog/?p=583</link>
		<comments>http://brej.org/blog/?p=583#comments</comments>
		<pubDate>Wed, 18 Aug 2010 15:20:41 +0000</pubDate>
		<dc:creator>Charlie Brej</dc:creator>
				<category><![CDATA[COMP20252]]></category>

		<guid isPermaLink="false">http://brej.org/blog/?p=583</guid>
		<description><![CDATA[Over years of programming I have learned how to be most productive, but I found it strange we do not teach this to the students. We teach obscure features of academic systems they will never see again, but we fail to teach how to tackle large projects. Course lab tasks usually consist of writing around [...]]]></description>
			<content:encoded><![CDATA[<p>Over years of programming I have learned how to be most productive, but I found it strange we do not teach this to the students. We teach obscure features of academic systems they will never see again, but we fail to teach how to tackle large projects. Course lab tasks usually consist of writing around 30 lines of code, which doesn&#8217;t expose the students to the challenges of large code bases. Here are some things I tried to teach this year in COMP20252.</p>
<h2>The one hour cycle</h2>
<p>I code in cycles. During these I try to disconnect as much from environmental distractions as possible (headphones). These cycles are roughly one hour long, including a 5 minute break at the end to commit the code to the repository, have a biscuit and a stretch. There are three reasons for this and I think it makes sense for students to learn this as a sensible method of being productive.</p>
<h3>Set-up and burnout</h3>
<p>When starting a new change on the code base, I spend about five to ten minutes trying to locate all the areas that will need to be changes and generally planning how to tackle the problem. After about 15 minutes, I am in full swing as I have everything I need to know, cached in my head. At this point I can code for hours straight, but generally I target to finish after a further half an hour and move onto testing and debugging. The reason for stopping so early is because there is a good chance you will burn out (become tired and clumsy).</p>
<p><a href="http://brej.org/blog/wp-content/uploads/2010/08/coding-cycle.png"><img class="alignnone size-medium wp-image-585" title="coding-cycle" src="http://brej.org/blog/wp-content/uploads/2010/08/coding-cycle-300x176.png" alt="" width="300" height="176" /></a></p>
<p>The first ten minutes are not productive, yet most students will only work for 10 minutes at a time before updating their status to &#8220;Bored now&#8221; and having a chat with someone before starting again from the beginning.</p>
<p><a href="http://brej.org/blog/wp-content/uploads/2010/08/coding-cycle-students.png"><img class="alignnone size-medium wp-image-587" title="coding-cycle-students" src="http://brej.org/blog/wp-content/uploads/2010/08/coding-cycle-students-300x184.png" alt="" width="300" height="184" /></a></p>
<h3>Testing and debugging</h3>
<p>In half an hour of coding you will probably write about 50 lines scattered between several files. The rule of thumb is there being one bug every ten lines of code. So, you now have five bugs to find in 50 lines of code. Testing while you still remember what you may have broken is very easy compared to testing something that was written by someone else, or by you but months ago. Finding the bugs, knowing they are somewhere in the small blocks code you have just written, gives you a massive locating boost. This is the main reason why you should never abruptly walk away from the computer without doing some testing. Test and debug will hopefully take five or ten minutes, but can often take an hour. If it does take an hour you will be grateful that you didn&#8217;t carry on coding until you were exhausted.</p>
<p>There is one even greater sin than that of walking away from a computer leaving untested code, and that is leaving the code in a broken state. Each programming task involves breaking an already working piece of code in order to add functionality, change the behaviour etc. In the set-up you will probably want to examine the current behaviour of the system to ascertain the areas that need to be changed. This is very difficult if the system doesn&#8217;t work.</p>
<p><a href="http://brej.org/blog/wp-content/uploads/2010/08/coding-debug.png"><img class="alignnone size-medium wp-image-588" title="coding-debug" src="http://brej.org/blog/wp-content/uploads/2010/08/coding-debug-300x172.png" alt="" width="300" height="172" /></a></p>
<p>Students rarely do any testing as they never see their code coming back to them. After writing something and finding that it broke the system, they would generally walk away hoping the bug fix itself in their absence. The next week they would ask a demonstrator to fix it for them while saying &#8220;I can&#8217;t remember what I did&#8221;.  Their original buggy code coming back week after week scared many students in COMP20252. In the feedback forms, that was one of their main criticisms. I say &#8220;GOOD! Be afraid. Very afraid&#8221;.</p>
<h3>Divide and conquer</h3>
<p>Forcing yourself to have a working system every hour partitions large tasks down to sensible sized components. Many of the students, from the start, wanted to create a large system involving several ambitious components. They would begin by writing a massive monolithic block containing all the features expecting that, once you write that last line of code, the program will work. This is bad on two counts. Firstly, it won&#8217;t work due to bug problems outlined above, and secondly there is no way you are going to keep so much state in you head. Even if you can keep track of the state of every variable you&#8217;ve used, all the possible input combinations and every possible error that could arise, you are making the job unnecessarily hard for yourself and for anyone else reading your code.</p>
<p>There is one more bonus reason of why you want to return to working code sooner rather then later, and that is the frequency of random unblockable interrupts. I receive a &#8220;stop what you&#8217;re doing and help me with this&#8221; request several times a day and with small changes it is still possible to revert the changes (infinite undo in nedit) and play them back to remind myself as to what I was doing. If I do have to revert and start again, then I have wasted at most half an hour, but at least I know what I am doing the second time round.</p>
]]></content:encoded>
			<wfw:commentRss>http://brej.org/blog/?feed=rss2&amp;p=583</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Tidbit: More technical</title>
		<link>http://brej.org/blog/?p=561</link>
		<comments>http://brej.org/blog/?p=561#comments</comments>
		<pubDate>Wed, 11 Aug 2010 23:12:04 +0000</pubDate>
		<dc:creator>Charlie Brej</dc:creator>
				<category><![CDATA[Fedora]]></category>
		<category><![CDATA[Projects]]></category>
		<category><![CDATA[Tidbit]]></category>

		<guid isPermaLink="false">http://brej.org/blog/?p=561</guid>
		<description><![CDATA[In the previous post I covered the ideas behind tidbit. In this post I will try and cover the technical aspects of the tidbit system. Currently the work is very exploratory, so everything may change. Tidbit record structure This is a typical tidbit which was generated using the Rhythmbox plugin: TIDBIT/0.1; libtidbit/0.1; Rhythmbox Tidbit Plugin [...]]]></description>
			<content:encoded><![CDATA[<p>In the <a href="http://brej.org/blog/?p=540">previous post</a> I covered the ideas behind tidbit. In this post I will try and cover the technical aspects of the tidbit system. Currently the work is very exploratory, so everything may change.</p>
<h2>Tidbit record structure</h2>
<p>This is a typical tidbit which was generated using the Rhythmbox plugin:</p>
<pre><span style="color: #0000ff;">TIDBIT/0.1; libtidbit/0.1; Rhythmbox Tidbit Plugin v0.1</span>
<span style="color: #800000;">tidbit_userkey==usePzEg4Cl4g1ASdzpssVHtQ1hJJilS+ryiBWjF...
tidbit_table==audio/track
tidbit_created:=1281479640
tidbit_expires:=1313037240</span>
artist==Arcade Fire
title==Keep The Car Running
album:=Indie/Rock Playlist: May (2007)
genre:=Indie
year:=2007
play_count:=34
rating:=0.8
<span style="color: #800000;">tidbit_signed:=JyJ1fIwhRL5t3y9CACmshm/UibYVhvInxh7XVx4...</span></pre>
<p>The first line is the header. It states the version of the tidbit followed by the user agent. The rest of the record is composed of key-value pairs. The key has a strict format of lower-case letters and underscore. The value can contain any character above 0x1F, and is terminated by a new line. Other characters must be escaped. The first  four pairs are compulsory and they all contain &#8220;tidbit_&#8221; at the start to distinguish them from normal data. The userkey is a unique(ish) 1024 bit RSA key the user uses to identify themselves and also serves as the public portion of their signing key. It is base64 encoded and in the text above it is clipped but in reality it is over 100 characters long. Table is compulsory field which designates the subject matter. The created and expires values state when the record was created (must be in the past) and when it will expire. Expired records are no longer valid. These are currently using Unix time, but a more general format will be used in the future. This is followed by a number of values specific to the record type. Finally, the record is completed by a signature which signs the body up to that point (also base64 encoded). The signature is generated using the user key which signs an SHA512 hash of the record (up to that line). There is a hard limit of 2KB per record to prevent abuse.</p>
<p>The separation between the key and the value is either &#8216;==&#8217; or &#8216;:=&#8217;. These signify if to search for that value, or overwrite the value. When inserting a new record, a search is performed for any records which match all the key/value pairs with the &#8216;==&#8217; separator. These records are discarded as they are overwritten by the new record. To ensure the correct sequence in cases where an old record is re inserted into the database, the created date is checked. This allows a record to be updated by destroying an older version.</p>
<h2>Library</h2>
<p>A library (libtidbit) handles most of the complexity of creating tidbits, key handling, communicating with databases and performing queries. Keys are stored in a gnome-keyring. There are also python bindings which make creating plugins simple. Here is partial mock-up of an example use in Rhythmbox:</p>
<p><a href="http://brej.org/blog/wp-content/uploads/2010/08/tidbit_rhythmbox.png"><img class="alignnone size-medium wp-image-562" title="tidbit_rhythmbox" src="http://brej.org/blog/wp-content/uploads/2010/08/tidbit_rhythmbox-300x136.png" alt="" width="300" height="136" /></a></p>
<p>In this plugin, forming tidbits and passing the out is very easy. Presenting the data is the hard part.</p>
<h2>Databases</h2>
<p>There are several database backends used in tidbit:</p>
<ul>
<li><strong>Memory database</strong> is used to cache recently accessed records.</li>
<li><strong>Fork database</strong> is not a real database but rather a connection to two, which fetches records from the local database to minimise long distance transactions.</li>
<li><strong>D-Bus database</strong> is a service which allows several applications to share a single cache, and minimise external accesses.</li>
<li><strong>HTTP database</strong> is the method used for long distance transactions with the global servers.</li>
<li><strong>Sqlite database</strong> allows cached records to be saved between sessions.</li>
</ul>
<p>The default database supplied for libtidbit access is a caching fork of a memory database and a D-Bus connection. The D-Bus service wakes up automatically to connect the applications to the global servers.</p>
<p>There are just three database commands at the moment:</p>
<ul>
<li><strong>Insert</strong> to push new tidbits into the system</li>
<li><strong>Query</strong> to ask for tidbit GUIDs which match a query</li>
<li><strong>Fetch</strong> to get the full record from a GUID</li>
</ul>
<p>The GUID is actually the signature and is unique(ish) to each record.</p>
<h2>Example</h2>
<p>Lets do a 2 minute into of how to create and post a tidbit for a fictional TV application. The following should be the same in both C and Python (although C requires types).</p>
<h3>Step 1: Get a key</h3>
<pre>key = tidbit_key_get ("mytv", "MyTV v1.2");</pre>
<p>Here we supply the name of out application twice. The first should never change so we pick up the same key each time, and the second is used for the user agent.</p>
<h3>Step 2: Get a database</h3>
<pre>database = tidbit_database_default_new ();</pre>
<p>This gets the default database on the system.</p>
<h3>Step 3: Create the record</h3>
<pre>record = tidbit_record_new ("television/episode");</pre>
<p>This creates a new record we can put data into. The table name is compulsory so we supply it here.</p>
<h3>Step 4: Add the data</h3>
<pre>tidbit_record_add_element (record, "series_name", "Ugly Betty", TIDBIT_RECORD_ELEMENT_TYPE_KEY);
tidbit_record_add_element (record, "episode_name", "The Butterfly Effect (Part 1)", TIDBIT_RECORD_ELEMENT_TYPE_KEY);
tidbit_record_add_element (record, "rating", "0.6", TIDBIT_RECORD_ELEMENT_TYPE_VALUE);
</pre>
<p>Note the difference between the key and value entries (as the &#8216;==&#8217; and &#8216;:=&#8217; before). We may change our rating later, so that is a value, and so overwrite the records which match on the keys.</p>
<h3>Step 5: Sign the record</h3>
<pre>tidbit_record_sign (record, key);
</pre>
<p>Once a record is signed, it cannot be altered.</p>
<h3>Step 6: Insert it into the database</h3>
<pre>tidbit_database_insert (database, record);
</pre>
<h3>Step 7: Tidy up</h3>
<pre>tidbit_record_unref (record);</pre>
<p>Now we are finished with this record, we free it. By now, the record is happily on its way around the world.</p>
<h2>Development</h2>
<p>If you have interests in the semantic web/distributed hashtables, you have an idea for an awesome application, you found a fundamental error or you just want to have a bit of a play, then the <a href="http://cgit.freedesktop.org/~cbrej/tidbit">source is available</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://brej.org/blog/?feed=rss2&amp;p=561</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Tidbit: A global database for exchanging signed tidbits of information</title>
		<link>http://brej.org/blog/?p=540</link>
		<comments>http://brej.org/blog/?p=540#comments</comments>
		<pubDate>Wed, 11 Aug 2010 21:11:24 +0000</pubDate>
		<dc:creator>Charlie Brej</dc:creator>
				<category><![CDATA[Fedora]]></category>
		<category><![CDATA[Projects]]></category>
		<category><![CDATA[Tidbit]]></category>

		<guid isPermaLink="false">http://brej.org/blog/?p=540</guid>
		<description><![CDATA[Social everything Many of us, use a range of range of so-called Web2.0 services. Social bookmarking which enables you to recommend sites as well as tag sites with relevant words to make searching easier. Microblogging services allowing you to inform your friends (and others) of your status, while attaching tags to the message. Systems which [...]]]></description>
			<content:encoded><![CDATA[<h1>Social everything</h1>
<p>Many of us, use a range of range of so-called Web2.0 services.</p>
<ul>
<li>Social bookmarking which enables you to recommend sites as well as tag sites with relevant words to make searching easier.</li>
<li>Microblogging services allowing you to inform your friends (and others) of your status, while attaching tags to the message.</li>
<li>Systems which note the music you have listened to recently and share that with the community, recommending other music and events.</li>
<li>You can declare yourself as going to an event and check if your friends are too.</li>
</ul>
<p>This is a system which will keep expanding and undoubtedly within a couple years your bike will send out a message to say you are stuck in traffic which warns your friends that you will be late, while telling others to avoid your route. As you take a photo of the space invader mosaic, your phone will ping out the image with its GPS position to an urban art site with the tag of the artist, while informing you that there is another one just round the corner.</p>
<h2>Fear of clouds</h2>
<p>Great! The future is awesome! Well, not quite. There are several weaknesses to these systems.</p>
<ul>
<li>Each system requires a sign-up. There are solutions like <a href="http://openid.net/">OpenID</a> which make this easier, but generally you cannot use them anonymously very easily.</li>
<li>There are multiple providers for each kind of service, so you may have to keep several profiles up to date and post your data to several services.</li>
<li>The data is transferred to the service owners so only one company can make use of it. Users are giving this data out for free, and that&#8217;s the way they would like to keep it.</li>
<li>Services close. If you have built up a massive profile of contributions with millions of followers and the service dies, you are left with nothing. No you can&#8217;t take the data and create your own.</li>
<li>Competition is stifled. Imagine that you thought of a system like Facebook but better. Who would sign up for that? There is no chance of cooperation between companies to allow new competitors.</li>
<li>It is difficult to queue up data when not connected to the internet. You have to wait till you get home to write a review of that restaurant in Thailand which does great tofu.</li>
</ul>
<h1>So, this &#8220;Tidbit&#8221; thing?<a href="http://brej.org/blog/wp-content/uploads/2010/08/tidbit8.png"><img class="alignright size-full wp-image-536" title="tidbit8" src="http://brej.org/blog/wp-content/uploads/2010/08/tidbit8.png" alt="" width="184" height="80" /></a></h1>
<p>The principle is pretty simple. You don&#8217;t send your data directly to the service provides, but to a distributed open database. Each piece of information is a &#8220;tidbit&#8221;. Anyone can post, read and search for these tidbits. If you wish to provide a service, you read the tidbits that are of interest to you. No one gets to keep a monopoly on the data and everyone has the opportunity to to use the data to make new inspired products.</p>
<h2>Anatomy of a tidbit</h2>
<p>Each tidbit contains:</p>
<ul>
<li>Your username. The username is actually your public signing key. You can generate a new one whenever you like and is completely private (unless you reveal your identity to someone).</li>
<li>The date the tidbit was created and when it should expire. Most data becomes irrelevant after a year so that is the default unless you set it to be longer.</li>
<li>The table the data belongs in. For example &#8220;audio/track&#8221; would be talking about an audio track you have listened to.</li>
<li>A set of key value pairs which hold the data you wish to tell the world. There is no fixed structure so your tidbit can contain fields which will be ignored by some applications.</li>
<li>A signature to make sure it was you that generated that tidbit. It is impossible to adjust the data without damaging the signature, so no one can spoof as you.</li>
</ul>
<h2>You can&#8217;t trust this</h2>
<p><em>Stop! Reality time! This is bound to be abused by spammers, robots etc, just like the current services, but worse. I can&#8217;t trust anyone.</em></p>
<p>On top of this system, you can extend a web of trust. You can post a tidbit stating your trust of someone. Say you only fully trust the 10 people you know, but they trust 10 more and so on. You might only trust an individual a little (since they are several friends away), but if you combine a whole group of people you trust a bit, you get a fairly sensible picture. You can also partly trust someone who you have only a little confidence in due to information they posted, and perhaps only for some kinds of information (music taste only). Producers of original content are thus rewarded with respect of their audience, while building a network that gives people confidence in the data.</p>
<h2>I want my privacy</h2>
<p>Privacy is at the core of the system. You may choose to only reveal your username to your friends. Only they will know who you are. All applications work with a different auto-generated username, so unless you manually set your movie watching application to use the same username as your dating profile, you essentially remain as two different people. Obviously, all data you post is open for anyone to read, so posting personal information is a bad idea. This is not a system which sensibly replaces private social networks.</p>
<h2>Let&#8217;s get technical</h2>
<p>The <a href="http://brej.org/blog/?p=561">next post</a> will be somewhat more technical and explain the system in glorious geeky detail. There is a <a href="http://cgit.freedesktop.org/~cbrej/tidbit">git repository</a> you can take a look at and if you have questions there is a room #tidbit on irc.freenode.net, or leave a comment or email me.</p>
]]></content:encoded>
			<wfw:commentRss>http://brej.org/blog/?feed=rss2&amp;p=540</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Slanted monitors</title>
		<link>http://brej.org/blog/?p=526</link>
		<comments>http://brej.org/blog/?p=526#comments</comments>
		<pubDate>Wed, 14 Jul 2010 10:11:05 +0000</pubDate>
		<dc:creator>Charlie Brej</dc:creator>
				<category><![CDATA[Hate]]></category>
		<category><![CDATA[Web]]></category>

		<guid isPermaLink="false">http://brej.org/blog/?p=526</guid>
		<description><![CDATA[At my desk I have two 20&#8243; 1600&#215;1200 (4:3) monitors which I got rather used to. Unfortunately the hard-drive in my machine failed and I have been waiting over two weeks for a replacement (not sure if it is the university or MicroDirect being useless). Normally I would buy one and claim it back and [...]]]></description>
			<content:encoded><![CDATA[<p>At my desk I have two 20&#8243; 1600&#215;1200 (4:3) monitors which I got rather used to. Unfortunately the hard-drive in my machine failed and I have been waiting over two weeks for a replacement (not sure if it is the university or MicroDirect being useless). Normally I would buy one and claim it back and the problem would be solved within an hour, but the new university austerity measures forbid this. Instead, I have moved onto Christian&#8217;s desk and am experiencing his two wide-screen monitor setup. It feels a bit weird having pages which are very wide, but not very tall. Having one of the monitors vertical is equally creepy. So I came up with a compromise. Have the monitors slanted by ten degrees. This makes them <strong>both taller </strong><strong>and wider</strong>.</p>
<p><a href="http://brej.org/blog/wp-content/uploads/2010/07/slanted.jpg"><img class="alignnone size-medium wp-image-529" title="slanted" src="http://brej.org/blog/wp-content/uploads/2010/07/slanted-300x225.jpg" alt="" width="300" height="225" /></a></p>
<p>If you wish to try this yourself, just browse through this <a href="http://brej.org/blog/wp-content/uploads/2010/07/slanted.html">slanted frame page</a> and turn your monitors ten degrees to the right. Press F11 for full screen mode to make it look believable. This should work in Firefox and Webkit based browsers.</p>
]]></content:encoded>
			<wfw:commentRss>http://brej.org/blog/?feed=rss2&amp;p=526</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>ACSD in Braga</title>
		<link>http://brej.org/blog/?p=498</link>
		<comments>http://brej.org/blog/?p=498#comments</comments>
		<pubDate>Thu, 24 Jun 2010 16:02:59 +0000</pubDate>
		<dc:creator>Charlie Brej</dc:creator>
				<category><![CDATA[Personal]]></category>

		<guid isPermaLink="false">http://brej.org/blog/?p=498</guid>
		<description><![CDATA[We are working very hard at the ACSD converence in Braga. But because Doug and Will are involved, beer is never far away. This is Will&#8217;s attempt of reproducing the Isle of Man symbol Several acts of sillyness including Doug attempting to destroy the pool. I will try and upload the video as soon as [...]]]></description>
			<content:encoded><![CDATA[<p>We are working very hard at the ACSD converence in Braga.</p>
<p><a href="http://brej.org/blog/wp-content/uploads/2010/06/doug_dodgy.jpg"><img class="alignnone size-medium wp-image-501" title="doug_dodgy" src="http://brej.org/blog/wp-content/uploads/2010/06/doug_dodgy-300x225.jpg" alt="" width="300" height="225" /></a></p>
<p>But because Doug and Will are involved, beer is never far away.</p>
<p><a href="http://brej.org/blog/wp-content/uploads/2010/06/braga_beer.jpg"><img class="alignnone size-medium wp-image-499" title="braga_beer" src="http://brej.org/blog/wp-content/uploads/2010/06/braga_beer-300x225.jpg" alt="" width="300" height="225" /></a></p>
<p>This is Will&#8217;s attempt of reproducing the Isle of Man symbol</p>
<p><a href="http://brej.org/blog/wp-content/uploads/2010/06/braga_beer.jpg"></a><a href="http://brej.org/blog/wp-content/uploads/2010/06/braga_will_jump.jpg"><img class="alignnone size-medium  wp-image-502" title="braga_will_jump" src="http://brej.org/blog/wp-content/uploads/2010/06/braga_will_jump-300x225.jpg" alt="" width="300" height="225" /></a></p>
<p>Several acts of sillyness including Doug attempting to destroy the pool.</p>
<p>I will try and upload the video as soon as I can over this awful connection.</p>
<!-- degradable html5 audio and video plugin --><div class="video_wrap html5video"><video width="480" height="360" controls id="html5video-0" class="html5video"><source src="http://brej.org/blog/wp-content/uploads/2010/06/braga_pool.m4v" type="video/mp4" /><source src="http://brej.org/blog/wp-content/uploads/2010/06/braga_pool.ogv" type="video/ogg" /><object width="480" height="360" type="application/x-shockwave-flash" data="http://brej.org/blog/wp-content/plugins/degradable-html5-audio-and-video/incl/videoplayer.swf?file=http://brej.org/blog/wp-content/uploads/2010/06/braga_pool.m4v" id="f-html5video-0"><param name="movie" value="http://brej.org/blog/wp-content/plugins/degradable-html5-audio-and-video/incl/videoplayer.swf?file=http://brej.org/blog/wp-content/uploads/2010/06/braga_pool.m4v" /><p>Could not use HTML&nbsp;5 or <em>Flash</em> for playback. You can download the file as <a href="http://brej.org/blog/wp-content/uploads/2010/06/braga_pool.m4v">MPEG4/H.264</a> or <a href="http://brej.org/blog/wp-content/uploads/2010/06/braga_pool.ogv">Ogg Theora</a> file.</p></object></video></div>
<p>Yes accidents will happen.</p>
<p><a href="http://brej.org/blog/wp-content/uploads/2010/06/braga_doug_hurt.jpg"><img class="alignnone size-medium wp-image-504" title="braga_doug_hurt" src="http://brej.org/blog/wp-content/uploads/2010/06/braga_doug_hurt-300x225.jpg" alt="" width="300" height="225" /></a></p>
]]></content:encoded>
			<wfw:commentRss>http://brej.org/blog/?feed=rss2&amp;p=498</wfw:commentRss>
		<slash:comments>0</slash:comments>
<enclosure url="http://brej.org/blog/wp-content/uploads/2010/06/braga_pool" length="25709485" type="video/ogg" />
		</item>
		<item>
		<title>Migrating to Google apps</title>
		<link>http://brej.org/blog/?p=489</link>
		<comments>http://brej.org/blog/?p=489#comments</comments>
		<pubDate>Thu, 10 Jun 2010 10:34:06 +0000</pubDate>
		<dc:creator>Charlie Brej</dc:creator>
				<category><![CDATA[Google]]></category>
		<category><![CDATA[Linux]]></category>

		<guid isPermaLink="false">http://brej.org/blog/?p=489</guid>
		<description><![CDATA[I have always hosted my own @brej.org mail server on my home machine, upon which I have become more and more reliant, over the years. But one thing always worried me a little. I have a dynamic IP address, changes in which are tested for every 5 minutes and the DNS entry is automatically updated [...]]]></description>
			<content:encoded><![CDATA[<p>I have always hosted my own @brej.org mail server on my home machine, upon which I have become more and more reliant, over the years. But one thing always worried me a little. I have a dynamic IP address, changes in which are tested for every 5 minutes and the DNS entry is automatically updated (thanks to the guys at <a href="http://freedns.afraid.org/">afraid.org</a>). So at most there is a five minute window during which I cannot reach my home computer, and neither can my mail. Mail servers have an automatic cooloff and retry system, so if they cannot contact the target system, they will retry a few minutes, hours and eventually days later. This is great because an email simply doesn&#8217;t disappear if a server goes down for a while. You can always tell if someone is lying if they say that the email they sent must have got lost (never seen this happen). But what can happen, in my case, is the mail server attempts to connect to some random machine assigned by old IP address. Luckily these rarely run mail-servers themselves so nothing bad usually happens, but never the less there is always a chance and I like to sleep at night knowing it is all fine.</p>
<h1>Google Apps</h1>
<p>I was a little put off by the thought of someone else running my mail server because I was scared that many of the options I relied on were not going to be there, and secondly, I am always afraid that I will get lazy, stop being able to manage things like mail servers, get a mac and consume my own brain.</p>
<p>I already have a gmail account, but you cannot deliver the mail of an entire domain to gmail account. Instead, you can use <a href="http://www.google.com/apps/intl/en/group/index.html">Google Apps</a>. These are designed for businesses and organisations, but for individual (and small group) use it is free. You have to control the domain DNS entries. Firstly you have to prove that you have control over the domain, before the setup is allowed to begin. Setting up a single user and selecting all uncaught mail to go to that account was fairly straightforward. Once that is set up, you can flip the switch and point your MX entries to the gmail servers. The site has a guide including images of how to do this with most domain providers, although the <a href="http://www.google.com/support/a/bin/answer.py?hl=en&amp;answer=33353">images are very blurry</a> (not sure why). Then it is a case of waiting a couple hours while the DNS caches are refilled and your mail starts trickling to the new server. IMAP is fairly easy to set up. There is a folder called <strong>[Gmail]</strong> that holds the normal set of default folders, so in thunderbird (or any other mail client), you have to set the drafts and sent to point to those. There is no support for nested folders, which is a shame, but the folders themselves are just representations of tags, so it may not make as much sense. The biggest job is setting up the filters.</p>
<p><a href="http://brej.org/blog/wp-content/uploads/2010/06/filters.png"><img class="alignnone size-medium wp-image-492" title="filters" src="http://brej.org/blog/wp-content/uploads/2010/06/filters-300x202.png" alt="" width="300" height="202" /></a></p>
<p>I have a set of procmail filters which made prioritising very simple. To replicate this in Gmail, it took a few more filters. Most mailing lists make this easy by adding a list name to the headers and gmail recognises these ans suggests the right filter. What I didn&#8217;t realise at first is that filters can have reasonably powerful logical expressions, but you have to use the rather generic sounding &#8220;has words&#8221; filter. There is an implicit AND between the different filters, so using this field is the only way of getting an OR between a subject and a from field e.g. from:(a@foo.org) OR subject:(&#8220;[foo]&#8221; OR &#8220;bar&#8221;).</p>
<p><a href="http://brej.org/blog/wp-content/uploads/2010/06/filters2.png"><img class="alignnone size-medium wp-image-493" title="filters2" src="http://brej.org/blog/wp-content/uploads/2010/06/filters2-300x60.png" alt="" width="300" height="60" /></a></p>
<p>One annoyance is that it matches on whole words (with underscore being a valid letter) and I still haven&#8217;t found a method of  matching &#8220;CS_Newsletter_2010&#8243; but with any number at the end. <span style="text-decoration: line-through;">The second annoyance is the outgoing SMTP &#8220;corrects&#8221; your from address to be the one of the account you logged in with. This is annoying as I like to send from different addresses, but I guess I can still keep my home sendmail setup for that, or create an account (with a forwarding to the master account) for each outgoing address.</span> <strong>(UPDATE)</strong> Actually it couldn&#8217;t be easier. You have to validate that indeed an email address belongs to you by entering a code sent to it. It works with addresses of other domains too.</p>
]]></content:encoded>
			<wfw:commentRss>http://brej.org/blog/?feed=rss2&amp;p=489</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>TexMex evening</title>
		<link>http://brej.org/blog/?p=463</link>
		<comments>http://brej.org/blog/?p=463#comments</comments>
		<pubDate>Tue, 01 Jun 2010 16:49:23 +0000</pubDate>
		<dc:creator>Charlie Brej</dc:creator>
				<category><![CDATA[Food]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[Personal]]></category>

		<guid isPermaLink="false">http://brej.org/blog/?p=463</guid>
		<description><![CDATA[Sorry about the delay but, finally, here are some photos from the TexMex evening. You know it is going to be a silly night when your drinks acquire worms from the very first bottle. Will proudly placed himself in charge of making the margaritas. These were incredibly strong (and personally quite horrid).  Strange that we [...]]]></description>
			<content:encoded><![CDATA[<p>Sorry about the delay but, finally, here are some photos from the TexMex evening.</p>
<p><a href="http://brej.org/blog/wp-content/uploads/2010/06/beer_worm.jpg"><img class="alignnone size-medium wp-image-470" title="beer_worm" src="http://brej.org/blog/wp-content/uploads/2010/06/beer_worm-300x225.jpg" alt="" width="300" height="225" /></a><a href="http://brej.org/blog/wp-content/uploads/2010/06/will.jpg"></a></p>
<p>You know it is going to be a silly night when your drinks acquire worms from the very first bottle.</p>
<p><a href="http://brej.org/blog/wp-content/uploads/2010/06/will.jpg"><img class="alignnone size-medium wp-image-480" title="will" src="http://brej.org/blog/wp-content/uploads/2010/06/will-300x225.jpg" alt="" width="300" height="225" /></a></p>
<p>Will proudly placed himself in charge of making the margaritas. These were incredibly strong (and personally quite horrid).  Strange that we managed to get though three bottles of tequila, yet we still had plenty of limes. I suspect Will was not sticking to the correct measures.</p>
<p><a href="http://brej.org/blog/wp-content/uploads/2010/06/sam.jpg"><img class="alignnone size-medium wp-image-477" title="sam" src="http://brej.org/blog/wp-content/uploads/2010/06/sam-300x225.jpg" alt="" width="300" height="225" /></a></p>
<p>But still he managed to find a steady stream of willing victims.</p>
<!-- degradable html5 audio and video plugin --><div class="video_wrap html5video"><video width="480" height="270" controls id="html5video-1" class="html5video"><source src="http://brej.org/blog/wp-content/uploads/2010/06/tux_pinata.m4v" type="video/mp4" /><source src="http://brej.org/blog/wp-content/uploads/2010/06/tux_pinata.ogg" type="video/ogg" /><object width="480" height="270" type="application/x-shockwave-flash" data="http://brej.org/blog/wp-content/plugins/degradable-html5-audio-and-video/incl/videoplayer.swf?file=http://brej.org/blog/wp-content/uploads/2010/06/tux_pinata.m4v" id="f-html5video-1"><param name="movie" value="http://brej.org/blog/wp-content/plugins/degradable-html5-audio-and-video/incl/videoplayer.swf?file=http://brej.org/blog/wp-content/uploads/2010/06/tux_pinata.m4v" /><p>Could not use HTML&nbsp;5 or <em>Flash</em> for playback. You can download the file as <a href="http://brej.org/blog/wp-content/uploads/2010/06/tux_pinata.m4v">MPEG4/H.264</a> or <a href="http://brej.org/blog/wp-content/uploads/2010/06/tux_pinata.ogg">Ogg Theora</a> file.</p></object></video></div>
<p>And the there was the Tux piñata.</p>
<p><a href="http://brej.org/blog/wp-content/uploads/2010/06/mex_tux.jpg"><img class="alignnone size-medium wp-image-474" title="mex_tux" src="http://brej.org/blog/wp-content/uploads/2010/06/mex_tux-300x225.jpg" alt="" width="300" height="225" /></a></p>
<p>Tux will be remembered for his bravery in the revolutionary cause (and for sharing his sweets).</p>
<p><a href="http://brej.org/blog/wp-content/uploads/2010/06/salsa.jpg"><img class="alignnone size-medium wp-image-476" title="salsa" src="http://brej.org/blog/wp-content/uploads/2010/06/salsa-300x225.jpg" alt="" width="300" height="225" /></a></p>
<p>But the point of the night was the food. Lots of it. This is just one of the many bowls of salsa I spent four hours chopping.</p>
<p><a href="http://brej.org/blog/wp-content/uploads/2010/06/table.jpg"><img class="alignnone size-medium wp-image-479" title="table" src="http://brej.org/blog/wp-content/uploads/2010/06/table-300x225.jpg" alt="" width="300" height="225" /></a></p>
<p>This is only about half the food items. Shame I have no photos of the table when full as it was literally brimming with food. This was the first course of wraps and tacos.</p>
<p><a href="http://brej.org/blog/wp-content/uploads/2010/06/mai_ahn.jpg"><img class="alignnone size-medium wp-image-485" title="mai_ahn" src="http://brej.org/blog/wp-content/uploads/2010/06/mai_ahn-225x300.jpg" alt="" width="225" height="300" /></a></p>
<p>This was followed by chili con carne (two types), expertly carried by Mai Anh (who also deserves thanks for helping me make the guacamole too).</p>
<p><a href="http://brej.org/blog/wp-content/uploads/2010/06/students.jpg"><img class="alignnone size-medium wp-image-478" title="students" src="http://brej.org/blog/wp-content/uploads/2010/06/students-300x225.jpg" alt="" width="300" height="225" /></a></p>
<p>All together there were 35 people there which is a personal record. I even invited some of the better students round to try and bully them into doing something amazing over the summer.</p>
<p><a href="http://brej.org/blog/wp-content/uploads/2010/06/clyde.jpg"><img class="alignnone size-medium wp-image-472" title="clyde" src="http://brej.org/blog/wp-content/uploads/2010/06/clyde-225x300.jpg" alt="" width="225" height="300" /></a></p>
<p>Here is a misbehaving pair of banditos.</p>
<p><a href="http://brej.org/blog/wp-content/uploads/2010/06/me_and_tux.jpg"><img class="alignnone size-medium wp-image-473" title="me_and_tux" src="http://brej.org/blog/wp-content/uploads/2010/06/me_and_tux-300x225.jpg" alt="" width="300" height="225" /></a></p>
<p>Sadly this was a photo taken while I was carrying Tux to the bin for his un-ceremonial funeral.</p>
<p><a href="http://brej.org/blog/wp-content/uploads/2010/06/brave_lappy.jpg"><img class="alignnone size-medium wp-image-471" title="brave_lappy" src="http://brej.org/blog/wp-content/uploads/2010/06/brave_lappy-300x225.jpg" alt="" width="300" height="225" /></a></p>
<p>The brave little lappy managed to play Mariachi music for some 5 hours without dying (note the Dynamplifier).</p>
<p><a href="http://brej.org/blog/wp-content/uploads/2010/06/nachos.jpg"><img class="alignnone size-medium wp-image-475" title="nachos" src="http://brej.org/blog/wp-content/uploads/2010/06/nachos-300x225.jpg" alt="" width="300" height="225" /></a></p>
<p>And the final course was the nachos, which were indoors as it was very dark outside by that hour. Because we run out of salsa I (foolishly considering the drinks Will forced me to have) decided to chop up some more. Thanks to John for taking that job over while I tried to stem the bleeding.</p>
]]></content:encoded>
			<wfw:commentRss>http://brej.org/blog/?feed=rss2&amp;p=463</wfw:commentRss>
		<slash:comments>1</slash:comments>
<enclosure url="http://brej.org/blog/wp-content/uploads/2010/06/tux_pinata" length="16825005" type="video/ogg" />
		</item>
	</channel>
</rss>
