Monday, December 31, 2012

Steady progress developing Umple

I would like to end 2012 by highlighting how the Umple model-oriented programming technology is progressing.

Numerous people have worked on Umple during 2012 including my graduate students Hamoud Aljamaan, Sultan Eid and Miguel Garzon as well as several former graduate students. Twelve UCOSP students fixed bugs and added many small features. UCOSP arranges for fourth-year students at many Canadian universities to work on open-source projects as their capstone course project. They have all been logging their progress.

Over 68 issues were closed in 2012, and many more have been moved into the 'Mostly done' status. Some of the key changes include:

  • Many more error and warning messages (such as this) to help users create correct Umple code (e.g. detecting duplicate attribute names).
  • Greater stability and functionality for UmpleOnline: It works better between browsers and looks much nicer, with syntax highlighting.
  • Arguments to transition events on state machines, and various other state machine improvements, such as automatic transitions upon completion of a do activity.
  • Immutable attributes and associations.
  • Automatically sorted associations.
  • Generated code that indicates the line number in the original Umple files where it came from, allowing editing and compiling of Umple, with error messages in Java pointing back to Umple line numbers.
  • Improved documentation, including an API reference, and a generated grammar document that is nicely coloured.
  • Passing through comments from the Umple source to the generated Java.
  • Command line arguments, such as controlling the language generated, and ordering Umple to compile the generated code.
  • Ability to embed an UmpleOnline diagram, or textual Umple, in a web page.
  • Numerous bug fixes.

Work well underway includes:

  • Adding constraints to Umple. Simple constraints where you specify and attribute, a comparator and a value are working, e.g. [age > 18]. These will prevent setters from violating the constraint.
  • Adding C++ code generation. Most of the pieces are in place, although it is not compete yet.
  • Adding a comprehensive tracing capability (Model-Oriented Tracing Language) to allow injection of trace directives at an abstract level.
  • Adding basic SQL generation.
  • Adding a capability to reverse engineer code into umple (umplification).
  • Generation of state machine diagrams using the -g GvStateDiagram option.
  • The UIGU tool for generating user interfaces from models (this is essentially complete, but has been found to be too inefficient for widespread use, so it needs refactoring or rewriting).

In addition to making progress on the above, work planned for the near future includes:

  • Adding Autosar, multi-threading and real-time concepts to Umple.
  • Adding generation of formal specifications, as well as formal specification of umple semantics.
  • Research into comparing umple to regular code using metrics.
  • Further research into usability of Umple
  • Ability to debug code in Umple without relying on looking at generated code
  • Many more example systems
  • Automatic layout in UmpleOnline, using GraphViz.

Ongoing news about Umple can be found on Facebook and Google Plus. An up to date analysis of Umple can be found on Ohloh.


Tuesday, December 18, 2012

Evidence of climate change: Snow depth and chance of white Christmas decreasing

When a major storm hits, some people say 'climate change'. But should avoid doing so, since individual events by themselves, no matter how record-breaking, cannot be used to determine a long-term trend.

Telling evidence of climate change can only come from looking at long term changes, i.e. comparing certain averages from lengthy periods many years ago to the same data for more recent periods.

Environment Canada has a very interesting page documenting the likelihood of a white Christmas. In it they compare data from the period 1992-2011, to the period 1963-1982 (my childhood to my adulthood). The results are startling.

Snow depth: Out of 39 cities, 33 have seen a decrease in snow depth, and only four (Vancouver, Victoria, Hamilton and Brandon) have seen an increase. 12 cities now see less than half the snow they used to on Christmas day: The following are the percent changes in depth:

Fredericton -72.7%
Halifax -70.0%
Kamloops -63.6%
Saint John -63.6%
Moncton -60.9%
Penticton -60.0%
Charlottetown -58.8%
Sarnia -55.6%
Stephenville -52.2%
Quebec -51.2%
Kelowna -50.0%
Montreal -50.0%

