On Freedom

There are always two types of freedom

Freedom To – The active freedom. These are the freedoms that you exercise when you are doing something.
Freedom From – The passive freedom. These are the freedoms that you have when you aren’t doing anything. They are your everyday freedoms that you enjoy without even thinking about it.

They are in eternal conflict. They are mutually exclusive.

My right not to get shot conflicts with your right to a gun.
A minority’s right to live without bigotry conflicts with another’s right to bigotry.
Freedom to enslave is in conflict with freedom from slavery.
As you mention the freedom to pollute is in conflict with freedom from pollution.

Until we can all understand that freedom from is generally more important than freedom to we are fucked.


Dan says “Shit” is now published!

I finally got my book out and for sale. It is a short silly book looking at the everyday hassles that we all put up with.


Check it out on Amazon!


I’m thinking about running for congress against Anna Eshoo.

While I respect Anna and I have voted for her many times I think that I need to try and run against her in order to take action for the things that I care about. I’ve been nominated on the Justice Democrats platform and I have been starting to put together a platform in case I do run.



Repeal Drug War and replace with health care first initiatives for addicts. (ref: Portugal/Denmark).


$15 minimum wage with annual/quarterly increase tied to the rate of inflation.


Minimum vacation and sick time for all workers prorated on 40hr/wk (12/yr each).


Requirement for all salaries/pay rates in a company to be available to all employees.


Make forming a union easier.


Mandate investigations into police violence/use of deadly force by outside agency using jury of citizens.


Reform Intellectual Property/Patent laws in favor of the public domain.


Require all government funded research to be published as open science articles and be released to the public domain.


Mandate equal pay for equal work.


Medicare for all. (evidence based)


Strengthen Social Security (scrap all social welfare programs and turn Social Security into a Universal Basic Income)


Moratorium on construction of coal/carbon based power plants.


Invest in green energy production/research.


Increase law enforcement activity to combat domestic white terrorism.


Strengthen the voting rights act.


Strengthen open and free elections including primaries and caucuses.


Ban lobbyists from governmental positions for at least 5 years.


Ban politicians from lobbyist positions for 10 years.


Ban speaking fees for politicians in office and for 5 years afterwards.


Ban corporate donations to politicians and political parties.


Publicly funded elections.


Voting reform. (ranked voting)


Mandatory voting.


Automatic mail-in voter registration.


Centralized government web pages for all candidates.


Remove party affiliation from voting documents.


Access to debates for all candidates.


Increase funding for education (teachers should earn a good living).


Increase funding for the arts.


Increase funding for the humanities.


Reduce military funding.


Empower government science advisors.


Promote evidenced based laws and policies.


Mandatory offerings for parental leave (new child/sick child)


Invest in infrastructure.


Tuition free bachelor degrees at public universities.


Path to citizenship for undocumented immigrants.


Restructure trade agreements to benefit workers.


Drug testing for politicians.


Enact insider trading rules for politicians.


Empower ethics committees.


Strengthen equality laws for all minorities.


Internet as a utility.


Jail time for corporate executives.


Empower municipal fiber internet.


Ban warrantless surveillance and blanket information gathering.


Tie political salaries to the Universal Basic Income.


Politicians get medicare.


Increase corporate taxes and remove many corporate tax breaks.


Increase taxes on top earners and remove many tax breaks.


Ban politicians from voting on their own wage increases.


End US torture.


Employment protections, no firing anyone for no reason/any reason.


Mandatory severance packages for downsizing.


Increase enforcement against unpaid internships.


Ban asset forfeiture without conviction.


Free adult learning classes towards high school diploma or GED with free GED testing. (with online classes)


Reverse climate change  

So what do you think?

On The Left vs The Republicans and Democrats

