Category Archives: Random thoughts

Random thoughts

End of Summer – Thank you!

This summer was a big one at for CDOT (Centre for Development of Open Technology).  We had almost 30 RA’s working on many many different types of project.  Yesterday was our final cdot presentation day for the summer.

For those unfamiliar, CDOT is an applied research group within Seneca College.  Over the years we have worked on many different projects related to open technology in various areas.  I am one of the faculty members involved with CDOT.  Projects tend to run over the course of a semester or two.  Students are hired either while they are studying or just after they graduate.

My team worked on projects related to 3D web graphics.  This summer I had two projects.  The first was a project with Box, to implement a 3D data visualization tool.  The second was with a Gorilla Productions.  The project was to implement realistic cameras for three.js.  (cameras that behave as real world cameras do).  In total I had 4 awesome research assistants working for me (Andrii, Barbara, Dmitry and Koji).  They have done a fantastic job on their projects.

However, aside from my two projects, CDOT also hosted many other projects.  One of the reasons the reasons that CDOT exists is to provide experiential learning opportunities to our students.  A chance for them to work on real projects and develop skills.  One of those skills is the ability to talk about their work.  Thus, each Thursday was we have “Demos”.  During that time, the teams will talk about their project and what they have been working on, problems they encountered, solutions they found.  Yesterday, was the last day and everyone had a chance to talk about thoughts of on their summer’s work.

Generally the comments were all very positive. However, there did seem to be a few themes that were shared by multiple students.  These were:

  1. Being surrounded by other very smart people working on interesting projects has helped them develop as programmers
  2. Demo days helped them learn from other teams even when they were not working on remotely the same thing.
  3. Demo days made them less nervous about speaking in front of crowds
  4. CDOT provided opportunities to work on something important with a great amount of freedom to design and implement their work
  5. CDOT experience has helped them to either find a job (a couple of students will start in new positions right after labour day) or the confidence that they will be able to find one shortly.

I truly believe that CDOT is one of those places that are unique and special.  We have students that do very interesting work on a wide variety of projects.  Our students are very bright, and I have always admired their ability to exceed my expectation.  Many of you have taught me things I did not know.  To all the RA’s at CDOT, know that you are the ones that make CDOT special.  When I see what you do, when I see what you have accomplished, I am reminded of why I teach.   Thank you!

On Code Documentation

There are two major problems that I see when I look at my student’s documentation for their code.

  1. no documentation … we are talking about not even having a header with their name on it here for assignments
  2. too much documentation – repeat all code in comments!

Both of these are problems.  One may not seem like a problem but it in fact is.

The lack of documentation in its entirety is just a job of incompleteness.  Most students understand that when they don’t do it, they will lose marks.  They know they should but for whatever reason they didn’t.   Its like knowing you should exercise but you don’t…This post isn’t about that.  The complete lack of documentation is relatively simple to address.

This post is addressed to those that document everything.  I know students who do this are very proud of their work and they put a lot of effort in it.  I get that.  I’m not knocking that.  However, I would like to ask you to please please please please please stop doing it.  Don’t do it.  It isn’t better.  A bad comment is worse than no comments at all.

Here are a few commenting guidelines:

  1. please don’t repeat your code in your comments… your code is there… anyone reading it sees what it does if they need to know it.  “this is a for loop” is not useful.  “this loop runs 10 times” completely silly.  “assign 5 to x”….please stop. please stop.
  2. I have found that comments become sacred over time.  programmers do not hesitate to alter code… and yet comments…well you can’t touch those (sarcasm).  So, with this in mind, I encourage you to write as little comments in the body of your code as possible!  Your code should be clear enough to read.  Unless you are doing something very very tricky, don’t put in a comment in the body of the code.
  3. Comments that are useful explain reasoning, that may not be immediately obviously.  In my first programming job I was trying to hunt down a bug in a program and I saw this comment “find first sunday in april and last sunday in october”… I could tell thats what the code was doing… that wasn’t hard.  I then spent a day trying to figure out why they needed to do this and whether or not it was the cause of the bug.  What they did and how they did it was clear… the code said as much.  I couldn’t figure out why it was that this was something that needed doing.  Finally, I realized the why and changed the comment to “adjust time calculations for daylight savings times”… to me this makes way more sense.  I’m not saying how to do it (and the how has changed since then as the time of year that daylight savings time comes into effect has changed).

Here is are the three things you should document:

  1. Have a header!  State who wrote the code, major modification dates, versions etc
  2. state the intention of each function (not how but what it is suppose to do), its parameters, expected return value and restrictions.
  3. document unclear variables, units  of measurement etc.

That’s it.  Let the code speak for itself.

Thank you to my teachers

Recently I got a tweet from a former student saying that they really liked my Data Structures class. It was really good to hear that and filled me with warm fuzzy feelings. It also got me to think about all the wonderful teachers in my academic career. There have been so many. I don’t know if I have ever expressed my gratitude at the time but I think it would be good for them to know (although I’m not sure if any of them will ever see this blog… but they say that nothing ever gets erased on the internet so maybe). So here is a small list of teachers/professors/instructors who have made a difference in my schooling.

Dr. Dekang Lin – My thesis advisor. The one who spent countless hours trying to explain grammars and parsers to me. You have taught me so much and provided me so much support. I thank you from the bottom of my heart.

Dr. Helen Cameron (Univeristy of Manitoba) – who was very tough but incredibly fair. I never worked so hard to get things done as when I had two courses with you in the same semester.

Dr. John Bate (University of Manitoba) – I never directly used what you taught me (digital logic) but it was the course that made me really understand how computers work.

Al Marshal (University of Manitoba) – my own data structures prof… clear, concise with a sense of humor too.

Dr. Bill Kocay (University of Manitoba) – my other data structures prof who helped me to understand all about suitcases 🙂

Dr. Neil Arnason (University of Manitoba) – who helped me out a lot when I started teaching and made it easy for a newbie like me to transition into this career

Dr. John Anderson (University of Manitoba) – who gave me my worst grade on my transcript but you were my first CS prof and you always did a fantastic job teaching… and you know I mean it when I say this since you gave me my worst mark 😛

Dr. Russel (University of Manitoba) – The mandarin classes were awesome.

Mr. Doug Silzer (Cedarbrae Collegiate, Scarborough Ontario) – who taught me to reason through problems and never gave me a straight answer.   Thinking through to a solution is important after all :).

Mr. French – who taught history and not French :P.   Your class was amazing

Mr. Horkoff (Ken Seaford Jr. High) – a teacher who grew my love of science.

Mr Thies (Ken Seaford Jr. High) – a teacher who taught me to do my homework even when I thought I knew what I was doing already because a good student do their homework. I believe that were it not for this enforcement of homework doing, I would not have been able to so easily continue my studies at higher levels.

An ESL teacher in Meadows School in Brandon Manitoba (sorry I forgot your name, it was long ago, I was really really young, and I was only there for 3 months)  who taught me that the “th” sound required the sticking out of the tongue to be properly pronounced. “The” not “De” :).

Miss Jenny Smith – awesome exchange teacher from England who taught at James Nisbett in Winnipeg for one year. You were awesome.

So, if anyone reads this and knows any of my former teachers, please pass on my message of gratitude.  You have my thanks.

The cost of the easy way out

So, this post will be a bit rambly because I am completely exhausted after a marathon paper writing editing session.  However, I figured I should write this now while these thoughts are still in my mind.  In the past week or so, a few seemingly unrelated events/discussions have gotten me to think about how we get where we are.  Now, lets start off with the things that got me thinking:

  • a …how do I put it nicely…well a crazy woman wrote an article about “Chinese” mothers that some of my friends keep linking me and asking… I don’t remember my mom being this awful do you?
  • a very interesting discussion about expectations for our students with my colleagues at the start of the school year
  • a paper submission to a conference

I’ll start with the article… now firstly, I’ll start off by saying that I pretty much disagree with just about everything the author talks about.  While my mother is definitely chinese (I can ask her again but I doubt she  will say different) she was not the crazy woman in that article.  However, there is one thing that my mother did do … she believed that her children could learn.  I’m not talking about always being number 1 in a class but she believed that since my brother and I seemed perfectly healthy, we should have no trouble learning and that it was just about working hard at it.  I remember that in grade 3, I had nearly been held back a year.  Thats right… I nearly flunked grade 3 (gasp).  It was a year of movement for my family.  I had started school in Toronto, then my family moved to Brandon, Manitoba (missing about 2 to 3 weeks of school during that process) and  moved out to Winnipeg Manitoba for the last month of the school year.  Moving twice in a year can be rough especially if you move between provinces/school boards with different curriculum.  Add to that an English problem  and it was pretty easy to see why my last teacher suggested I redo grade 3(I was still in ESL at the time…btw total sidetrack but, I want to give a big Thank You to the ESL teacher from Meadows School in Brandon, Manitoba for telling me to stick out my tongue for “th” sounds! you rock and while I don’t remember your name, I do want to thank you) My mom understood that it wasn’t my ability to learn and asked that I be put into grade 4 with the provision that I would repeat that if necessary.  That summer, my mother made me learn the multiplication tables at home and got me a tutor for English.  It was a summer where I had to put in a lot of extra time to schooling instead of to playing but in the end I had no problems with my education again.  Rambling point being this… my mom believed that I could learn, and made sure that there was no excuse for me to not do so.  It took a lot of  work but in the end I got through school just fine.

At the beginning of the semester our colleagues and I had a discussion about what we should expect of our students.  My colleague Dave had reflected on this discussion earlier.  I think that like him I often feel that our students are given the short end of the stick…they have to go out and prove that they are just as capable as a University grad.  In the time that I have taught here at Seneca, I have met a lot of students who do such wonderful work that they continually amaze me.  Sometimes we get to chit chat and talk about their past.  Some of them had struggled in high school which had barred their entrance to University and yet here in College they flourish.  Partly this is growing up and partly it is finding something that they really want.  If you ask me what makes one student better than another, I would have to say that mostly it is drive.  They succeed not necessarily because they were the type of programmers that were born with a keyboard wrapped around their fingers  but because they want to succeed.  They put in the time to learn things they don’t know and they keep working at something until they get it.  This more than anything else is what sets them above the rest.  It is how they are able to succeed.

And finally my paper.  Today I submitted a paper to a conference and it was right down to the wire.  Part of the problem was that I was paying for my own laziness years earlier.  When I was doing my master’s thesis I had asked my prof if I needed to write it with LaTeX (pronounced Lay Tech).  Its a layout language widely used in scientific publications.  My prof’s answer at the time was that I should.  However, because it was a master’s thesis and not a phd thesis that he wouldn’t force me to use it.  I was allowed to write it with a word processor as long as I stayed to the formatting guide lines set by the faculty.  Thus, like many people who take the easy way out when they could… I did.  I did not learn to use LaTeX and just wrote my thesis with a word processor.  This morning while I was finishing the final editing of our paper, I just couldn’t get it to look anything even remotely like what the conference wanted.  What I knew was that they had a LaTeX template so I got their template and put my paper into that form.  It turns out that doing that wasn’t really hard to get the paper into the template but it was all the little details that I had problems with.  There were just some things that did not work like I thought they should.  I kept feeling that it would have been much easier if I knew how to do this from the outset that I wasn’t flipping through helps and faqs trying to solve the simplest problems.  In the end the submission made it in just 30 min before the deadline and did not have time to include a few more screenshots or make an awesome movie.   All this because I was too lazy to learn it when I should have learned it… one of those lessons that bites you only later.

In the end this rambling post is mostly about this… while you have the chance to learn, learn as much as you can.  The easy way out is never free, it always comes with a price.  That you while you should expect to succeed it never comes without work.  Finally there is no reason to believe that you cannot do something if you work at it.  It just requires time, patience and work.  Not always fun but definitely always rewarding when you realize you can.