Chance of a white Christmas: 31 of the 49 cities have seen chances of a white Christmas drop. Only three (St. John's, Victoria and Vancouver) have seen an increase. Sarnia holds the record, having a 56% lower chance of a white Christmas; Toronto Airport is not far behind at 46% lower.

This is clear evidence of climate change right across Canada. The regional differences are particularly interesting. Decreases in depth can be noted from Whitehorse to most of the Prairies, throughout Ontario, Quebec, and the Atlantic provinces.

Thursday, November 22, 2012

Career slowdown due to childcare is a human rights issue for academics and other professionals

This morning,the Globe and Mail has an article about a report from the Canadian Council of Academies discussing the difficulties female faculty members have advancing their careers.

In general, the process of academic advancement does not mesh well with raising families, whether you are a female or a male.

In order to achieve tenure and promotion, professors are supposed to continually build a publication track record. Taking a break, or 'slowing down', just doesn't work.

One can't properly take maternity or parental care and expect to advance. Indeed female colleagues of mine routinely work during their maternity leave. One even has had her nanny with her in her office looking after her young babies, just a few weeks after each child is born. Why is such leave often impractical: 1) You have to maintain supervision of graduate students; you can't just abandon PhD's in process; 2) You can't just abandon research programs you have carefully negotiated since you often have deliverables or expectations from research clients. 3) It often takes 12-30 months to get papers published in top conferences and journals; you have to keep that process moving, and attend the conferences when papers are accepted. 4) The process of hiring and getting new PhD students going can take 1-3 years; if you wait until you get back from a maternity or parental leave, you have a long gap again before you have a productive research team (and heaven-forbid that you might have another child on the way).

After any statutory or negotiated leaves in a baby's first year, you have a fixed number of courses to teach, so any slowdown while children are young inevitably is deducted from your time to do research and write publications. Slowing down 33% (e.g. from 60 hours a week to 40 hours a week) due to  family responsibilities, might mean reducing the research time from 30 hours a week to 10, a 75% cut. Hardly anyone realizes this consequence.

Interestingly, the Law Society of Upper Canada (Ontario), which had a progressive policy towards enabling female lawyers to take time of for childcare by helping cover their office expenses during their absence, is poised to drop that policy.

This problem, however, is not exclusively a female problem. It affects men too. It contributes to divorce when male academics (and lawyers or other professionals) are unable to take their share of the childcare and family workload. It leads to family-oriented men getting left behind in the career ladder, or simply deciding not to take opportunities that otherwise they would have done.

I have personally found that I have not been nearly as successful in research since having my three children. The sleepless nights and other family tasks have slowed me down very considerably. I know this is the case for other male colleagues. PhD students can be particularly badly affected. I was lucky to have made it to full professor just at the time my first child was born. I believe I might never have made tenure even if I had had children earlier. It must be so much harder for women who have a greater biological imperative to slow down their career.

Institutions and society must recognize this issue, especially now that women make up the majority of students in most academic disciplines. I have seen too many women professors just leave because of this issue, or decide not to take on higher-level responsibilities. And my graduate students both male and female, that have had children, inevitably have huge drop-offs in research performance.

It must become a violation of human rights to not consider childcare and family in promotion, and to not as an institution or profession have active programs in place to accommodate employees and members while their children are young.

Universities and granting agencies, for example, should explicitly have policies that expect and account for 60%+ drops in research productivity when people have young children. Co-supervision of graduate students should be the norm for essentially all graduate students. And when I talk about young children, I don't just mean babies and toddlers; the productivity effect of caring for family may slowly drop off, but it doesn't really ever drop to zero, and should continue to be accounted for until children are capable of travelling by themselves to activities and looking after themselves at home when required.

Friday, November 16, 2012

Yes the provocation and arms buildup by Hamas is intolerable, but aren't there other ways for Israel to respond?

The average person in the world today sees Israel's bombing and military buildup and finds it hard to see the justification for the amount of force being deployed. This will just fuel the hate against Israel, which is not in Israel's best interest.

Yes, elements in Hamas have been bombing Israel for the last year with relatively ineffective "boring" rockets that nonetheless terrorize Israeli citizens. Yes, I accept that Hamas is becoming more brazen and starting to deploy more effective weapons that need to be stopped. Some level of right-to-defend is justified. Yes, there are a great many people in Gaza with fundamentalist attitudes that demand the destruction of Israel.


If the world is supposed to believe that Israel is a mature democracy, can't Israel try other tactics. Some of the following come to mind:
  • Call for United Nations resolutions every time they are bombed.
  • Instead of bombing with explosives, bomb with millions of 'propaganda' leaflets explaining to the Gazans how evil the Hamas bombing is. Or bomb with devices that have loudspeakers that explain to Gazans what is going on.
  • Unilaterally stop the tit-for-tat for a few days to see what happens. If Hamas rockets continue, give a burst of intense response at a pre-announced time, but then stop again. Accelerate this, but always show more restraint than Hamas.
  • Call on elder statesman from other countries (US, Egypt, Turkey, Jordan) to get together to help figure out how to get Hamas to stop the provocation and rhetoric.
  • If they have to bomb (perhaps because they have intelligence about more sophisticated weapons), announce 10 minutes before where they are going to bomb, so people can escape but relatively little military hardware can.
  • Parachute in water and extra humanitarian aid to let the people of Gaza think a little about their intentions.
  • Post on an interactive website exactly where they aimed, and what they intended to hit, for the world to see.
Some of these ideas may be impractical. But surely there most be something other than pure intense military response that is vastly greater than the rockets that Hamas has been using. Israel has so much stronger an army, superb anti-rocket military defences, powerful friends around the world. They don't have to destroy their reputation and foster ever more hatred among neighbouring countries by overdoing their responses.

There is just no way that the current action will serve as a 'deterrent'; angry people are not deterrable.  If anything the current action will just stoke up more attacks on Israel for years to come and risk wider war and more Israeli deaths. It is clear that the action must be aimed at destroying weapons Israel knows or suspects to be present. And perhaps they have to be careful not to reveal the source of their intelligence, hence precluding some of my ideas above. Nonetheless, showing restraint and waging an intense propaganda war surely must be viable.




Thursday, November 8, 2012

iOS battery drain: Cause is runaway background processes such as Skype

There have been many threads on the Internet after iOS updates about battery drain on people's iPhone and iPad mobile devices.

People blame Apple, demanding a cure and threatening to switch to Android. People have suggested such 'solutions' as factory restores, logging out if iCloud etc. It seems Genius bar staff at Apple are often not able to solve the problem, and some have not believed the problem is as serious as it is.

I had the problem for the first time after upgrading my iOS devices to 6.0.1. My battery was draining from 100% to zero, sometimes in as few as four hours. It was also running 'hot'. Before my iPhone 5 had lasted at least two days on standby.

I experimented carefully with various solutions one at a time. In my case, it turned out that Skype was the culprit. Even though I haven't used Skype on my iPhone for a long time, its background process was still active, and reactivated after every reset. The solution was to 'kill' Skype fully by double-clicking the home button to bring up the 'recent apps' list, finding the Skype process, holding down the home button until the the red 'minus sign' appears, then clicking on it. After doing this, my iPhone's battery is back to normal.

Other people have reported a similar problem with the Facebook background processes, or the iCloud background processes. In the latter case it seems that logging out and logging in is the cure.

Why are these background processes behaving badly for some people and not others? It could be malformed data in the particular person's account, or any number of other possible causes. Clearly these issues are sporadic and only affect a minority of iOS users.

Apple, I think, is not to blame here, but could be part of the solution. Those with a conspiracy theory mindset might guess that Microsoft has seeded bugs into Skype to drive people from iOS to Windows 8 Mobile! Of course, I don't believe that. My theory is simply that a latent bug in Skype was surfaced by upgrading iOS to 6.0.1 for me. Other bugs for other people might have been surfaced by other upgrades.

Apple should, however, put software in iOS to detect processes that are using too much power during supposed sleep times, and warn the user about them (with instructions about how to kill the process), or force those processes to die or use far fewer resources.

The AppSwitch tool is a very good tool, by the way, to see which processes are running in multitasked mode.

Apple's stock is in a downtrend, and I am convinced that the battery woes are driving lots of people away from iOS unnecessarily. There are other issues for Apple's woes (ridiculous patent attacks against them for example), but this is one they can deal with fairly easily.

Wednesday, October 3, 2012

Video series: Creating a class diagram in Umple of a simple manufacturing plant controller system

Since I am at the Models Conference in Austria, I had to cancel my SEG2105 class. I decided to present my lecture through a series of YoutTube videos.

The video series, which can be seen here, starts with analysing a simple description of a manufacturing plant by highlighting parts of the text that may represent classes, associations and attributes. Then I use Umple Online to create the class diagram step-by-step.

The original description of the manufacturing plant comes from my book, and is reproduced below


This system will be used to manage and control the production processes at Use Case Industries’ manufacturing plant. The plant makes several types of mechanical devices. It has 10 assembly lines, each of which can be used in the manufacturing of any of its products. An assembly line is allocated to a product for a fixed period of time (anywhere from a few hours to a few days) – this is called a product run. During a product run, the assembly line makes a specified number of units of the product.

Each product is assembled in several steps. As the product-under- construction moves down the assembly line, it will be worked on in turn by a series of robots. Each robot completes one step before the product moves on to the next step (and a different robot). Each robot is dedicated to just one manufacturing step.

Each product is composed of parts. Parts may be bought from suppliers, or they may in fact be smaller products that are built by this company (in earlier product runs). In each manufacturing step, a given subset of these parts is put together. Parts waiting for assembly are kept in numbered bins; the robots know which bins to go to in order to get the required parts.

Each completed assembly is given a serial number. When orders for products are filled, the serial numbers of the products sold are recorded with the order.

Thursday, August 16, 2012

Apple Time Machine backups should not delete oldest, thin to monthly when space becomes short

The new version of the Time Machine backup capability in Mac OSX Mountain Lion has important improvements.

Most notably it transparently allows one to use multiple disks for backup. I use one backup disk at home and one at work. These allow me to be more confident that if one disk crashes I still have the other, and wherever I am working, I have an hourly backup to fall back on.

However here's a suggestion for the next improvement Apple could make: Currently the policy for maintaining backups is (quoting directly from the Time Machine control panel shown below):

  • "Hourly backups for the past 24 hours
  • Daily backups for the past month
  • Weekly backups for all previous months

The oldest backups are deleted when the disk becomes full."

My suggestion is this: When the disk becomes full, older backups should be thinned to monthly (up to three months ago) starting with the oldest. Weekly backups should always be retained for three months.

So if the disk becomes full, it should not delete the oldest backup, instead it should delete the second-oldest, and what was the third and fourth oldest, leave the what was the fifth oldest, and delete what was the sixth oldest, etc.

Why? Sometimes missing files can only be retrieved from deep history. With monthly backups far back in time, one has a pretty good chance of being able to retrieve such files. Weekly backups several years old are likely not needed.


In my experience I have retrieved lost work from Time Machine about 3 times a year. Not much. However, backups are all about insurance and peace of mind. Who knows when I will have a disk crash or do something catastrophic to my documents.

This post updates my earlier post on backups. Note that I no longer backup to Mobile Me since it has gone away. Some of my data is backed up on iCloud, although I personally feel it is critical to maintain one's own personal backup of cloud-stored data. I still back up using SuperDuper periodically in addition to Time Machine, although now I have two Time Machine disks, I will be updating my SuperDuper partitions less often.

Sunday, August 12, 2012

Fair London 2012 Olympic medals ranking - Final results

Here are my 'fair' Olympic medals rankings, based on the final results of the London 2012 Olympics, after the final medals were awarded on August 12th. This updates my earlier posts on August 8th and August 9th, which proved quite popular.

What have I done to make the rankings fairer:
  1. I have weighted the rankings by population.
  2. I have further normalized by UN development index. Developed countries have an index closer to 1, but developing countries, which have much less capacity to train athletes, are ranked lower, typically in the 0.5 range.
  3. I have weighted silver medals as worth two bronze medals, and gold medals as worth two silver medals. This seems considerably fairer than the two schemes widely used by the International Olympic Committee and the press, either ranking strictly by gold medals (breaking ties with silver and bronze), or else weighting all medals evenly.
The first table below gives my final rankings, ordered by this scheme. The raw score is column WM10M, and the ranking is column WMR.

Population and development index, used for normalization, are shown on the right. 