As a far left anti-authoritarian I have been getting a ton of flak from Democrats saying that I have to align with the major political party that most closely aligns to my views. Unfortunately, there is no party that does that. On the Political Compass scale ( https://www.politicalcompass.org/ ) I rank as -10/-10 putting me firmly in the corner of a collectivist anti-authoritarian. But you may ask, why not side with the Democrats, well….


Well friends, here is the map of the US Presidential Candidates of 2016




If we look at the two main candidates we have Clinton and Trump.

Clinton ranks at: 7.5/5 being further to the economic right than Trump

Trump ranks at: 6.5/9 being more authoritarian than Clinton (and right next to Hitler btw)


So doing some simple maths using good old Pythagorus:

My distance to Clinton is the square root of (|-10| + |7.5|)^2 + (|-10| + 5)^2 = 23

My distance to Trump is the square root of (|-10| + |6.5) ^2 + (|-10| + 9)^2 = 25.16


Now, obviously I am most closely aligned to Clinton but not that much more closely. There is about an 8% difference between the two from my political position. But what about the two of them?


The distance between Trump and Clinton is the square root of (7.5 – 6.5)^2 + (9 – 5)^2 = 4.12


So it becomes obvious that Clinton and Trump are closer allies than I am to either one of them. Fundamentally, there is very little to differentiate either person from my political positions.



On Tradition

To defy the laws of tradition is a crusade only of the brave – Primus


I dislike tradition. I think that they fundamentally need to be challenged and replaced with something better if it is available. Inevitably someone pops along and says well what about Christmas and birthday parties. And while there is a bit about that I am going to offer the following counter argument.

  1. A birthday party is about sharing time with the people that you care about. There is nothing prescribed about how you celebrate a birthday. You aren’t required to give/accept gifts. You aren’t required to do it on your birthday. You aren’t required to do it at all. It is a voluntary activity that is so personal that it really can’t be considered a tradition.
  2. Christmas isn’t what it was. It has evolved into a mostly secular capitalist spend fest. The Christmas tree itself is forbidden in the Bible. The original gift giving happens on the Epiphany on Jan 6 (when the wise men arrived). The date was even changed during the shift from the Julian calendar to the Gregorian calendar (the original date was on Solstice to coincide with Pagan holidays) to the actual tradition of Christmas, being the Christ Mass is already dead.
  3. It is traditional to pay women $0.77 for every $1 that a man earns.
  4. It is traditional to subvert the civil liberties of the non-rich white upper class.
  5. It is traditional for women to be subservient to men.


Fundamentally to me, these all derive from the tyranny of dead people. Someone, sometime in the past decided that this is the way that it should be. It may or may not have been the best choice at the time, but as time moves on the rules for society necessarily must change to deal with the problems that currently face living people. The dead do not need to worry about the problems of the living. The living should not care about the opinion of the dead.

This isn’t to say that all ideas from the past are bad, obviously, but to blindly follow the traditions of old is to rob yourself from finding a better way forward.

Would you prefer to spend Dec 25 at Mass or doing your own thing?

Would you prefer that the institutional inequalities be perpetuated or challenged?

You may find that some traditional activities agree with your life, and other not. But be active in choosing what is and what isn’t for you. Don’t let others make that choice for you.

Dan says “Shit”: a storybook for grown-ups.

2016-08-11 10.58.292016-08-11 10.58.432016-08-11 10.58.582016-08-11 10.59.112016-08-11 10.59.242016-08-11 10.59.372016-08-11 10.59.502016-08-11 11.00.032016-08-11 11.00.152016-08-11 11.00.292016-08-11 11.00.43

The wonderful and the woes of the Professor Adjunct

First, let me say that I love teaching. I love talking to my students about my specialist topics and getting into discussions about the future of technology and getting them set for a career in academia. It is one of the best feelings in the world.

In some small way, I help to contribute to the future production of all my students and that gives my life a real impact on the world. I have helped people learn to program that have then gone on to work on new robots for CERN (to upgrade the Large Hadron Collider), I have helped researchers from a variety of fields such as library science, music, history, civil planning, and more. I even had a member of the Royal Society in one of my classes that had an entire Journal issue dedicated to him.

Unfortunately, I can’t survive on a part-time teacher’s salary. Since I withdrew from my research degree I am no longer eligible for a tenure track position (a fact that has been lamented by the Chair of my new dept). Fortunately for me, I have strong technical skills that are highly adaptable to many problem domains so I have a well paid day job that allows me the freedom to spend my spare time as a Professor Adjunct.

I am one of the few, though to be fair this is fairly common in my department.

So that is the great part, I get to teach as a hobby. Now for the problems.

I don’t know semester to semester what my schedule will be like, I am at the whims of the class scheduling staff and I am in competition with the other Professors and as the junior member, I am last in line. Normally since I have a day job this wouldn’t be too bad, but the benefits that I get as a 2 class teacher are better and much cheaper than the benefits options I have at my job. But I don’t know if I can rely on them.

When I was teaching at the IT dept at Oxford it was fairly well established that to set up a new class it would take 9 hours of prep time to 1 hour of lecture time. In my current job, I am paid for 8 hours work a week per class and 3-4 hours of that is just dedicated to giving the lectures. That leaves 4 hours a week for lecture generation, review, admin work, correspondence with my students, office hours, and marking papers/exams. There is no physical way that I can pack all of that into 4 hours of work. I donate a lot of time and energy to helping my students succeed, but if I was trying to do this as a living I would be in a very bad position trying to get this all sorted out while maintaining anything resembling a life or having time with my kids.

My pay is also less than half of what I earn at my day job.

This is the reality of the Professor Adjunct, I love my job but I am not given enough hours to do it properly.

The transition from failed research student to successful Professor and Industry Computer Scientist.

One of the things that always plagued me at Oxford was my imposter syndrome. I constantly felt like my skills meant nothing and that all my previous accomplishments meant nothing. It was like that quick transition in Men in Black where J lists off all his qualifications and that K had recruited him and K just responds with “none of that matters now”.

As a research student, I always felt I was falling short and the institutional support wasn’t really there. If you do something good you are just given more work, if you mess up you get to hear about it for months. You are not recognized for being an intelligent, highly skilled person and are instead a trainee. Even if you finish your Ph.D/D.Phil you still aren’t accomplished as shown by the fact that you have to spend more years as a Post Doc before you are a trusted researcher. You may be a world expert on your subject but that doesn’t mean much, and you are expected to pull long hours for menial pay in order to move up the chain.

So due to personal circumstances, I withdrew from my research studies. The reward wasn’t worth the effort, and the reward would just lead to further menial positions even as a world expert. I relocated to San Jose, CA (near where I grew up in Palo Alto) and proceeded to get snapped up as an Adjunct at San Jose State University. From submitting my resume, to my meeting with the Chair of the Computer Science Department, to being hired as a Professor Adjunct took less than 5 hours.

Getting my resume sorted out for an industrial job took a little longer but when I had hit the right keywords I had to start beating recruiters off with a stick in order to make my phone stop ringing (a great problem to have, I’m still turning down companies like Google, eBay, and Cisco). I had several multinational corporations vying for my skills and even had NASA contractors contacting me to work on extra-terrestrial biology research or the search for extra-solar planets in our galaxy.

I accepted a job working on file synchronization and concurrency which are hugely interesting problems to work on. My pay rate is over 8x my stipend as a research student. It is 4x the pay rate of a Post Doc in the Uk. Finally, it is about 2.5x the rate of pay for a new Professor in the UK. Not only that but my skills and experience as a professional are highly regarded. The VP of a billion dollar/yr company stops by my desk to make sure I am happy and things are going well. I have an infinitely better work/life balance than I did in academia.

This isn’t to say I didn’t enjoy my time at Oxford, I did. I learned a great many things and I met some wonderful people. But, the difference in appreciation for my talents between academia and the real world is night and day.

Maybe failing my doctorate was the best thing that could have happened.

Best of all, I still get to teach. I’ll do a post about that soon, but I love teaching.

Apache 2.4 + Ruby + Sinatra + Websockets

It has been almost a year since my last blog post and a great many things have happened.

I’ve dropped out of Oxford, become a Professor Adjunct at San Jose State University, and I’ve gotten a job working on VeroFiles at Memeo in Campbell, CA as one of their senior developers.

It has been quite an exciting ride.

However, this post is about getting Sinatra to work with WebSockets.

It is well documented among the Ruby community that Apache is not great at handling WebSockets and many people have moved to NGINX, Thin, or Passenger. However, I had a need to make Ruby work with Apache and I want to spread that information now.

What I had to begin with was an Apache server with a Sinatra REST service behind it. I needed to add WebSockets to the mix. I added the gem sinatrawebsockets to the mix and it worked great running in stand alone with thin. But in the production environment it just wouldn’t work so I had to reconfigure the system to have apache as the user-facing service and I used mod_proxy_wstunnel to set up a Proxy/ReverseProxy to thin which then handles the WebSockets.

In your Apache .conf file you will need to add the following:

LoadModule proxy_module /usr/lib/apache2/modules/mod_proxy.so

LoadModule proxy_module /usr/lib/apache2/modules/mod_proxy_wstunnel.so

ProxyRequests Off
ProxyPreserveHost On

<Proxy *>
# Auth changes in 2.4 - see http://httpd.apache.org/docs/2.4/upgrading.html#run-time
Require all granted

<Location /websockets>
ProxyPass wss://
ProxyPassReverse wss://

Where PORT is the port that thin is running on in the background. Then launch thin as a long running process and it should now work. The example from sinatra-websockets should take you the rest of the way and with very little work you should be able to get any of the other Ruby WebSocket gems working behind Apache.

Thanks to all of the other coders out there on the net that have shared the information I needed to make this work.

An armed society is a dangerous society

First, we must understand why we are a nation and not a British colony any more: The complete text of the Declaration of Independence can be found here: http://www.archives.gov/exhibits/charters/declaration_transcript.html It is an exceptional read and has several points that are valid in our discussion.

Secondly, we move to the constitution itself. Again, there are a number of points that we need to address before we can properly understand the context of my argument. Full text here: http://www.archives.gov/exhibits/charters/constitution_transcript.html

I am going to lean rather heavily on the introductory text of the two documents because in those introductory paragraphs we lay down the purpose and function of the government, to which the rest of the document and amendments must be in support of.

From the Declaration of Independence:

We hold these truths to be self-evident, that all men are created equal, that they are endowed by their Creator with certain unalienable Rights, that among these are Life, Liberty and the pursuit of Happiness.–That to secure these rights, Governments are instituted among Men, deriving their just powers from the consent of the governed, –That whenever any Form of Government becomes destructive of these ends, it is the Right of the People to alter or to abolish it, and to institute new Government, laying its foundation on such principles and organizing its powers in such form, as to them shall seem most likely to effect their Safety and Happiness.

So straight of the bat, the most important statement in the creation of the US government is to protect and enable – unalienable Rights, that among these are Life, Liberty and the pursuit of Happiness -.

It is to enable everyone to have these rights that we have a government to begin with and the sole purpose of the government is to protect these rights. When the government or other organisation infringes on these rights it is for the people and the government to adjust the laws and norms of society to protect these rights – Form of Government becomes destructive of these ends, it is the Right of the People to alter or to abolish it, and to institute new Government, laying its foundation on such principles and organizing its powers in such form, as to them shall seem most likely to effect their Safety and Happiness. –

From this I take that the government itself has an obligation to change if the citizens’ life, liberty, pursuit of happiness, or safety are threatened.

Moving onto the Constitution:

We the People of the United States, in Order to form a more perfect Union, establish Justice, insure domestic Tranquility, provide for the common defence, promote the general Welfare, and secure the Blessings of Liberty to ourselves and our Posterity, do ordain and establish this Constitution for the United States of America.

Again this gives us context for what our government should and should not be doing. Here we will be focusing on justice, domestic tranquillity, common defence, general welfare, and the blessing of liberty.

Finally, we will look at the 2nd amendment:

“A well regulated Militia, being necessary to the security of a free State, the right of the people to keep and bear Arms, shall not be infringed.”

Now that we have collected the necessary text we can start to analyse the different bits. Back in the Declaration there is a very important grievance against the King of Britain that help puts the 2nd into context:

He has kept among us, in times of peace, Standing Armies without the Consent of our legislatures.

It was felt among the colonials that a standing army was the tool of a dictator and that the US wouldn’t maintain a standing force of fighters. Instead they had citizen first responders called the militia. Now when the 2nd speaks of the militia it talks specifically about the security of the free state and a well regulated militia. This is vital to the early security of the states without a standing army to protect the states from exterior threats and to handle civil disturbance. However, the situation has changed, we have 5 branches of a standing army now (Army, Navy, Marines, Air Force, Coast Guard) as well as the new national militia, the National Guard. These organisations have superseded the need for the militia as the standing armies protect the freedom of the state and the national guard and police forces handle the needs of civil disturbance. The requirement for the professional peace keeping forces to have access to arms is not in dispute and I think that is what the 2nd is about, protecting the state. But in contrast me must also look at the role of civilians in peace keeping. The civilian is in general supposed to stay out of peace keeping. If you track criminals the way a police officer would you become a vigilante. If a group does it, you become a mob. The role of the civilian in peacekeeping is to keep themselves out of the way and keep themselves safe. Even security guards are only there to observe and report in dangerous situations and wait for the professional law keepers to show up and tell them what happened.

Given the modern world, I feel the 2nd has no meaning for the general public, the general public is not supposed to be involved in the maintenance of domestic tranquillity in an armed role. Further, when an armed civilian gets involved in preventing a criminal situation through the use of fire power the result is not “Just”. The punishment for robbing a liquor store is not summary execution. Even the punishment for shooting another person is not summary execution, we no longer live under the law of an eye for an eye.

Continued: a civilian does not have the authority to remove the “inalienable rights” of life and liberty from another civilian. Only the government must be allowed to interfere with these rights and it must only happen under the rule of law. A major problem in the US right now is the number of shootings that the police get into, but while I disagree with it, I understand it. Every time a police officer pulls over a civilian in a traffic stop there is a high probability that the civilian is armed and the traffic stop is potentially life threatening to the police officer. An armed populace is a threat to the job of ensuring domestic tranquillity. If I were a cop, I would be worried about getting shot for doing my job and giving someone a traffic ticket, this would escalate the situation from safe to unsafe and I understand why cops pulls guns quickly. Police forces outside the US don’t have to worry about getting shot at random times. Since other countries don’t have an armed and aggressive citizenry to worry about they don’t have to opt to violence in the way that American police do. In the UK the cops don’t even carry guns because it is safe enough for them not to.

This all leads me to the conclusion that a highly armed citizenry isn’t in the best interest of the citizenry’s life, liberty, pursuit of happiness, or safety. Therefore something needs to be changed. However, I accept that some people have legitimate reasons to have access to fire arms. We should not be restricting people that actually have a need from having access to weapons.

In regards to the argument that if we disarm the citizenry that then only the criminals will have access to guns. This is correct in the very short term. The free availability of weapons in the US has lead to the free availability of weapons in the hands of criminals in the US. No weapon leaves the factory intended to be used in a crime. It isn’t like Smith and Wesson has a secret factory pumping out guns to be sold directly to criminals. It is instead our lax gun laws that allow criminals easy access to weapons. In Australia in order to get an AR-15, you need to have black market contacts, for those black market contacts to trust you enough to sell to you, and the AR-15 costs over $34,000. In the US, you can just get your non-criminal buddy to walk into Wal-Mart with $1000 and then “lose” the gun or report it stolen depending on what state you are in. This also leads to the conclusion that if you are paying $34,000 for your gun you aren’t going to risk that gun by using it to mug someone for the $40 they have in their wallet. It is not an economical use of resources.

As time goes on and the price of black and grey market weapons increases do to the scarcity of weapons, criminals will have less access in the long term to these weapons and they will be less likely to use those weapons in petty crimes or in low value crimes. Not to mention that the cops will be able to target gun dealers more effectively to get illegal guns off the streets.

This brings us to Open Carry. Open Carry is a scary situation where you do not know if the person that is carrying the weapon is just a douche bag that wants to show off how small his dick is, or if it is someone that is actually about to commit a crime. There is no way to tell until the moment of danger itself. Then there is also the problem of the racially biased enforcement of Open Carry. If a bunch of white people are open carrying then the cops won’t do anything. If a non-white person is open carrying then the police will respond in force. This flies directly in the face of “all men created equal”.

Finally, there is the idea that the free ownership of weapons is to ensure that the government doesn’t become a dictatorship. This was never the intent of the 2nd and that is pure revisionist history. The Constitution itself protects against the formation of tyranny through the use of checks and balances. Additionally, the world has changed and you will be brining your semi-automatic rifle to a drone fight.

All together as my conclusion: we no longer use militias they have been replaced by professional forces to ensure the protection of the free state and domestic tranquillity. No citizen should be removing life or liberty from another citizen, criminals won’t have free access to weapons once we close down the legal to illegal pipelines, everyone will be safer after we disarm the population. People that have a legitimate reason for having a firearm will still be able to access them.

It works great in the rest of the developed world and there is no reason that it won’t work in the US. It won’t be easy and it won’t be quick. It will be worth it.

%d bloggers like this: