Sunday, 17 July 2016

On theory and practice

During the final year of my Zoology degree I was lucky enough to do my dissertation at Edinburgh zoo, studying communication between collared peccaries. At the time Edinburgh zoo was the only zoo that actually went into the enclosure with the peccaries. It turns out that the staff at the zoo aren't particularly keen on the students, seeing them as know-it-alls with no practical experience. Before I went into the enclosure I was made aware, by the keeper, that my classroom learning was worthless inside the enclosure and that I was to do exactly as I was told if I wanted to keep my access to the animals.

As our relationship thawed I found the keeper to be an absolute fountain of knowledge about the peccaries, their habits, quirks and behaviour. I found that my time working with the animals (I helped clean the enclosure, feed and tag them and help the vet when required) was where I really started to learn about behaviour. My classroom learning hadn't been a waste, it was just one part of a greater whole. It gave me a frame of reference from which to understand what I was seeing.

At that time I was heavily into the martial arts and I couldn't help but draw parallels. The drills and training sessions were an important frame of reference for me to draw on. They gave me a set of theoretical tools which I had to turn into a skillset or style that worked for me practically. I did that through trying these things in a practical setting (sparring, competition fighting and door work). This is almost always a one way process - if something doesn't work for you practically, then you adjust your frame of reference. The martial arts is a very good way of learning this one way rule. The consequences of trying to force your theoretical knowledge on to unwilling reality are usually immediately apparent (she can be a harsh mistress).

The point I am working towards here is that this is true of any endeavor. It really doesn't matter how beautiful your theory is, or how much it should work, if it doesn't match reality then it's wrong. Results (in a practical setting) or observations (in a scientific setting) always trump theory. Unfortunately it is really easy to fall in love with a theory and it's even easier to twist your view of reality to accommodate "glitches". However, I don't think there is a worse way to lose an argument than to have to run off with your tail between your legs when someone simply says "don't tell me you are right, show me".

As a quote on this subject, I particularly like this from an animal trainer Gary Wilkes:

Good science does not propose rules that are not confirmed by an objective observation of nature. Good science reveals nature as it is. If reality contradicts science, then it’s not really science.

Friday, 8 January 2016

Using an e-collar

Given that there is a movement in the Scottish government to ban e-collars (dog collars which beep, vibrate and give an electric pulse) I thought I would write something about how I have used them in training Bane and Silver. I am not writing from the perspective of an expert, but as a standard dog owner who wants to have well behaved and safe dogs.

First of all, it's worth saying that these collars are thought of as cruel and are often referred to as shock collars because of the electric pulse delivered to the dog. I think shock collars are exactly the right term for these training tools as they shock the dog out of whatever activity they are too intent on doing to listen to you. Unfortunately, the word shock also conjures images of people being tortured using car batteries or mains electricity. Having actually used the collar on myself I can confirm that it is the former rather than the latter (I would never use anything on my dogs that I'm not prepared to use on myself). The feeling is not in anyway painful, but it's a pulse that jerks the muscles and breaks your concentration.

I think of it this way - you need to use the minimum force necessary to break your dog's intensity so they listen to you. So, if I was fast asleep and you needed my attention it might be necessary to shake me. However, if I am concentrating on coding I wouldn't expect a work colleague to start shaking me to grab my attention when a simple "hello" would do the trick. It's also important to remember this is a training tool, it helps the dog to learn the required behaviour quickly and acts as a safeguard when things go wrong.

Here's an example of it's function as a safeguard from today's walk. I took the dogs out into the field I share with my 9 neighbours. It borders a public park with only a small fence in between. I put the collar on Bane because he's going to have a high intensity play - playing tug and chase with Silver and I don't trust other people not to let their dogs rush into our field. So, my dogs are being training to sit and stay while I throw a ball and they only fetch it on command. I've just let the dogs run for the ball when a lady walking her dog throws the ball right into our field. Her dog (a lab) rushes through the fence and starts charging towards Bane despite his owners command to come back. This is exactly how fights start. I called my dogs back and Silver returned, but Bane ran forward so I delivered a shock, Bane stopped and on command returned to me. I then put my dogs on place (a version of sit and stay that the dogs understand they must not move from regardless of what is happening) while I helped the lady get her disobedient dog back. The lab however had other ideas and his excitement had turned to aggression and he became quite challenging, so the shock delivered to Bane definitely stopped a fight.

It's easy to say "you shouldn't need to cruelly shock your dog to get it to behave", but this is the real world and I can't trust other people to control their dogs and create a safe environment for my dogs to have fun in. The point, however, is just that I used a training tool to help prevent something much worse from happening, which wouldn't have been necessary if the lab had been wearing a collar... Obviously I didn't just go out, buy a collar and start shocking Bane at random. I did it after being trained in it's use by a professional. I also didn't just settle for the first dog trainer I found. I went to a number of trainers (the first being a positive only trainer) and settled on Roddy Kirk (Be pack leader) after finally finding a trainer who had dogs that behaved the way I want my dogs to. It's quite an impressive sight watching a pack of 7 dogs walk down a narrow path way, see another dog approach and just separate to give the approaching dog plenty of space to pass by, then reassemble without a word of command.

Banning things isn't normally a good idea, but banning something that can be used to keep your dog safe is just plain stupid. I know the argument is that there are better ways to train your dog and therefore the collars are unnecessarily cruel. Neither of my dogs has ever shown the slightest disinclination to put their collar on. In fact Bane and Silver both love the collar, because they know that the collar means a high energy walk where they can run free. When I first got Silver, she had been badly treated and wet herself in fear when I took out a roll of tinfoil one day - thinking she was going to be beaten, yet she's never hesitated to put on her collar.

I put a lot of work into training my dogs so that they have the freedom to behave like dogs and have a happy life. I'm not an expert, so the training has been finding my way in the dark a lot of the time, but I guess that is true of the majority of dog owners. My experience is that most dogs simply aren't well trained and living next to a dog walking park I see a lot of bad behaviour. So in the real world it's nice to have a safeguard.

Saturday, 10 October 2015

BSL

Breed Specific Legislation

This is legislation enforced in the UK where your dog can be destroyed if it looks like a banned type of dog, regardless of it's actual breed or behaviour. This was introduced in 1991 as a response to several high profile dog attacks and an increase in the number of people using "prestige dogs" as weapons. I'm old enough to remember the media stories at the time.

Obviously there are two emotional sides to this legislation. In my view there's the "I'm afraid of dogs and therefore they should be killed so I can feel safe" argument (spoiler: I'm on the opposite side). Then there's the "I want a pitbull" argument. Unfortunately, in any discussion which has it's basis in emotion, it's impossible to convince the opposing side. I can't cure your fear of dogs, you can't stop me wanting one...

  • Are you seriously asking me to put my child's life at risk for the sake of your dog????
  • But your child isn't at risk from my dog...
  • YOU CAN'T KNOW THAT
  • My dog loves children, he's super gentle with them
  • WON'T SOMEBODY PLEASE THINK OF THE CHILDREN
  • Your dog might not kill children, but some people make their dogs aggressive. You can't argue that bigger dogs do more damage when they attack.

While while we continue the above argument ad nauseam, the dogs continue to die. Which is a shame, because we have a lot of evidence to show that BSL has been a complete failure in protecting the public. First off, "BSL has not succeeded in reducing dog bite-related injuries wherever in the world it has been enacted." National canine research council. If that's not enough of a blow to BSL, it's also not going to work in the future with some amendments because it's fundamental principle is wrong: "There is no evidence from the controlled study of dog bites that one kind of dog is more likely to bite a human being than another kind of dog. A recent AVMA survey covering 40 years and two continents concluded that no group of dogs should be considered disproportionately dangerous".

Unfortunately, the media has moved on from it's high profile cases of dog attacks, leaving in its wake new and harmful phrases like "large aggressive breeds". This means that stories about how the media portrayed dogs were completely wrong are very thin on the ground.

Despite the fact that we've a history worth of evidence to show that banning things is a terrible idea, we seem doomed to repeat the mistake over and over again. I find it soul crushing to think that we, as a society, look at a problem like "owners training their dogs to be vicious" and decide that eradicating the dogs is a sensible solution. That we would rather kill dogs than face our own fear of them. That we concentrate on "the dog problem" when we suffer 4 dog bite fatalities per year in the UK as compared to road fatalities in the thousands. No one has considered banning cars because it's simply not a workable solution...

I assume that during the talks prior to the introduction of the legislation someone must have said "Perhaps the problem lies in the owners, maybe we need to concentrate on the fact that society is creating people who want to hurt each other and are using dogs to achieve that goal". The fact that the lone voice of reason was lost in the desire to be seen to be doing something quickly is what really makes me sad.

Sunday, 28 June 2015

A year of Bane

Big decision

Almost a year ago, I set off to Leeds to buy a puppy. After an awful lot of research I decided that a presa canario was what I wanted after I fell in love with the dog in the link. I returned with Bane, my 8 week old puppy after a lovely day playing with all the puppies and falling in love with Major (Bane's dad) whose looks and personality make him the poster child for large, calm dogs.

Lots of people in my life were quite concerned about the large quadrupedal killing machine I was bringing home. Fortunately, after actually meeting him everyone has changed their minds. However, I took my job of raising Bane to be a calm, well mannered dog, quite seriously and began socialising him from day one. I have been really lucky to find an awesome group of people to walk and train Bane with. It's been great fun learning how to handle a large dog and I thought I would write up some of the things I've learnt.

Raising Bane

At first, I concentrated on teaching Bane the simple commands everyone does: sit, come, lie down, stay etc. As everyone seems to find out quite quickly, your dog will come to you 100% of the time inside the house or garden, but perhaps a little less than that when you actually want the to - like in the park! My socialisation seemed to have worked a little too well and Bane would be too excited about playing with other dogs to listen to me. So i got some private tuition for him from a fabulous dog handler. I learnt to control Bane's excitement before he got to the other dogs and show him how I wanted him to interact with other dogs. This meant I had to be super calm during the interaction and not tense in case Bane ran off playing with another dog. The best piece of advice I got during this phase was "put your dog in as many challenging situations as you can and will him to do his worst, then you can correct his behaviour". Having the confidence to let your dog make mistakes and knowing you have the tools to correct any unwanted behaviour really speeds their training up and I definitely believe it strengthens the bond between you and your dog.

A lot of the tools to correct your dogs behaviour seem centred around keeping your dog calm during a given interaction. Stopping Bane being excited and rushing over to meet a new dog has dramatically reduced the amount of times he gets told off by another dog and increases his ability to listen to me when I want him to come away. On the pack walks we go to, each one starts off with the reminder "excitement is the biggest cause of fights between dogs".

It takes two

The next phase in what was really my training, not Banes, was to realise that it's not all about my dog. Up until recently, I'd really focused on having Bane do what I tell him. However, I noticed that Bane was an absolute prince on the pack walks amongst lots of other well mannered dogs, but out in the real world, he was often attacked by other dogs or people would create confrontational situations with him. For example, a man once shouted at me to get my dog on the lead, because he didn't want his family to have to walk past my frenzied killing machine. I should point out that at that moment in time, Bane was away from the path, oblivious to what was happening, sniffing his way through the undergrowth. I reacted in my own standard way, by explaining that if the man continued to shout at me the dog would be the least of his worries. Bane immediately sensed the confrontation and raced over to protect me. He placed himself between me and the man and barked his warning. I slipped a lead on Bane and walked off, however, I later realised that I should have taken control of the situation earlier.

So now, when I walk Bane, my focus is less on controlling my dog in a difficult situation and more about managing each situation so that Bane can just act normally. I have found it to be a really effective method for having a nice walk and it's quite easy to do once you get past that typical British reserve. There's a tendency for two people walking past each other not to speak or make eye contact. I think this makes their dogs think that it's up to them to take the lead then. If the owner of the other dog is a bit afraid of dogs, this can make their dog more protective and less likely to be happy if Bane wants to say hello. So, rather than let the dogs take the lead, I'll give a smile and say hello, perhaps make it clear that Bane's friendly. If that relaxes the other person, the dogs will follow suit if it doesn't then I'll call Bane over and put him on the lead.

I've also found that asking someone if their dog is friendly is a good opener. If the owner greets you with a cheerful response, I've always found the following interaction between the dogs to be friendly. I've also found that it sometimes jolts the other owner into action, a couple of times I've had the response "she can actually be a bit snippy sometimes, I'll pop her on the lead mate".

Survey of one

Obviously, these are my thoughts having reared a dog to the grand old age of one :) so I'm not claiming they are universally true. I do however, thoroughly recommend pack walks, socialisation and not getting a dog unless you plan to spend lots of time enjoying it!

I feel I should mention at this point that I actually have two dogs now, Bane and the lovely Silver - who came pre trained. However, everything I've said about walking Bane seems to apply to walking Silver too, especially the parts about setting her energy levels.

Saturday, 5 July 2014

Past, present and future me.

I think more than is probably good for me. I think about conciousness, time and the nature of reality along with a whole bunch of other things. My current wondering is whether or not I can put into words my thoughts on what it is that makes me me. For what it's worth, I'm guessing the answer is no.

As an old person, I have a long and rich history of being me.

  • First there was baby me,
  • then child me,
  • teenager me,
  • 20's me (that guy! Ha, what a hoot),
  • 30's me,
  • more recent me,
  • there's right now me,
  • tomorrow me,
  • Monday morning me (man, I feel for that guy)
  • future me.

Of all those people, "right now me" is the guy I feel closest to. Having said that, I'd probably be prepared to put "right now me" to some small difficulty for tomorrow me, or even a probably future me. Looking back though, I barely remember baby me and I can certainly empathise more with people at work or my family than I can child me - which seems a little strange. Especially when you think that past me actually happened! My memories of past me are surely what go to create "right now me", future me, however, is just a figment of my imagination.

Past me

My brain makes sense of who, what and where I am from my memories. In a simple example, I can follow my train of thought in this blog because I remember why I wanted to write it, I remember sitting down with a cup of tea at my desk - causality is complete. It's easy to understand what happens when that breaks down too - when you walk into a room and forget what is was you went in for. Obviously, my relationship with me goes back further than that, I sat down at my desk to write this blog post with a cup of tea, milk and no sugar, because 30's Ant decided to stop taking sugar in his tea. In a less trivial and slightly more esoteric example, the way I deal with my colleagues at work is different to that of other people. It's different to the way 20's and 30's me did. But there's a fading silver thread that connects us - showing the evolution through time of right now me.

None of those past me's exist in anywhere but my memory and my memory is faulty. I know this because other people's rambling stories about 20's me don't really gel with the handsome young rake I recall. Also - science says it's so - well, the Atlantic anyway. So, I've interpreted my life differently to others and my memories aren't super faithful captures of reality. They are more of an artists impression of stills from the life of me. So, these faulty impressions are what keep me seeing my life as a joined up journey from birth to death. It's not having the same body (as I'm replacing it, bit by bit, over the years of my life). It's certainly not reality. It's just a series of memories which create a complete, unbroken narrative.

Broken narrative

When I wake up in the morning and recall going to bed that night, there has been a definite break in the flow of the narrative. Your internal memories just stop, then start again 8 hours later. If, during your sleep you were cloned, I think most of us would naturally agree that the person who woke up next day in your bed would be you. The person that woke up in the cloning room wouldn't.

Who would the person waking up in the cloning room be? They would wake up in a strange room with all of your memories, right up to going to bed that night.

I think the answer becomes a little less obvious if you now imagine the Star Trek transporter. This device would disassemble people in one location and then reassemble them in another. Is the newly materialised person you? If the answer is yes, then the only reason it can really be you is if the definition of you is your memories.

Now me

It is easy to imagine seeing an unbroken narrative in action when you are at work interacting with a colleague and one moment has to follow another in a sensible order. Even though time has past it's easy to believe that "start of the conversation" you is the same person as "end of the conversation" you. But she isn't, "start of the conversation" you is dead, consigned to the foot notes of history. You can't go back to her and get her to change the course of the conversation.

If we follow this logic, every attempt we make to define "now me" becomes, in the very moment of cognition, "past me". "Now me" seems to exist in an almost impossibly thin fragment of time, by the time we have recognised that something is happening to "now me" it's a memory.

Future me

This is thus the only guy who can really be relied on to get anything done. So he's also the guy we have to protect and care for. Imagine you are told you will be given £20 and a punch in the face. If you could assign each of those to a particular you, I'm guessing most people would assign punch to past you and the money to present you for future you to make use of? How much strain "now you" will take on to make things easier for "future you" seems to vary greatly. I find it quite an interesting concept and way to think about reality. To the point where I think in this manner. If I am performing some particularly onerous task for future me, I hope he'll appreciate it, or if I'm being lazy, I'll think "Ha! Screw you Monday morning Ant I'm leaving it to you to fill the car with petrol".

Who am I?

Well, past me is clearly a lie - me as seen though a glass darkly. Present me is too fleeting, gone before I ever get to know him. Which just leaves future me, who doesn't even exist yet and he's only a figment of my imagination! Each of my memories is just a frozen instant in time like a single frame in a movie. Just like a character in a movie, I am the summation of all of those snapshots played at 25 frames per second to create a coherent narrative. I am that narrative...



Good enough

I was reading a blog post by one of my favourite authors talking about how difficult he finds it to hand in a manuscript.

"It’s a hard thing for me, letting go of a manuscript. Other authors are very matter of fact about it. But for me, obsessive word tinker than I am, I hate knowing that after a certain point I won’t be able to go in and fix things any more."

I feel something very similar when I'm coming to the end of a milestone and the code I've been working on is getting close to "complete". Because I am paid to create functionality and not art, it's actually possible for me to over polish the code. So I thought I would write about what goes through my head when I'm trying to decide if my code is ok. Obviously, the code has to meet the written requirements - otherwise it is deemed "not good enough" by QA.

Meeting the written requirements

  • Obviously, the software I write has to meet the immediate functional requirements - it has to work as intended.
  • It, usually, also has to meet the design requirements - it has to look right.
  • There are also user experience requirements - it has to feel right.

However, the written requirements tend to deal with the tangible parts of the software. It now becomes a judgement call on the part of the developer whether the code she has written meets the required standards for the unwritten requirements - things like maintainability, readability, reusability, extensibility, architecture and test quality. How important these requirements are depend very much on what you are building and the time frame your are working in.

I genuinely believe there is more value in a developer who develops good quality software quickly, than code poetry slowly. I justify this by saying that after a certain level of quality in a piece of software the effort starts to out weigh the gain and the reason for putting the effort in becomes less about the software and more about developer ego. I think the developer who understands this and judges correctly when to stop is the better craftsman.

Meeting the unwritten requirements

Software is constantly evolving and it's sometimes not possible to come up with the "best" solution for a piece of code until after it's been in use for a while. We were seeing lots of forking in the code where data needed to be processed differently depending on certain circumstances, so we decided to write a more elegant method of dealing with this. I closed the code review in which the final outcome of the discussion was to leave the code unfinished and revisit it to see how it's actually being used. The more time that has past, the more I think that turned out to be a really good idea. We waited to see how other developers would need to use it and how some might try and abuse it. The solution we have now makes the common forms of abuse much more difficult, while aiding the current common usages.

The above is, in my opinion, an example of where good quality code really shines. The code doesn't just perform it's own task, it creates a process for other developers to quickly perform similar tasks. When given a new task, most developers will look at the system and see if something similar has been done before. At some point, your code will likely be used as a base for something similar, or a small part of it will be used as the pattern for "doing x" in the system. You can aid in this by making the code easy to read and understand. If it's loosely coupled, it'll be easier for other devs to work into something new and that new thing will likewise be loosely coupled.

I am a big fan of using tests to help other developers understand the subtlety of the requirements of my code. If I make an assumption during the development of some code and it turns out to be wrong, that's a test right there. If a future dev makes the same assumption and introduces a bug because my tests didn't fail - that bug is on me.

When trying to decide if my code is "good enough" yet, here's what usually goes through my head:

  • Would I be ok seeing this code replicated through the system.
  • Is this problem local to this code, or do I need a global solution for other devs to use.
  • Is this problem properly tested.
  • Can I justify changing this?

Thursday, 29 May 2014

Arguing with stupid people

Changing your mind in response to an overwhelming argument is as fine a quality as it is a rare one. I was reminded of this fact yesterday in discussion with the current Mrs Ant. Then, again, today when a friend posted a Mark Twain quote I like and I thought it might make an interesting blog post.

"Never argue with stupid people, they will drag you down to their level and then beat you with experience."

Mental models

We all have a mental model of the world in our brain, our version of the world, our place in it (the centre) and our friends and acquaintances as satellites orbiting us. This model is super useful for us, as it allows us to play out scenarios in our heads before trying them out in the real world. For example, I am in a room with my boss and his boss. My boss makes a suggestion which I think is stupid, rather than blurting out that fact and suffering the consequences I can run a series of scenarios in my head, before commenting.

  1. Hey Bob, 1963 called, they want their shit idea back, oh and November the 22nd says it wishes it was you instead of Kennedy.
  2. Yea, nice one, or we could do x, might be quicker?

Now we run the simulations and go through the likely outcomes.

  1. Bob loves a good roasting and respects opinionated people. Bob's boss looks like a hard businessman, just the type to take the hard line.
  2. It's a pleasing answer, but it puts across two points, which makes me come across as uncertain.

It may seem unnecessary to state that this exchange all goes on inside my head. That the Bob referred to here is my mental model of Bob, and may, in fact, not represent the real Bob in every aspect. Yet the world is a complex place and we are often surprised when an interaction goes completely differently to the simulation. Unfortunately, we don't think very much about how poor a representation of the real world our mental model is. This is largely because we need to have faith in our simulations in order to act without undue hesitation.

Changing the model

Each time one of our simulations leads us ary, it causes us to restructure our mental model. This is fine for non weight bearing parts of the model, for example, realising you actually do like olives. For most people, there's not too much re-shifting of heavy mental furniture to accommodate this new fact. This shifting of mental furniture takes a great deal of mental effort.

If I can stretch the analogy further and imagine changing my mental model to switch my opinion of a co-worker to be like moving the sofa in my living room. As well as expending the energy to move the sofa, I have to adjust all of the things associated with it. My mental model must remain consistent, useful and operational in the same way my living room does. I can't just turn the sofa to face a wall and continue using it as is. I need to be able to see the t.v. and ensure I get enough light to read.

This effect is even greater when being asked to accommodate new information. This is why some of the most persuasive arguers will take the time to help you build the mental frame work into which they want you to place their new idea long before they ever get to the idea itself. In his excellent books Douglas Hofstadter takes us on wonderful walks through Godel's theorum, Escher's art and Derek Parfit's transporter thought experiment before he gets to the subject of conciousness. Those amazing Eureka! moments are where the last piece of the puzzle slots gracefully into your newly formed mental model of the world.

Mentally lazy

Obviously, some people are quite energetic mentally, to them, it's fun to listen to someone and say "Hey, you're right, if I knock a wall down here and add another window there I'll get so much more light in and have room for that chaise longue!" (some people have weird taste in thoughts). Others are not and laziness can cock a deaf ear to even the most simple idea. This is why you can be demonstrably correct and still not get someone to listen to you. This is why people get angry with you for being right sometimes, because accepting your right idea requires too much mental restructuring. Some beliefs are simply so entrenched (so foundational) as to be literally unchangeable.

Entrenched beliefs may not be as detrimental as they first sound - if my mental model is right most of the time, but you have shown me an obvious edge case where it is wrong, what is the cost / benefit of changing my entire model? Remember, all of our mental models are incomplete, their value is in how well they help us predict our future, not in how logically consistent they are. This is nicely illustrated by Philip K. Dick, who was a barking mad drug hound, yet, never the less, operated at the highest intellectual level - giving talks on reality at universities. This was because, despite believing we were still living in biblical times, 50 years after the death of Christ, his mental model made correct predictions.

When I was younger I read Richard Dawkins' The Selfish Gene and the other books in that series. They moved my mental furniture through reasoned argument and I was a big Dawkins fan for nearly 30 years. I now see him arguing from a position of complete entrenchment as a die hard atheist / materialist against equally entrenched religious people in what are supposed to be serious debates. I know he can't possibly expect to change his opponents views (my internal model refuses to shift to allow me to see him as a fool) which leaves me thinking that he supposes I am a sufficient fool to be influenced by this sham. Sigh...

People's mental models of the world are important to them and serve as the foundation of who they see themselves as. The key to being successful in changing their opinion is to help them see the benefit of shifting to your model rather than proving theirs is wrong. I guess it also makes you a nicer person to understand when being right doesn't really matter.

Monday, 21 April 2014

At the beginning

In Newton's day, it was believed that we had the fundamental equations to the universe. Knowing these equations were the key to understand everything. We could know the future of the universe simply by applying the maths. Well, we could until Heisenberg, Lorenz and Einstein muddied the waters. They showed that there were things that Newton's equations didn't account for.

We seem to be in the same Zeitgeist at the moment, where significant scientists can safely ignore evidence for phenomena which they know to be impossible. Now, this is a perfect acceptable stance if you know what's going to be discussed is impossible, or that you already have a completely plausible theory which is the only one to fit all the facts. If you are in a lift with 1 other person and you know you didn't fart, a discussion on "bottom elves" isn't going to sway your opinion on the identity of the culprit. However, the key factor here is that you are certain of your conclusion, because you believe your method of deduction to be perfect. Historically, of course, we've never been right yet.

It's important to note here that I am all for ignoring stupid people with stupid ideas. It's impossible to investigate every new idea that challenges firmly held scientific beliefs. However, you have to look at the person behind the idea. In 1970 Hannes Alfven won the Nobel prize in physics, yet he had papers rejected by technical journals on the grounds that they did not agree with current theoretical physics. I don't think I'm stretching things to say that Nobel prize winners have earned the right to disagree with the current dogma.

Science is young

I recently heard Noam Chomsky described as being a polarising figure in linguistics: is he right or wrong? That, to me, is a question based on the belief that we are so close to "finishing" linguistics that we can ask questions about being right or wrong. In a game of golf when the player is on the putting field we can make similar statements about a shot. It's a good shot if the ball goes in the hole and a bad shot if it doesn't. However, we have different definitions of a good shot from the tee, because we can't expect a hole in one every time. Now imagine teeing off in Edinburgh for a hole in London - the definition of a good shot there could be broadened all the way to "did the ball travel south?".

This is where I believe we are with science, really quite close to the start. Despite the computers and space travel, I suspect there's still a long way to go yet and this makes a big difference to the questions we should be asking and the attitude towards new ideas we should be having. I always find it helpful to remember the massive gaps in our knowledge or our total failures when faced with the dogmatic certainty of a tv presenter like Brian Cox.

  • We don't know how 2 dimensional DNA encodes the complex 3 dimensional structures required for life (we're basically stuck in genetics).
  • String theory (we're basically stuck in physics).
  • People still die.
  • Nassim Taleb can make a living explaining to financial workers that they still don't understand chance.
  • Our attempts to build a robot that can walk on two legs are in their infancy.
  • Despite the presence of the sun, there's an energy crisis.
  • Dark matter?
  • We need a singularity to explain creation.
  • We don't understand what conciousness is.

Despite that last gap in our knowledge, many still believe that we are so close to understanding everything, we'll soon be able to create sentient machines. Anyone that's tried to use a printer's OCR software will know that we are still safe leaving little Timmy alone with the toaster.

Conclusion

Embrace not being all knowing and relax your expectations. This way we could comfortably praise Chomsky as having "hit the ball south" and discussing his ideas as progress along the way. To me, if Sheldrake is right about morphic resonance it's pretty much a "hole in one" scenario. The most I expect from him is to "hit the ball south" and that his experiments will be noted in history as markers along the way to some greater understanding of conciousness or reality. We are close to the beginning of science and we would progress faster if we started acting like it.

  • We need a healthy, skeptical outlook without dogmatic disbelief.
  • We need alternative sources of funding and a viable alternative to big science.
  • Respect for scientists outside the mainstream.
  • A more open scientific media.

Tuesday, 11 March 2014

I want off

Today is the day I lost my last remaining ounce of hope. I want it to go on record I tried with you people, I really did. I wanted this work, I wanted us to be happy, but.. we just can't. Oh and by the way, it's not me... it's you.

First, this is a thing

I found this today: literally unbelievable. It's a collection of references to The Onion articles taken as factual by the author. I just don't want to live in a world where satire has been rendered obsolete... either because people are too broken to recognise it, or because reality is too broken for people to tell the difference.

Secondly, parcel deliveries

I ordered a book to my work address, which is a company name at an industrial estate. First attempt was made to deliver on Sunday. Today, I received a text saying delivery would be attempted at some point after 5. Just after 5, I thought I would stop by reception on my way out and check if the delivery had been made. The van was parked outside and the receptionist kindly caught up with the delivery driver to ask him if he had my parcel. He stated he had one more left to deliver, for Sarah, in my office. I explained I had a text stating the delivery was due today, at which point he looked at me and said "Are you Anthony?". I confirmed that I was and he replied "Ah great, your parcel is in the van, I was going to deliver it later, so you've saved me a trip" and gave me a big grateful smile.

Thirdly, ban bossy

Ban bossy Really? I mean, seriously? All I have to do, in the opinion of Jennifer Garner, Beyonce and other such assorted ass-clowns is not call my daughter bossy in order to rear a confident, self possessed young woman brimming with self-esteem. Wow, well that's just lifted a massive burden from my shoulders, because, up until now, I'd foolishly assumed rearing a child might be a super complex task which couldn't be boiled down to a simple slogan!

I've needlessly fretted that I may have to handle each scenario based on it's own merits, with no real road map to guide me but an abiding love for my child and desire to do what was best for her in the long run (which, I'd chauvinistically thought might include teaching her when it was time to give daddy just a touch of peace and shut her noise hole). However, I now realise that it's only male children that need to be prepared for the harsh realities of life by learning to curb their natural self obsession in order to become more rounded and caring individuals in the future. Girls on the other hand, need to be encouraged towards narcissism so that one day they'll have the self confidence to stand in front of a camera and say, with a straight face, "I'm not bossy, I'm the boss". Imagine your pride as you turn to the person next to you and announce "That megalomaniac douche burger is my daughter".

Previously, I had failed to realise how powerful a word bossy is. As Anna Maria Chavez tells us "When I was growing up, I was called bossy" and we can see that she's turned out to be a complete idiot, so... case closed, lets ban the word bossy. The powerful info-graphics make the case even more air tight by claiming "Between elementary and high school, girls’
self–esteem drops 3.5 times more than boys’.", obviously with a statement that powerful, you don't need to cite the study involved, it's just a fact! The correlation between a self reflective property measured in juveniles and the use of the offensive word being self evident and thus requiring no proof.

I shall be spending all my resources on finding a way off this planet and leaving you to it.

Saturday, 1 March 2014

Considered harmful: rockstar developers

Ten years ago when I told people that I worked with computers I would often get the response "you don't look like a geek". These days no one seems to think it strange. I currently work in an office in which some of the developers talk about football and have meaningful social relationships. Being a software engineer has become somewhat cooler; as part of that "coolification" process, certain things have changed and other things, which always existed, have been named and magnified. Rockstar developers have always been a thing, but now they have a name and are often seen as desirable. Before I start to explain why I think rockstar developers are harmful, lets define one and the circumstances in which they are harmful.

Characteristics

  • Above average understanding of their language.
  • Love of esoteric knowledge.
  • Egotistical style of programming.

The first two items on the list aren't in any way negative, however, they can lead to problems if not applied responsibly with reference to the environment they are used in. It's the third characteristic that I believe leads to harmful behaviour, because the "me, me, me" can overrule common sense when it comes to the application of logic in a given environment. So there is a tendency to create overly complex solutions to simple problems as small monuments to personal vanity.

Habitat

If you are a rockstar developer as described above, working on a solo project, then go ahead, knock yourself out. It's like being a singles tennis player, there's no need to alter your style for the benefit of others. Have fun, it's your code.

If you are working in a commercial environment, being paid to do a job, then it's not your code. If you are working with a small team of like-minded rockstars, then I hope it's the nirvana it should be and once again, have fun! Unfortunately, the likelihood is that you are working as part of a team of individuals of mixed ability. This, to me, is where rockstars become harmful. It's almost always a problem related to the egotistical programming style creating problems for others. If you are part of a team, then you need to act like it and put the needs of others above your own need to show off.

Obfustication

Yea, sure, bitwise operators are interesting and using them can be a shining badge of your elite status, I mean, how else will people know you can use them unless you do? In a large team, with high code churn, it's pretty likely that someone else will have to read / understand and then modify your code. If you have code reviews, then it's a certainty. Here's an illustration with some reasons why obfustication is awesome and my rebuttals. It's not a real conversation as I wouldn't change someone's code without talking to them first.

"Hey broheim, I was checking the logs and saw you changed my code dude, what's up with that man? It's like, you took my gnarly code, babyfied it. You know your code doesn't do the same thing right?"

"Yup, it's more readable now and therefore maintainable by all members of the team, so I figured it was worth changing. I understand that your code is checking purely for -1, but that's a different discussion."

  • Original code: if (!~index) index = 0
  • New Code: index = index < 0 ? 0 : index;
  • The new code is a conditional ternary operator which is used quite widely in the codebase, if it wasn't, I'd have written:
    if (index < 0){
        index = 0;
    }

Here are the most common reasons I've heard as to why something like the original code is better. In my rebuttals my arguments are designed to be for the general case of unnecessarily complex code while still referring to the specific example.

It's not my fault everyone else is an idiot.

Although I've put this point in it's harshest possible form, this is the point I feel has the most value. Finding code you don't understand and looking it up is a very valuable way of learning. In this case though, I'd argue that it's not the right code in the right place, it's just a block of vanity code. Even though you understand that the ~ operator switches the 0's and 1's around in the binary representation of the operand, it still isn't immediately obvious that the code is checking for the case where index is equal to -1. There are enough complex things which require complex solutions, lets leave simple things as simple. It's also hopelessly naive to assume that people will understand unnecessary complexity just because they should. It's like leaving your wallet in your unlocked car because no-one should steal it.

Optimisation dude!

Ok, this is a blog post all on it's own, so we'll gloss a little here. Lets just say that there are two forms of optimisation that are important in a commercial environment.

Code Optimisation

Most important point: optimise where it hurts. Looking at the performance difference in time between our different approaches is all well and good, but we need to take into account the environment in which we are working. At the end of this code, we then append the result to the DOM. Optimising a conditional in this environment is like optimising your drive from Glasgow to London by running to the car (perf. test).


Graph showing the similarity in speed between multiple conditionals when compared with the act of accessing the DOM

Maintenance optimisation

In general it is much easier to show the cost to a company in lost man hours caused by hard to maintain code than it is to show the boost in profits caused by pre-optimised code (I'm referring here to code optimised by a developer prior to any requirement from the customer). So it's usually preferable to write maintainable code first and then optimise where it's hurting.

Complexity is better

I know this may sound strange, but I have first hand experience of a culture in which a complex solution to a problem was considered better by virtue of it being more complex. After a long discussion of the differences between two possible solutions, it was finally agreed that both solutions achieved the same goal. One group insisted that the more complex solution was better "if you are a developer", yet were unable to define a single benefit of the complex solution over the simpler one. I have also been told, as a put down, "yes, I understand your proposal, it's so simple even my grandmother could understand it". Despite how crazy this sounds, it's actually an easy trap to fall into. If something has been hard to work through, it can be difficult to accept that there is an easy solution, you want it to be difficult and require a complex solution to justify the time it took you. Again, beware of your ego.

Conclusion

Coding is interesting and those of us who do it for a living are lucky, we get paid to do fun stuff. Being good at coding is something you want to show off, but like many things it's not the flashy stuff that shows your mastery. A complex piece of work, that is simple to read and understand is the sign of great coder. The good thing about this attitude is that it scales. What you think is easy to read depends on your level of competence, to someone less experienced there may be logical tricks you've used that they have trouble following. This is where they will learn from reading your code, but without the unnecessary obfustication we've been discussing.

Saturday, 8 February 2014

Code reviews

I have been doing a lot of code reviews recently. Obviously, criticising someone else's work in a constructive manner can be a tough skill to acquire, conversely, I also used to feel quite patronising making positive comments. After a while though, I think you hit your stride and develop your own style of commenting. It quickly becomes pretty obvious that you need to have a clear idea in your own head of what you are trying to achieve with your code reviews. When you start to think about what you want to achieve, you realise how much value you can get from code reviews. Yes, they are time consuming, but consistent reviewing can really add a lot of value.

  • Checking for security vulnerabilities
  • Sense checking for possible bugs
  • Enforcing the agreed architecture of the project
  • General code quality
  • Enforcing code standards
  • Training

That's a list of what we've been trying to get out of our code reviews. Because they have to be consistent, it really helped having a clear idea of what we were looking for and what our definition of "good enough" was. In a commercial environment, it's important to make only those changes with a business case and not use code reviews as an excuse to endlessly polish. Thinking "hmmm, I wouldn't have done it like this" isn't reason enough to change someone else's work, you need to refer back to your list and see if there is an actual reason. I found this the most difficult part of learning to give code reviews. I often felt strange glossing over blocks of code I didn't feel were particularly well written because they were "good enough" while commenting on jsDoc, line spacing or naming conventions which didn't meet coding standards.

Finding your voice

Through trial and error I found that asking questions rather than making statements is a good way of introducing training into code reviews. When I spot something I don't like I often ask questions around the area. It's amazing how often forcing someone to articulate what they are trying to achieve creates a eureka moment. It suddenly becomes obvious what is wrong when you notice a series of function names don't correspond to the language you are using to define the problem.

It also took me a while to realise that I didn't have to know the answer to everything in order to be eligible to do code reviews. I know that's one of the points of peer review, but it's difficult to keep that in your head when you are reviewing. I like a conversational tone in a code review to help alleviate the idea of being judged or being confrontational. I also think that it helps make the process two way. If you tell someone to check for a valid user name, they will likely just implement what you've asked for (you, who haven't been working on the code for the last 2 weeks). However, if you ask what happens when there isn't a valid user name you get input from the person who wrote the code.

At the risk of over stressing this point, you don't have to have a brilliant solution for every comment you raise. "Hmmm, something in this just doesn't sit well with me, but I am not sure what. What do you think?". Is a perfectly acceptable comment, especially if the developer comes back with the solution you failed to think of.

Oddities

Strangely, it's much easier to criticise good code than bad. Good code is easy to read and understand which makes it much easier to think of improvements. With bad code you struggle through the logic, it's difficult to understand what it does and more importantly what it's meant to do. Finding the pivot points in which you can start to improve the code is hard work and there's so much more you have to say. This is also the time when you have to be careful how your comments come across. "I would expect a function called isValid to return a boolean, not mutate the value" is making a reasonable point, but what the developer will probably read is "You are a terrible person, that is why I hate you and your ugly code" which may not have the desired effect. In cases of really bad code, I tend to avoid the review and just help the developer re-work the code in person.

Conclusion

Spending a lot of time reading other people's code may initially seem like a cruel and unusual punishment and depending on the code it really can be. Code reviews can be super time consuming if they are on a section of the code base that you aren't familiar with. However, by the end of the review, you know the code base better and you will have levelled up your "reading other people's code" skill.

Code reviews have helped us keep the quality of the code base higher than previously. It also saves us time in bug fixing by enforcing better unit tests. We also have a level of consistency running through the projects now in terms of coding standards and architecture which is really nice. It certainly makes future development faster when developers come to work on a new project and find it fundamentally works in the same way as all of the others. I can't honestly say code reviews are a fun part of my day, but the results are too useful to ignore.

Tuesday, 28 January 2014

Banning things is awesome

I wrote recently that I don't think banning things is a cost effective way for governments to solve problems. The first reason for this is simple: supply and demand; the second reason is that it's rare that something bannable is actually the root cause of the problem; finally, banning things is a restriction of personal freedoms and those should never be given up lightly.


Supply and demand

If there is a demand for a thing, banning it has, historically, created a black market supply. Banning drugs is an awesome example of this, in 2010 it was reported that every bank note in the UK was contaminated with cocaine within weeks of issue. The cost of drug prohibition enforcement in the UK is estimated at £16 Billion. I'm not suggesting that the government wouldn't squander that cash on something equally useless if drugs were legalised, just that banning things doesn't seem to work. Here's a list of other things that have been banned at one time or another:

  • Christianity
  • Drugs
  • Alcohol
  • Guns
  • Homosexuality
  • Books
  • Furbies
  • Video games (Greece)

Now here's a list of things which (to my knowledge) have been banned effectively:

  • Time travel (China)

Solving the wrong problem

It's easy to see why some people don't like guns, drugs or Christianity, but if banning them is expensive and seemingly ineffective, why is it such a popular choice? My guess is that it's a lot easier to ban something than it is to solve the actual issue. For example, where would you rather live, in a place where everyone had guns but no-one got shot, or a place where no-one had guns, but your neighbour dreamt every night of shooting you using your own ass as a silencer? It's quite possible that solving the issue of people wanting to kill each other might give better results than simply taking away one of the more effective ways of doing it. However, that's a difficult problem to solve, it's hard enough catching murderers after they've killed someone, let along before...

It's often easier to be seen to be doing something than it is to actually do something. Like when a friend wants to tell you about their problems. You could sit, listen, perhaps make some insightful comments, help them get their heads into a better place. But that's an evening you are never getting back, plus it sets a dangerous precedent. So, you take them out and get them drunk instead, it's way more fun for you and much less work. I think it's the same with drugs, it's much easier to be seen to create jobs for drug enforcement officers and pledge someone else's money to a cause than to actually try to reduce the demand for narcotics. Especially in the instances where drugs are not taken recreationally, but as an escape from appalling social conditions.

Liberty

In addition to not working, banning things is a reduction in personal freedom. There would have to be a lot of evidence of the efficiency of such a move to warrant it in my eyes. This is true regardless of whether I want to make use of that particular freedom or not. I didn't own a gun when they were legal in the U.K. nor do I base my sexuality on the legality of homosexuality. The point is the loss of personal freedoms to a government that is doing the political equivalent of sweeping mental health issues under the rug of gun control and shoving the mess of social problems into the closet of drug prohibition.

Don't worry, I'm not going to go into the tired old chat about banning one thing being a slippery slope to a totalitarian state. It just irritates me because it's lazy and not the fun type of lazy like someone getting their food delivered from a restaurant so close I can shout my order to them. It's the evil sort of lazy that encourages stupidity by pandering to it. It's easier to ban someone from t.v. for the words they use than explain that it's the meaning behind words that matters. It's easier to ban websites than to monitor your child's internet activity. It's easier to ban jam on aeroplanes than to make them safer. It's easier to ban certain breeds of dogs than to ensure the owners aren't idiots. It's easier, it's ineffective and it makes the world just a little duller.


Sunday, 26 January 2014

Are some things too complex for sound bites?

Like most people I love a good sound bite or a witty one liner. Distilling a complex issue down to a few words is a very complex task and takes a keen mind, for me, H.L. Mencken was a master of this:

I believe in only one thing: liberty; but I do not believe in liberty enough to want to force it upon anyone.

It's short, memorable and very much to the point. For these reasons, the idea is super portable, posting something like this on twitter could see your idea entering a vast number of other people's heads and finding a resting place. There is, of course, a draw back to this, ably condensed by Mr. Mencken:

For every complex problem there is an answer that is clear, simple, and wrong.


While Mencken's pithy quotes are short, memorable and well thought through, it is only the first two factors that make them repeatable and "sticky". Therein lies the rub...


If god meant for people to talk into cellphones, he would've put our mouths on the side of our heads...

Just because something is pithy doesn't mean it has value above and beyond amusement. Sometimes, that's the point of a quote, we're dealing with those times when it's not. Fortunately, some are easy to deal with, for example if they are simply factually incorrect:

The chance that higher life forms might have emerged in this way (natural selection) is comparable with the chance that a tornado sweeping through a junk-yard might assemble a Boeing 747 from the materials therein.

No, it's not.


Others, however, require a bit more thought. I saw this little nugget of wisdom today, it's not an Mencken quote and I doubt it would convince anyone to swap sides in an argument, but it seems to have the effect of cementing together people of the same view. It's tweet provoked a very focused discussion on gun control.


We keep having shootings because there aren’t enough guns yet.


It's short and memorable - so it gets a tick for being portable. But what idea does it bring to the point? The idea that guns cause shootings? That people only want to harm other people because they have access to guns? If you put a normal, healthy individual in a room full of guns will they transform into a murderer? Or are there more complex reasons why shootings occur?


Get to the point


I chose H.L. Mencken's quotes because they are great examples of the power of short, memorable phrases; they sum up a large idea correctly without room for error in interpretation. It's pretty obvious that saying things that are just blatantly wrong is to be avoided in short, memorable phrases as in long, unmemorable ones. The reason for this post is the final example, where the phrase is ambiguous. It's hardly worth a blog post to explain that people should say what they mean and try not to be ambiguous or wrong, but this is where short, memorable phrases tend to be different. They entice us with a witty, highly repeatable phrase which supports our view on a subject. It's flattering to think that others agree with us and the tendency is to repeat these things without thinking too much about them. However, if they are not exact, if they don't focus on saying only what they mean, other ideas can slip in unnoticed.

Most people would agree that shootings are a bad thing and the fact that there are so many shootings is a form of evidence that the wrong people have the guns. The passenger idea here is that banning guns would solve the problem. I could be persuaded to agree with the comment "I don't feel comfortable with the general public having guns because they need to be told to wash their hands after using a public toilet". But I see no evidence to suggest that banning things is a reasonable way to solve the problem.

The reason Mencken wrote so many quality little quotes is that he took the time to say exactly what he meant, not sacrificing precision for brevity. When his topic was more complex, he was less brief. However, in short phrases lacking that exactness there is the danger of introducing passenger ideas, either intentionally or by accident.


The fact that I have no remedy for all the sorrows of the world is no reason for my accepting yours. It simply supports the strong probability that yours is a fake.


Sunday, 12 January 2014

Is it possible you might be responsible for your own misfortunes?

I'll start with a tale from real life that I feel illustrates my point. It does this so comically perfectly that it just has to be true (although these are not perhaps entirely accurate quotes).

I brutally and obviously cheated on my wife and now she's divorcing me. I love her completely and the fact that she won't give me another chance has ruined my life. Why is she doing this to me? I refuse to accept that this is just and right and will now devote my life to misery.

Hang on, wait... you're the wronged party in this tale? I don't want to come across as unsupportive, but you realise that you are refusing to accept the consequences of your actions here? That's not normally something that makes you the hero of the story or even a particularly likeable character.

On another memorable occasion a work colleague decided to regale me with a list of poor life choices which had lead him to become unhappy. I asked him if he thought that perhaps a large part of his woes might be due to poor decision making? For example, if he'd have chosen, at random, another member of staff to unburden himself to, he would, most likely, have received the sympathy he obviously required. I was genuinely interested in seeing what thought process had started with "I'm sad and need solace" and had ended with "Ah! There's Julie, she's really kind and compassionate, maybe I could tell her my problems... No, wait, here's Ant, I remember, one time, he told me that I would be the first person in the office he would sacrifice to save himself in the event of a zombie apocalypse, I'll tell him instead".

On an almost daily basis I seem to see incidents in which people are utterly unaware of the role of their actions in their own fate.

"I can't believe I got ANOTHER parking ticket - I got one yesterday as well, this is bullshit!"

"Were you parked in the same place as you were yesterday?"

"Yea."

"In the disabled bay next to the main doors?"

"Yea, I had a box to bring in..."

Imagine my joy to find that this isn't a new thing. That many plots of the most famous novels follow this pattern of obliviousness.

Frankenstein

So, Frankenstein is smart enough to create new life, but then abandons it into the world because it's ugly. Then makes a bargain with the monster under threat of having those he loves murdered. A bargain he subsequently breaks and is stupid enough to be woefully unprepared for what follows.

The monster itself turns out to be utterly wretched. "Oh woe is me, I am lonely! I am stronger and faster than normal people, I am almost impervious to the weather and require little sustenance, but those are small comfort to someone who is lonely and it's someone else's job to fix that for me".

Wuthering Heights

The entire plot here is driven by people failing to act in the face of brutal provocation. If Ellen Dean had been shot in the face at the start of the book and someone competent brought in to replace her, this would probably have been a very different novel. Of course, it's unfair to lay all of the blame on Nelly. If Edgar Linton hadn't taken so calmly to a man breaking into his house regularly to spend time with his wife things might have turned out differently too.

Heathcliff, of course, is responsible for his own misdeeds, but it's the inaction / acquiescence of others that allows them to be so devastating. If Edgar had taken action by confronting his wife's obvious love of another man, or by accepting that he had an enemy bent on his destruction and preparing for it he wouldn't have had to live his life in fear and seen his ward and eventually his daughter taken from him. Telling your child she's not allowed out of the garden isn't keeping her safe in the same way that having a fence between the tiger enclosure and the nursery isn't.

Solution

My point here is that's there's way too much boo hooing in the world and not enough taking responsibility. It's that lack of responsibility that leads to inaction. It's entirely possible to solve all of the problems discussed here in two monosyllabic words: "man up". We all have a responsibility to lead by example, great literature doubly so, so here are some amendments to our plot lines.

  • "So you see Dr. Frankenstein, you must make me a bride, you are completely in my power!"
  • "Not at all simple creature, did you really think I, the genius who created you from nothing, would chase you all this way unarmed? I have poisoned your tea and now I intend to shoot you like the dog you are. Then I shall return to my beloved Elizabeth and marry her in safety."

  • "But I've met 10 people in my life and none of them liked me, I am so lonely. It's not my fault I murdered people, I'm lonely."
  • "So super strength is not enough of an advantage for you, you need someone to solve your loneliness problem for you don't you? Well, here's how to solve it - GROW A PAIR! Now stop whining and sort your own problems out instead of placing them at my doorstep - my brother's dead for god's sake you thoughtless dick!"

  • "Ah, Heathcliff, I see you are in my wife's bedroom. I can't say I'm pleased about this, but I'll give you the chance to leave and never come back."
  • "You shall never force me to leave her be. There's no way you can stop me!"
  • "Wilson, shoot this man in the face and have his body dragged to the moors, then stop by the constabulary and explain how this mad man broken into my home and tried to assault me with the poker."
  • "Now, Catherine, perhaps you and I should discuss the future of our relationship."
  • "Oh and Ellen, you deceived me and brought this man into my wife's bedroom, you're fired."

Sorted.


Sunday, 18 August 2013

Reading, listening and comics

I have recently created an Audible account which I absolutely love. It turns the drive to and from work into a pleasant experience and I often use it when working out. It also means that I have rattled through more than the usual amount of books this year. Many of these books have come from reading round the League of Extraordinary Gentlemen comic book series. Yea, it's odd to think that a set of comics are interesting enough to get me to read the novels from which they draw their characters. So far I have read or am reading:

  • All the Sherlock Holmes novels - loved them.
  • Orlando (Virginia Woolf) - weird but interesting.
  • Raffles: Amateur Cracksman (E. W. Hornung) - good fun.
  • The Island of Dr. Moreau (H. G. Wells) - dark and thought provoking.
  • 20,000 Leagues Under the Sea (Jules Verne) - terribly dated.
  • Moonchild (Aleister Crowley) - good so far.
  • Gulliver's Travels (Jonathon Swift) - awesome.

I realise I am missing some of the main character's novels, but I'd already read Dracula, some of the Alan Quartermain novels, Dr Jeckyl and Mr Hyde, the Time Traveller, War of the Worlds and enough of H.P. Lovecraft to follow a lot of the subtle jokes and shifts in writing style.

In general reading, my recommendations are as follows:



The Yellow Birds - Kevin Powers

Frighteningly well written it also has a very powerful story. I was gripped from the very first sentence. I may have to re-think my top 10 :)



The Martian - Andy Weir

A story of the survival of an astronaut stranded on Mars. A well told story filled with humour and wit - a super easy read.



The Name of the Wind - Patrick Rothfuss

The first of a set of fantasy books following the life of a very gifted boy and his search for magic. It is superbly well told, the world and the characters are incredibly rich.



Solaris - Stanislaw Lem

A sci fi classic and rightly so - a very thought provoking look at how different an alien life form could be compared to the usual human-centric creatures we see in other novels.


Comics and graphic novels

I'd never really thought of comics as something I would want to read - I don't think the idea of super heroes really appeals to me. Then I discovered that a lot of comic book writers felt the same and I decided to give V for Vendetta a read. It's probably one of the best things I've read in a long time, my quotes file has grown fat on just this one graphic novel. I also discovered Alan Moore, which has been a real source of joy.

The art work in V is pretty dated, but the story is so amazing that I went to my local store and asked for a recommendation for more of Alan Moore's work. I was pointed to The League of Extraordinary Gentlemen as his master work. It's truly amazing, the story is a weaving of many works of literature into an alternate history of our world. There are so many wonderful places where the plots of two or more novels join seamlessly that you just stare at the page in wonder. The artwork by Kevin O'Neil is everything that V was missing. I genuinely haven't enjoyed reading something this much in a long long time. It also turns out that Alan Moore is a fan of H.P. Lovecraft and there are a few novels using that mythos - Neonomicon (the art work by Jacen Burrows is masterful) and Nemo Heart of Ice, which is an off shoot of the League with Kevin O'Neil, also outstanding.

So, if you have never read a graphic novel, I would heartily recommend giving them a try. Also worthy of mention are Neil Gaiman's The Sandman series and, if you want a gritty anti-hero I highly recommend The Punisher.

What is wrong with us?

Language and literature

As a species we've pretty much mastered language and we are way ahead of our nearest rivals. For example, frogs know about 3 words, dolphins on the other hand are known to associate themselves with names and have a wide vocabulary. Impressive huh? Yea sure, until we roll out some of our poetry - Ozymandias written nearly 200 years ago; or our literature, take 800 pages of War and Peace to the face dolphins, written nearly 150 years ago.

So, we've totally nailed language, we excel in literature and poetry. We are so far ahead of our nearest rivals we could wait 500 years and still not have a dolphin best seller, or could we? We have all of this amazing literature and poetry, things people can use to better their mind, contemplate alternate worlds, discover new thoughts. How are we using it? Well, in the top 20 best selling books on Amazon, the top 3 are diet / cookery books, with another 4 dotted about. There are 2 books with instructions on how to pass your driving test and Dan Brown has a place in there. Jesus people! You have all the works of literature to choose from and Dan Brown can sell books!

So, we have all this amazing literature, but we aren't using it, what about science?

Technology

I'm not even going to compare our advances in technology to those of animals, it would just be embarrassing. We have television! What do we do with it? Well... there's erm EastEnders and Coronations Street, obviously. There was a show on last night called "I love my country" and another one where a puppet asks celebrities questions. I'm pretty sure John Logie Baird would be relieved to know his invention was being used for a higher purpose.

There's also the internet - that's a marvel of technology! Yup, it's currently being used for spam, porn and keeping people up to date on our bowl movements.

There's always proper science, that's the home of true intellectual endeavour. Well, physics is stuck with string theory, which is the first major theory to have the benefit of being untestable. Genetics is a total mess with back pedalling on a grand scale. The decline effect is rampant. However, the scientific community is more dogmatic and narrow minded than ever. Much in the way they were when that fool Copernicus started mouthing off about his heliocentric model of the universe.

We've reached our zenith

As a wise man once said, "any species that has words in it's language for sexual asphyxiation isn't built to last". I, for one, say we accept and enjoy the slide down to our nadir and graciously welcome our new dolphin overlords when they make the transition to land.

Sunday, 21 April 2013

You know what's fun?

Playing games that are fun to play... I am currently playing the exceptionally highly reviewed Bioshock Infinite. It has lots of good features:

  • Probably the best companion ever - she gives you cash, health and ammo
  • The world is beautifully realised and engrossing
  • The story is gripping and you care about the characters
  • Travelling by rails on a hand held hook is awesome

Surely all these excellent points warrant the high ratings? Well, they would if this was a film, but it's not, it's a game, so it needs one more feature - gameplay.

To me, this is where Bioshock Infinite really lets itself down - it's just not that much fun to play. The shooter itself is fundamentally broken, here's what I think.

Battles

So, we've got a big dude with a massive gun - you do extra damage when you shoot him in the back. Ok, so, I have a gun and an ability to freeze this guy in place - strategy sorted.
This will work great if I have plenty of space, and I do. However, I am shot by lots of other NPC's, I don't die, but I am at low health now - maybe my strategy is wrong? Ah well,
there's some health over there, so all's well that ends well. I'll try a different strategy next time.

So next time, I take cover, grab a rocket launcher and shoot from a distance. I kill the machine gun dude, but am flanked and loose a lot of health. Hmm, not an ideal strategy either,
still, I don't die and there's a fair amount of health lying around, so onwards and upwards.

Next up is a guy who takes extra damage to the chest and does lots of damage at close range. I keep him at a distance using my vigors and shoot him in the chest. I take a lot of damage,
but I don't die and there's lots of health around... By this time, I am starting to see a pattern forming. So next time, I just stand my ground and shoot - I take a lot of damage,
but I don't die and there's lots of health around. Man, this kinda sucks, I wonder if the game is more advanced than I'm giving it credit for? So I take to the sky rails and use them to keep mobile.
Same deal... sadness descends.

Weapons

The weapons are largely functional, you shoot up close with the shotgun for maximum damage, the sniper rifle for long range and in between you have the machine gun. There's the RPG for splash damage, but not a single weapon that's fun to use. Nothing that makes you laugh and and smile when you first use it... Remember the gravity gun from Half Life 2, yeah you do! Or the first time in Dishonoured when you blinked onto a walker and cut the driver's throat? Getting the chainsaw in Doom2? The line-gun in Deadspace? Things that were fun to use and play with? I have never practised combat in a single player game the way I did in Dishonoured, but it was just so much fun, there were so many things to try out and play.

Also, you can only carry 2 weapons at once in Bioshock Infinite, which is a nice nod to realism in a game where you can shoot electricity from your hands. This would be fine, if there seemed to be a game play reason associated with it. So far, I've not come across a scenario where the RPG and a machine gun weren't sufficient.

Linearity

I've just finished playing Tomb Raider - which was awesome fun and very linear. My problem with Bioshock is that it seems to suggest an open world to explore, so it jars when I come to a door I can't open or a ledge I can't jump off. It's also the linearity of the combat. I've read reviews raving about how you can set an opponent on fire and then push them at others, or you can trap them in place and shoot them. My issue is that you have to do one of those combinations and it doesn't seem to matter which. Neither option is enough fun to overcome the lack of inventiveness in the options.

Other games

Now Dishonoured allowed you the freedom to kill in many different ways, it even offered you the option of not killing. You could play with the game mechanics and have loads of fun without following the linear plot. Take a look at this and tell me it doesn't look fun Dishonoured. Now I know they are different games, but they both need to be fun to be worthy of such high reviews.

Monday, 1 April 2013

Grinding my gears

What's bothering me

I keep seeing lots of random people in the entertainment industry speaking on behalf of science. They mock anything other than the standard scientific view as proposed by celebrity scientists without any real understanding of what they are talking about. I'm not just talking about Heather Mills talking about the dangers of eating meat, or Roger Moore claiming foie gras causes Alzheimer's disease.

Take this quote from Ricky Gervais:

"Science seeks the truth. And it does not discriminate. For better or worse it finds things out. Science is humble. It knows what it knows and it knows what it doesn't know. It bases its conclusions and beliefs on hard evidence -­- evidence that is constantly updated and upgraded. It doesn't get offended when new facts come along. It embraces the body of knowledge. It doesn't hold on to medieval practices because they are tradition."


All very true and correct as a principle, but it is hopelessly naive as a statement of fact. The scientific method is, of course, the best way we have of acquiring new knowledge and verifying existing theories. However, it is implemented by people and therein lies the rub. If you have made your career based on proposition X, how likely are you to be impartial when examining opposing proposition Y? Really? Is there any evidence to back my claim up?


"String theory now has such a dominant position in the academy that it is practically career suicide for young theoretical physicists not to join the field."

Lee Smolin - The Trouble With Physics.


"A study by the University of Edinburgh examined more than 4,600 scientific research papers published between 1990 and 2007 and found a steady decline in studies in which the findings contradicted scientific hypotheses.
Papers reporting null or negative findings are in principle as useful as positive ones, but they attract fewer readers and citations, so scientific journals tend to reject them.."

http://phys.org/news/2011-09-pressure-positive-results-science-threat.html


There are way too many factors that can distort the accuracy of information coming from the "body of science" to discuss here. However, imagine having to go to your boss and tell him that the work you have done in the last 2 weeks has lead nowhere. 2 weeks of work down the drain - would that be a happy day for you? Now imagine that you are heading up the Human Genome Project.
You have promised a golden era of bio-tech and unparalleled return on investment for your billions of pounds funding... Are you going to go with "For better or for worse, we've found out that it's more complex than we initially thought. Designer babies and the cure for cancer are going to have to wait a bit longer. So in conclusion, there are waaaaay fewer genes than we thought. Remember epi-genetics? Well that's coming back in a big way, so lets all embrace that new body of knowledge"?


"Britain's biggest drug company, GlaxoSmithKline, is facing fraud charges in the United States for allegedly concealing information that its leading antidepressant caused suicidal behaviour among children and teenagers during clinical trials."

http://www.guardian.co.uk/business/2004/jun/03/mentalhealth.medicineandhealth


Why does it bother me?

Because the scientific method is the way forward, however, it is impossible to be sure that you have analysed all of the data correctly when you simply don't have all the data.
Ben Goldacre has made a career (and a valid contribution to science) of exposing this.
Yet, I continue to see people mock the views of others because of their dogmatic belief that anything the scientific community says must be true.


We need to move back to the old scientific standard of having an open and enquiring mind. A balanced view of all sides of the argument is the route to making up your own mind. Not choosing a science super hero on the basis of their personality and mindlessly vomiting their words into the ears of anyone who tickles your unscientific gag reflex.

If you read Richard Dawkins The God Delusion, read Pierre Teilhard de Chardin's The Phenomenon of Man. If you read about the mind, read Hofstader, Penrose AND Sheldrake. Learning is fun! It's much more fun if you figure out the answer for yourself.


I have always liked this quote from Pierre-Simon Laplace, when asked by Napoleon where in his scientific thinking was the role for a creator, he replied "I had no need of that hypothesis".
It represents to me a beautiful neutrality, without a hint of the dogma I oppose in the current scientific zeitgeist.


Finally

And if you are going to mock religion, be careful! It's like playing pool against your kid - if you win, it's the slow hand clap of 'well played, you have better eye hand co-ordination than someone who still gets dressed by his mum'; if you lose, the mockery is, rightly so, endless.

I watched a comedian I follow on twitter make a comment about the death of Christ not being a big deal for God because he could always have more kids... Really? The basic premiss of this attack was 'you are stupid because your beliefs have no logical basis, I am superior to you because I am a logical man of science'. Who believes that people who lose a twin shouldn't be upset because they have a spare? On behalf of those of us who were atheists before Richard Dawkins and Sam Harris told you it was cool - please stop talking.

Saturday, 8 December 2012

The fine line between the -ism's

An interesting chat at work: A colleague was reading a news paper article about racism in the job market, stating that a young job seeker had been advised to change her name from Jordan to Elizabeth. My colleague stated that he didn't think this was racism, but class-ism, remarking that Elizabeth is classier than Jordan, not more British.

I liked his point, it made me think that if someone told me I was to meet a lady called Jordan to interview I would have no pre-conception of her race. My pre-conception of Elizabeth however, was that she would be better dressed. My colleague then took the point a step further, stating he wouldn't date a girl with the same first name as a wine.

That's when it hit me

This wasn't class-ism, or racism, IT WAS SEXISM!

Whatever happened to the days of Audrey Hepburn? A women to be treasured and worshipped, change her name to Chardonay Hepburn and she becomes a glitter soaked vajazzled sexbeast! Michelle Pfeiffer => Lambrini Pfeiffer.

The true horror of this insidious state of affairs only becomes apparent when you show the difference between the sexes. Lets flip it around and see what happens to our men under this new regime:

  • Johhny Shiraz
  • Mike Bordeaux
  • Ronny Budweiser
  • Little Bobby Shandy
  • James Hofmeister

All of a sudden these guys are comic book super heroes! Fighting for Good, Justice and Honour, but they have been subverted by the machine - unwitting soldiers in the war against the fairer sex!

Makes you think, doesn't it?

Monday, 9 April 2012

Thoughts on TED

I've been watching quite a lot of TED talks recently. Obviously the variety and depth of the talks is one of the things that make TED so amazing. I watched a couple recently, one was of a woman that wraps people in straws and takes pictures, the other was about a guy who designs book covers. It got me to thinking that if you could talk about your job all I needed to do was write some cool JavaScript and I'd be on the TED stage rockin' faces. Whilst living out this little fantasy in the theatre of my mind, I suddenly realised the horror. I then wondered when other people came to the same realisation?

Scenario 1: backstage

So, I am backstage and nervous along with the other speakers. The topic of conversation inevitably turns to subject of our talks. I give a pithy explanation of some software development project ending with my motivational line "One morning I got into the office at 8:30 to find there was no coffee... but you know, even through the dark times, we never gave up..." I guess that's why I am in the inspiring section.

I am imagining a reply to come from a plain looking middle aged lady, who you would correctly describe as "really nice". She would smile and say she was in the inspirational group too, which was great as we could be friends. I would smile and graciously ask her about her talk.

"Oh, I'm here to talk about my dog really. We were on holiday in India when my 6 month old child fell through a hole in the ground into a snake pit. The hole was so small that we couldn't reach her to get her out but we could see snakes all round her. I don't mind telling you I was really panicking! Then Poppy, my little King Charles Spaniel jumped down the hole and fought off the snakes until we could get help. She was bitten 15 times and had enough venom in her to kill a rhino, but she protected my little baby until we could dig her out."

As if this story isn't enough to knock your confidence, in the silence left by the end of her tale I hear the guy next to you finishing of his practice speech with:

"... and that's how I managed to secure a clean water supply for a village of people living in one of the worlds harshest environments."

Scenario 2: after the talk

Scenario 1 is pretty harsh, but that lead me to scenario 2. You don't find out about other people's talks till after you have delivered yours.

After giving my talk, I wander over to my friends to find out how it went from the perspective of a member of the audience. "So friends and family members, how did it go? Awww Mum, you are crying - did I make you proud?"

"What? Oh, actually, I'm still thinking of that puppy. Yea, you delivered your story really well, it's just that you were scheduled between that kitten that can sniff out cancer and the 16 year old kid who built a nuclear reactor in his garden shed. But your script thingy was good too..."

The journey home

But the punishment doesn't end there - imagine the journey home. Everyone is super excited and inspired by the talks they heard that day and are swapping their favourite bits.

"What about the woman who swam from Cuba to the States and kept getting stung by Portuguese men of war but insisted on getting her adrenaline shots in the water! She was mental!"

"Yea, but that guy who built schools for children out of trees he had to sail across the lake of terror - he was just some sort of saint."

Then to compound the injury, someone notices the sad on my and tries to help. "Well, I think my favourite bit was when Ant said he didn't know how to do that thing. Then he thought how to do it when he was in the bath and he got out of the bath and made the floor wet - that was pretty funny."

That's why it's actually a good thing I will never get to do a TED talk.