In all the columns in the table below, I have highlighted the top 20 countries (and ties) in the different rankings, so you can see how the different schemes affect the sequence. My preferred WM10M ranking is in blue. I have also marked the top 20 countries by population, and by development index, using grey.

Small island countries of Grenada and The Bahamas come first and second in WM10M score by virtue of winning a medal despite their extremely small population. Jamaica and New Zealand come third and fourth. Congratulations to those countries.

Column definitions
  • Gold, Silv, Bro - medal counts
  • GR: Ranking, based on Gold medals, with ties resolved by silver and bronze (top 20 orange)
  • TotM: Total medals (top 20 yellow)
  • WTotM: Total medals weighted using the 4 2 1 scheme described above (top 20 green)
  • G10M: Gold medals per 10 million, weighted by development index (purple)
  • M10M: Total medals per 10 million, weighted by development index (pink)
  • WM10M: 4-2-1 weighted medals per 10 million, weighted by development index (blue)
The second table below shows the same data, organized by population. The third table shows the same data, organized by the 'Gold medal' rankings used by the IOC.

No ranking will ever be totally fair. Maybe team sports, or sports which only give one medal such as modern pentathlon, should be given higher rankings for the medals. But there is no clear way to do come up with an unbiased ranking scheme if those adjustments are made. I think what I present is a good compromise.


Table 1: Rankings ordered by WM10M: 4-2-1 weighted medals per 10 million, weighted by development index.



Table 2: The same data ordered by size of country (PopM)

Table 3: The same data, ordered using the IOC's gold medal based rankings

Thursday, August 9, 2012

Olympic medals ranking August 9 by population and development index

(See here for my final update as of the end of the Olympics)

Yesterday's post was very popular, so here is an update one day later. The data below are as of mid day August 9th, 2012.

I have ordered countries explicitly here by my WM10M ranking, which is medals per 10 Million people, but normalized for UN development index, and where a silver counts double the weight of a bronze and a gold counts as double the weight of a silver. For explanations of the other columns, see yesterday's post.

Jamaica passed New Zealand to move into second place today.

I will post a final ranking at the end of the Olympics, and may do one or two between now and then.

A raw spreadsheet is here.


Wednesday, August 8, 2012

Olympic medals rankings normalized by country population and development index

(See here for my final update to this as of the end of the Olympics)

We all see China and the US jockeying for position at the top of the Olympic medal counts. But which countries are really doing best?

The table below orders countries by population (right column marked PopM). Coloured cells are the top 20 (and tied) countries according to various ranking criteria.

Orange is the 'gold medal' ranking, with ties resolved by silver and bronze medals. This is the ranking used by most rankings tables. Yellow is total medals. Green (WTot, WMR) is total medals weighted such that Gold has a value of 4, silver a value of 2 and bronze a value of 1. This is the system I prefer when population is not considered.

Purple (G10M, GMPR) is gold medals per 10 million of population , but normalized by UN development index (DevInd column). A country with a lower development index has fewer resources, so should be expected to be capable of training fewer athletes. Light orange (M10M, MPR) is total medals, again weighted by population normalized by UN development index. Finally blue (WM10M, WMR) is weighted total medals (as per the green rankings) weighted by normalized population.

Grenada does best in most rankings by virtue of its one gold medal and small population. New Zealand is doing best in countries with moderate population. Other countries doing well are Jamaica (due to their sprinters) and Slovenia.

Great Britain is the large country (by population) doing best. North Korea and Australia also stand out.

The US and China a quite far down, at 37 and 58 in my blue (WMR) rankings, suggesting that although they are doing well overall, they are not doing as well when population and development index are both factored in.

The table notably shows very populous countries with few medals: India and Indonesia stand out near the top.

The data is as of midday Wednesday August 8th. I intend to update it at the end of the Olympics. The original spreadsheet can be found here.

I wish the media would report data like this for all to see.




Friday, June 1, 2012

Greenland record temperatures: How clue are we to the tipping point?

One of the few blogs I read consistently is Dr. Jeff Masters' WunderBlog. His focus is on hurricanes, but he also reports the latest in climatological and meteorological news. Yesterday, his key news was that record May temperatures have been experienced in Greenland.

Why is this so important? Because the future of civilization as we know it is potentially tied up in the Greenland ice sheet. People talking about climate change tend to focus on warmer summers, more droughts, extreme hurricanes etc. These are bad enough. However if Greenland melting accelerates, several drastic consequences could come to pass:
  • Sea level rises on the order of tens of meters, destroying the cities and agricultural lands of billions of people
  • Drastic shifts in climate, potentially freezing Europe by shutting down the North Atlantic Oscillation.
Two very interesting articles show that the Greenland situation is highly complex. There are huge volumes of information to absorb from the articles, but I would like to draw attention to two quotes:

To oversimplify somewhat, Greenland is unstable to increases in temperature, because it exists purely through its altitude maintaining low temperatures. If the Greenland Ice Sheet were somehow removed, it would not return.
Realistically, they mean it would not return until another ice age.

The net effect of these processes [melting ice removing gravitational attraction from surrounding seawater] is that sea-level rise occurs faster in areas further away from the source of the melting. For example, in the case of melting Greenland ice, there would be less sea- level rise than the global average in the North Atlantic, near to Greenland.
So if Greenland melts, who would be inundated the worst? This is complex and research is still ongoing: Density differences due to salinity and differing expansion of cold and warm water will be one influence; patterns of circulation (subject to rapid change) will have an effect, gravity mentioned above will have an effect and so will subsidence and rising of certain land areas due to geological action and rebound from the last ice age. It would seem, however, that areas of southern Asia with vast populations near sea level are going to be hit the worst. 

How far off is this? Again there I have read many estimates. A meter or two in the next century would be possible, and tens of meters in this millennium quite conceivable. But even if it takes two centuries to get to a meter that is still utterly unacceptable.

One thing is clear: Uncertainty will continue for multiple reasons: We don't know when the 'tipping points' will occur (e.g. shutdown of ocean circulation, feedback leading to accelerating melting), we can't run a controlled experiment, we can never get all the data we might like, and we can't know what socio-economic or technological impacts occur (e.g. reductions in fossil fuel use due to economic depression, technological advances etc., or the inverse). Conservative politicians and climate deniers feed on uncertainty, claiming the science is not settled. But what is not settled is the timing, not the certainty of drastic change if we don't take drastic action.

It is hard for politicians to think even ten years in the future. But we really must think hundreds and thousands of years into the future because we hope to have descendants around then. The further we get into the future, the more absolutely certain we are of devastation if we continue policies that will lead to climate change. 


Thursday, May 31, 2012

What's Important in Software Engineering Education articles still having an impact

Over a decade ago I conducted research in which I determined that certain areas of software engineering education are under-taught and over-taught, based on their relevance to the careers of software professionals.

The three articles published from this research continue to be cited and discussed. Just recently Robert Glass and Johann Rost summarized some of my findings in their Dark Side of Software Engineering blog. They invited me to add some of my thoughts, which became part of their blog post. I invite you to read their blog entry by clicking here.

In my original papers, I found:

The three papers from my original research are below; please cite them:

Note that the raw survey data is still available online, and has had over 10,600 hits, suggesting the data is being used quite a bit.

I am planning on repeating the study and comparing the new data with the original. I will add a few topics that have become important in recent years such as web development, mobile development, agile methods, and game development. I will also examine recent curricula for additional items.

If you are interested in helping either as a participant or to help distribute the survey in your company, please email me with the subject line Education Relevance. In the original survey it was extremely useful to receive the assistance of senior managers and HR personnel from several companies. I was able to give those companies sub-analyses relevant to their employees.

In my comments in Glass and Rost's blog, I added a few additional points worth reiterating (these are my opinions, not based on any survey):
  • Central to becoming a productive software developer, in my opinion is practice, practice, practice, but structured so the practice is spread out over diverse technologies, problem types and application domains.
  • There are different sub-contexts for education. If you want to be a quality-assurance expert, you would want to focus on material that would be of much less interest to the 'average' developer; and clearly many of the less-important topics such as calculus will be critical to certain application domains. The survey results should not be interpreted as meaning that all software engineering or computer science educational programs should give uniform emphasis to the same set of topics.
  • The notion of agility is becoming not only important in the work force, but also in education: Educational programs need to become more agile at responding to the needs of students (actually I think the reverse is happening in some contexts where fear of losing accreditation drives decisions). But, even more importantly, having students work on agile projects can, I think, help them learn the most important material they will need. I have found UCOSP student projects very successful in this regard.

Tuesday, May 29, 2012

All sugar is just as bad, even organic cane sugar

I was watching this video in which a nutritionist points out correctly many important facts about sugar:
  • In the rush to remove fat from foods manufacturers are adding sugar. She rightly says sugar is toxic and addictive. From the evidence I have seen (she doesn't say so explicitly) it is worse than the fat.
  • Artificial sweeteners have been found to make us crave even more sweet things
  • There are many hidden sources of sugar.
Excellent video I thought. Until near the end.

Just before the end she suggests using organic cane sugar as a substitute. What! In that one statement she totally destroyed her credibility. The added nutrients and reduction in undesirable elements in the organic cane sugar are negligible. In terms of effect at increasing obesity and hear disease, the organic cane sugar is chemically pure sucrose, and will be just as fattening and addictive.

Wednesday, May 16, 2012

Software engineer is top career, yet again

Here's yet another article ranking "software engineer" as the top ranking career choice:

http://www.careercast.com/jobs-rated/2012-ranking-200-jobs-best-worst

The following InformationWeek article comments on this and gives a few reasons why software engineering is so great.

http://www.informationweek.com/news/global-cio/careers/240000347

They talk about flexitime, problem-solving excitement, team-orientation, creativity, and freedom to fail. The latter is interesting and I am not sure I fully agree with it: Yes, a software engineer will often try alternatives and discover some don't work, but I think 'freedom to fail' is not the way to describe this. Ideally any organization employing software engineers will want people who can spend very little time on 'failing paths'. Instead, a good software engineer will prototype and explore alternatives relatively quickly, and then actively design for a solution that is highly unlikely to fail, or 'refactor' when they see failures looming. A key aspect of engineering is designing robust systems that do not fail.

Another thing I question in the Information Week article is the way the author contrasts software engineering and programming. "Unlike programmers, software engineers typically work in teams ", they say. Firstly, I have long been convinced that there is little meaningful distinction in the workforce in most companies, it is really only a matter of education, skills and attitude that makes you capable of being a software engineer. In reality essentially all programming should be done by people with some software engineering background. Secondly, most people who one might call 'mere' programmers (lacking software engineering core skills) still have to determine requirements, do design and end up managing projects. They just can't do these things as well as someone who is trained. Finally, contrary to the article: Software engineers and programmers are all equally likely to work in teams (or not) in todays world.

Here's my take on why it is truly great to be a software engineer:

  • The sheer number of diverse jobs with good pay
  • The opportunity to be creative
  • The sense of satisfaction from getting something complex to work and be happily used by others
  • The feeling of gratitude from thankful clients
  • The rush from solving complex problems.
  • The chance to interact with people and technology from all aspects of society. You like health care, music or games? Go find a software engineering job designing systems in these domains.
  • The human interaction with clients and colleagues and the resulting team spirit
  • The respect from being part of the professions of engineering and computing. Note that I am careful to indicate that there are two intersecting professions you are part of.
  • The flexibility of the work environment. Opportunities to work at home, or have flexible hours are common.
  • The ability to be always learning. Technology and application fields change. Learning is fun.
  • The opportunities to lead and manage for those who want

Thursday, February 23, 2012

Distracted driving and cellphones: Technological solutions to avoid overreactive bans

Distracted driving is clearly a critical safety concern, however I believe that banning use of cellphones is a major overreaction.

Yet that is precisely what the US National Transportation Safety Board and several other organizations are pushing for. They are not just talking about texting or hands-free use, they are talking about banning all non-emergency calls even with hands-free technology.

Their key argument seems to be this: Unlike talking to a passenger (who can also see the road and recognize when the driver is in a situation where they need to ignore the conversation to pay higher attention to driving), or listening to the radio (which is not interactive), talking to a remote caller is particularly distracting since the caller will keep on talking through critical driving situations, and drivers will tend to feel compelled to maintain the conversation.

That may be the case. However rather than a knee-jerk ban, I think that it would be better to impose requirements for a technological solution. Here's what a cellphone should be capable of doing, within a few years.

  • Within two years: Notifying the person at the other end of a cell-phone conversation that the call is from or to a vehicle in motion: This would be relatively easy using GPS and accelerometer date today. The phone could simply inject into the conversation when the call starts, or the vehicle starts moving, or after a prolonged stop, the spoken words, "vehicle in motion". People would get used to it. It wouldn't solve all problems but it would be a first step. It might he hard to distinguish between a passenger talking vs. the driver talking, but a passenger could easily explain the situation.
  • Within 5-7 years: Interacting with upcoming vehicular technology inject a warning, or in extreme cases suspend a call, when indeed a driver is facing a difficult situation. For example the phone could take such an action when it detects the dense fast-moving traffic, an accident-prone zone, slippery roads, low visibility, accidents in the area,  potential rapid-braking requirements ahead, or indeed the driver or the driver of a nearby car behaving in a way that shows tiredness or distraction. At this level of technological development, the phone could also detect what area of the car it is in so as to know whether it is in the hands of a passenger or not.
  • Within 10-12 years: providing a video link to a camera facing forward out of the car's windshield so the caller can see the conditions on the road.

I think part two of my above proposal could in fact help actively reduce accidents, since the driver himself or herself would also hear the warning. All three of the above could in turn become requirements, as technology develops. Phones could be certified as 'distraction-reduction enabled'.

I used CB radios in the 1980's. Truckers and many other commercial drivers have used such 2-way communication devices for decades. Cellphones are only different because the person at the other end may be someone who is not also a driver, or aware of the driving context. My suggestions would largely remove that argument.

Talking while driving can have several important benefits.

  • It can keep the driver alert on long stretches of highway driving.
  • It can allow the driver to make better plans, which can sometimes improve safety.
  • It can allow drivers to communicate their status to others which can be helpful in many ways.
  • It is needed in many lines of business, where people need to talk with dispatchers, or decide where to drive to based on a changing context. Spoken communication is almost certain to be better than information appearing on a screen.
  • When lost, having someone guide you to the right place can be very valuable. Lost drivers are likely to be particularly distracted as they deflect their ideas to look for address numbers, 

And there are many other sources of distraction on the roads:

  • Use of GPS-based navigation devices
  • Talking to children or blind passengers, who be as less aware of context like external callers
  • Changing channel on the radio, or the heating controls, or other aspects of our ever-more-complex vehicle controls.
  • Drinking to keep hydrated and maintain one's caffeine levels; eating snacks. Being hungry and thirsty presumably can result in their own source of distraction, so we wouldn't want a complete ban on doing these activities.

There is no technological solution to rowdy kids or the need to drink a coffee. But there can be for the distractions worsened by technology itself.

I am completely in favour of a rigorous ban on texting, and strong restrictions if other devices that require deflecting the eyes or using the hands. In this regard, user interfaces and accuracy for voice-driven calling and voice-output on navigational devices needs improving. For example, I find my iPhone 3GS normally fails to call the correct person or play the right song when I use Voice Control (maybe it is my half-British accent). This should be an area of urgent focus for UI improvement. I would like, to have a few preset commands, 'call home' being the most important, that would be ultra-reliable.

I can see an argument for 'cell-phone' free zones or conditions (bad weather, heavy fast-moving highways, complex inner-city road layouts, etc). But the outright ban is over-reaction.

I can also see an argument for greater limitations on cell-phone use for new drivers (akin to zero-alcohol policies, and limitations on night driving). Various jurisdictions now also require driver re-tests for seniors above a certain age. Perhaps limitations on cellphone use could be integrated with such requirements. It would likely be possible to devise speed-of-reaction or distractibility tests. It is clear that as we age, or ability to multitask diminishes. On my license I have a requirement to wear eyeglasses because I couldn't pass a vision test without them. Perhaps I could have a requirement to not use a phone if I can't pass a multitasking test.

For an earlier post on my predictions for smart phone capabilities, see here.