Saturday, September 29, 2012

Back to GCC

I get to work with graduate fellows in Computer Science, thanks to a GK-12 NSF grant.  The last two years I was privileged to work with Jason Robison, a great, kind person who touched the lives of many of my students.  I was lucky to get Jason to help out with our Comp Sci program for two years, and we miss him a lot.

This year we are lucky to have David Knox working with us.  David supports our program wonderfully and is working with me to develop a unit on simulations in Computer Science.

David is old school--but in the best way possible.  He eschews all the typical barriers to education and makes me think hard about my effectiveness as a teacher.  One day David said, "well, what matters now is how many of them are actually engaged."  He then walked around the room, checking up on each and every student in class.

That was a gut check, really.  I don't avoid facing the hard facts of being a teacher in a country that does little to ensure our students are academically prepared for college.  We pay our sports stars salaries that put them far above the real heros in the USA.  If you touch others and (more importantly) make them think a bit, you have done well!

Oh yeah--so what does this have to do with the GCC?

Thursday, August 30, 2012

GIMP--now native app for the Mac



Swamped in the usual start-of-the-school year work, but one thing that really made my day today was this GIMP news that I read this morning.  I immediately downloaded the new native Mac version of GIMP and love it.

No more Photoshop in my Intro to Computing classes.  GIMP ubber allies!

Saturday, August 4, 2012

May as well share it...



I just came across this image I created while working through the excellent Shelly Powers book Painting the Web.  That's a screen shot from me trying out the new Nodebox application, made to look like a Web 2.0 thing.

Monday, July 30, 2012

ARGH!!! Best Practices HTML5 Canvas

I'm adding a lot of web development to the Comp Sci curriculum this year.  One thing I've been working on is getting the basics down solid for the new frameworks we'll be using.

Easier said than done.  Case in point: the many HTML5 Canvas books and their suggestions for creating a basic game/animation framework.

Without going into detail (I have a headache), let me just summarize:

Of the many books I have purchased on the HTML5 Canvas element, no two books agree on what should be considered "best practices" with programming the Canvas.  What makes it worse is that most of them speak with conviction as to why their approach makes the most sense.  In another world where I only bought one HTML5 Canvas book, I would simply see it all from one viewpoint.  Instead, I live in this world, and my current headache is mostly from going back and forth over the last several hours on various topics like:

How to best ensure the page has loaded before your script runs


Don't even get me started on this one.  In the end I just said %$&k this!--I'm using JQuery!

How to best erase the canvas between frames


Well, this one isn't really a problem of the various books suggesting different approaches.  This one is just a headache by nature.

How to control the timing of your game or animation


Oh boy.  This one really has changed a lot in the last year.  It appears the best practice now is to NOT use "setTimeout()" or "setInterval()" but to use "requestAnimationFrame()" instead--which is not even mentioned in half the books available on Canvas programming.  Sheesh.

Sunday, July 22, 2012

New GIT Project for various Generative Art frameworks

http://commons.wikimedia.org/wiki/File:Helping_hand.jpg


Sometimes I feel like I'm all over the place, sampling all sorts of new stuff and being overwhelmed with the task of weeding out the options to include in my Computer Science classes.  My only advice would be to carefully consider what Comp Sci topics you want to cover, and then look for interesting contexts in which to embed them.  For me lately, the context has been Generative Art.

I started a wiki on all the applications that I have tried for making Gen Art, but the thing quickly grew too big for me to manage, and too ... ugly ... for anyone else to seriously consider joining in on the work.  A wiki done by one person is not really a wiki.

The mistake I made, was starting too early.  Of course I was all excited from trying about a bunch of new applications, so I started putting all sorts of stuff on the wiki, including a huge table of the pros and cons of each application.  What I should have done instead was to put the whole thing off for a month while I worked in more depth on each application.  So that's what I did.  I have been working with my co-teacher in the CS department on updating our CS curriculum, so it was the perfect time to think deep about how these new apps could be used, and where they would fit into our CS curriculum.

Now things are much clearer.  I have had time to play around with all the apps and have narrowed down my list to the ones that find myself using the most.

You Can't Go Home Again

So ... I was ready to go back to my wiki and clean it up a bit and make it better.  And yet ... I didn't want to go back.  I'd look at it and think, "what a big mess--there's good stuff here, but my ADHD hates the intimidating way it's all plastered on the wiki!"  So I decided to make another change in our CS program, and I'm so glad I did.

In the past, our student developers team would use SVN and TRAC on our own server to host our projects.  We also have a private phpbb forum that we use for discussions on current projects.  But I have increasingly found myself interested in two very popular alternatives to the above approach: GIT and GitHub.

Rather than go back and redo the wiki I had already started, I created the Helping Hands project on GitHub, and I'm glad I did.  Of course I had the usual feelings of "...but this is just a simple project of my own, why put it up on a public repo and let anyone at all see it?"  And of course there was the usual guilt I have when something like GitHub is free (as long as the project is open source).  But then I spent some time reading research on the lack of women in open source projects.  I realized that my fears of putting my work out there for everyone to see was, well, normal.

Browsing GitHub, I entered some search terms like "education" to see what projects were out there that could possibly be similar to what I wanted Helping Hands to accomplish.  What I found was pretty surprising.  Of the projects I found, almost all of them were little tiny "hello world" type projects that had only one contributor.  Some only had a README file.  Others had one file of code titled "chapter01problem01.js" and no README file at all.  By "education," most were referring to the fact that the project creator was learning something and wanted to keep their work on GitHub. It was pretty clear to me that these were little experiments that someone tried and then totally abandoned. But there they are--doing nothing and not being read by anyone except ... me. Somehow that made me even more inspired to launch Helping Hands on GitHub.

Take the Chance and Share Your Work

The power of a site like GitHub is that they embrace the new business model that is totally killing off big corporations like MicroSoft. They realize that you don't have to nickel and dime users to death to be profitable. The writing is on the wall ( and it's in Chinese , btw).

One of the best ways to get batter is practice.  But practice can be an escape environment where you feel all safe and isolated and no one will make fun of your skills.  I just want to encourage you to take your work and open it up to others.  When I saw a few typical GitHub projects, I got a perspective that GitHub (and open source projects in general) are just as varied as we are as people.  If you only see GitHub from an occasional blog post linking to a successful and large project hosted there, well, you tend to think that anything you could create would be laughable.  Truth is, laughable is the norm, and on all those flimsy "education" projects there was not one troll on there saying, "this is a bunch of crap, just give up!"  The trolls are in our heads, for the most part (or posting comments on CNN.com).  The majority of people you will meet on open source projects are willing to help you get started into the exciting world of open source development.

It's not the real world, it's nicer.







Wednesday, July 11, 2012




Okay, I'll admit: I'm a blow-bag and can talk for a long time once I get going on something I am interested in.  When I was asked recently to define "computational thinking", I told the interviewer that I would get back to her on that one, as we had less than 15 minutes left to talk.  Here's what I ended up sending to her:

Q: What is Computational Thinking?

I would say that CT is the act of applying computational approaches to solve problems and to further understand how things work.  I don't want to say it's ONLY about problem solving, as it can also be a recreational activity, like when I play around with Structure Synth and Processing (and Nodebox and Context Free Art).  Certainly observing patterns is involved.  

I used to wimp out and say, "well, I recognize it when I see it."  That, however, seems to have some validity, and it led to me wanting to create a CS class that involved no text editors and no coding.  Education misses out terribly on the one thing that really helps get people thinking computationally: capturing that feeling you get when you start playing a game and you're not really sure how the game works.  The process of interacting with the game environment is very similar to how people best ACQUIRE languages (as opposed to LEARNing languages).  It's involves trial and error, and mistakes are not a big deal.  If mistakes are a big deal (like on a high pressure test, or when someone is uncomfortable during language immersion), learning almost completely stops.  

Think of a good puzzle.  Or here's something I witnessed once at a youth leadership-type conference:  after we had finished most of the activities from the day and were just relaxing in a cabin (in northern WI), one student asked another to "play a tricky game" with him.  Those two students discussed what they would do for a while and then they worked as a pair to show us a game.  Student A left the room and student B explained the game to us.  We were to select some object in the room and see if student A would be able to identify our "secret" object.  We discussed it and chose something like a light-switch.  Student A came back into the room and student B began asking questions like "is it that lamp?", to which A said, "nope."  This went on for a while, through many seemingly random objects, until student B asked "it it that light-switch?"  "Yes!" said A.  

Alright, we had to figure out how that happened.  For the next 40 minutes or so we worked together to impose constraints on A and B to rule out different ways they could be accomplishing their trick.  We had A turn and face the wall.  We made A not talk at all--instead he could only point at objects.  They always got it right.  But we figured it out eventually.

Why bring up that example?  Because those 40 minutes are still clear in my mind and that was 25 years ago.  I have no clue at all what the activities were that day, nor what the lessons were supposed to be.  But I remember that game, because it had all the makings for a successful lesson.  Players A and B did not lecture us for 30 minutes before we played the game.  They did not give us hints.  They also made it clear that they were willing to keep up the game, but we would have to figure it out--they weren't going to TELL US.  

Was it computational thinking?  Well, it certainly was logical thinking that got us the answer.  I have played similar games with students that WERE more overtly numerical in nature, but computational thinking embraces discrete mathematics, and discrete math is simply ignored at the secondary level (except for a little bit of probability, but that's only to pass a "there are 4 colored balls in a sack" type questions on standardized tests.

What's more important to take from that example, though, is the HUGE difference in that activity and a typical class for a student.  Students are much more likely to remember the "Bejeweled" game they were playing under the table on their smart phone than they are to remember the lesson.  

Sunday, July 8, 2012

Case Study in Wed Design (1: Plan the site)

The first step in making a website is to develop a plan.  That's what we'll do here, looking at what we want to accomplish, what our constraints are, and so on.

Disclaimer:  I'm no pro!  I also have the advantage that most hobbyist coders have: I don't have to work for anyone under a contract.  If you are reading this and want to be a freelance web designer, realize that it becomes much more complicated when you are hired by a client to make their site.  This cartoon should serve as a warning....  If, however, you want to experiment and try to make your own site or want to help someone make a site, this case study shouldn't teach you too many bad habits.  :-)


Our Goals


Let's begin by looking at what we want to accomplish.  We're designing a site to promote a volunteer group's trail system that they maintain.  Because they have zero web presence at this time, almost anything we produce will be an improvement, even a simple site that merely has some static info on it.  On the other hand, I can think of some really cool things that we could try to include for supporting portable devices that would enhance the experience of using the trails.  Users could mark events or wildlife sightings on a shared map, we could utilize geolocation, and so on.  But, let's keep this simple and more traditional.

Here are some goals we can consider:

  1. The site should be relatively simple but with a consistent theme.
  2. The site should have a clear navigation scheme--not something "cutting edge"
  3. The site should have a web address that makes sense for the site.
  4. The site should work reasonable well on older browsers.
Here are some things we can consider including on the site:

  1. An attractive home page that gets the user's attention
  2. A gallery of photos that were taken on the trail system
  3. Information about the trail system during the 4 seasons
  4. Information about the EATS group itself
  5. A page that gives info on upcoming events
  6. A contact page
  7. Clear directions on how to find the trails
  8. An interactive trail map--almost a "virtual tour"
  9. Historical information about the trails
  10. Information on the "Woodland Waddle" horseshoe event.
There are several things here that make this much easier than a typical commercial site you could be hired to design.  Most of this can be done with HTML and CSS.  Unless we include a guestbook or a system for receiving donations, we can probably do without using much PHP or a database.  Maybe some JavaScript for the gallery, but for the most part this is a simple site to create.  We can think of things we can add almost like modules, but the base site is just HTML and CSS.

So let's get started!  The first thing to keep in mind is the "separation of powers" between the languages we'll be using:

The Three Layers of the Web

  1. HTML for content.
  2. CSS for style.
  3. JavaScript for behavior.
For a small site, it is very feasible to make the main page first and then alter copies of that page for the other parts of the site.

The first big decision we have to make is deciding on WHAT the main page is about.  Is this site primarily for the EATS group, or for the Scotch Creek Woodland Preserve?  I'm going to go with the Preserve itself as the focus, but we can change that later, if necessary.

Here's a preliminary sketch of the site arrangement:

Main Page: Scotch Creek Woodland Preserve
  |
  |--Events
  |--Four Seasons on the Trails
  |--Gallery
  |--Interactive Map
  |--The EATS Group
  |--Get Involved!
  
Since the amount of actual content is relatively small for this site, I think the history of the trails and the information on where they are should go right on the front page, along with an attractive picture.  So the front page serves a few purposes:
  1. Show a nice image to grab attention
  2. Explain what the trails are, and how they came to be
  3. Show where the trails are located
  4. Contain a menu or navigation area to link to the other pages on the site

With that in mind, we can start sketching up ideas for the main page.  And that, is the subject of part two!


Saturday, July 7, 2012

Case Study in Web Design Introduction

From an E.A.T.S pamphlet


I'm going to use this blog to document a project I am working on.  I have decided to help make a website for the Edgar Area Trails Supporters group to showcase their trail system, including the Scotch Creek Woodland Preserve.  Edgar is a small town near Wausau in Wisconsin, and the Scotch Creek Woodland Preserve is open to the public year throughout the year and is maintained by EATS, a volunteer civic organization.  Since I have visited the trails in the past and always have enjoyed them, I thought this was a great example to use as a case study in web design that can serve as a reference for my students.

This is a great example of a win-win situation, really.  Since web development has suddenly become a lot less annoying (IE, you know who you are--pun intended), I, for the first time, feel comfortable enough to make it a major inclusion into the Computer Science Curriculum at Skyline.  And for the EATS group?  Well, right now they have ZERO web presence.  All they really wanted was a page on the Edgar Village site, but, as you can see, the Edgar site looks a little behind the times on a modern browser (left margin or some padding would be nice).  The site itself, though, is (and I don't mean to be rude) in a state of decay.  The main page uses frames for layout (ouch), and many of the pages a declared as "html 2.0" for their doctype.  I mean, even Internet Explorer left html 2.0 behind a looooong time ago.  But, if you happen to have some old computer running Windows 95, at least the site will work for you.  :-)

So having a page on the village site is probably NOT going to happen any time soon, seeing as the "upcoming events" on the site are still listing things from early 2011.  So why not just get your own site, right?  Well, I understand the difficulties involved in that.  I live on the Front Range of Colorado, a place that has a pretty "techy" reputation.  Even Google has a major office within 15 minutes from my backyard.  Even here, though, you would have trouble finding someone who knows web design and development to the point where they could develop a functional site for you.  Face it--not many people know how to program computers.  If anything, we are getting dumber as time goes on, when it comes to MAKING applications.  We are passive users who want to just click on stuff and hopefully the right things will happen on the computer or smart phone we are using to access the internet.

Of course that's my job now--teaching the younger generation how to really understand and use computers--making computers do what YOU want them to do, not the other way around.   Why are we in such a sad state?  Well, lots of reasons, really, but all my evidence comes just from my observations over time, so it is hardly scientific.  I put the blame on people not being able to know themselves.  Metacognition is a lost art, and few people seem to really know what they know.  Few are aware of what they are aware of.  In that culture, you can make an easy sale by dumbing stuff down and making it seem like there is an easy way out.  Don't like writing code?  Just use a click and drag block interface!  Don't know where your music files are?  Just let iTunes synch it all up for you!  Don't know the differences between HTML, CSS and JavaScript (not to mention PHP)?  Just let Microsoft FrontPage or Adobe Dreamweaver (or the Mac equivalent that I can never remember) do all the work for you!  Yay!  Life is easy!  We're saved by technology!

Not really.  How many people do you know that have lost their music collection because they plugged in their iPod and iTunes wiped it clean?  How many people have plenty of great pdf files but have no clue how to have their Kindle or iPad display them?  In all these cases the Apples and Amazons of the world are all to happy to step in and offer their solution: just buy all your stuff from our store and we'll keep track of it for you!

So we end up at our present state, where few people know what to do when something goes wrong.  Just check out the forums for things like fixing a system crash.  Your typical Windows user will look for some free little executable program that they can click on to make everything better.  That's one way to spread malware--make it look like something that will help Window's users remove malware.  Mac users are a little different, but not any better, as a whole.  Your typical help forum for technical issues on a Mac has someone describing something bad that their Mac is doing.  Then you get 5 to 8 responses from "helpful" users who say, basically, "...gosh, I'd take it to the Mac store.  I did that and they just gave me a new one."  Great.  I'm sure that business model encourages affordable hardware.

But there is another entire world out there that is very different: free and open source software communities.  Go to the Ubuntu forums and ask for help.  Within hours (often within minutes) you will either get someone willing to help you, or at least point you to an older thread in the forums where the same problem was stated and solved.  Really, there's nothing like the support you get for Ubuntu.

And therein lies my motivation to 1) teach REAL computer science at a public high school, and 2) help the EATS group get a good website up and running.  I get to combine both of these into one, and my students will benefit from the process, along with the EATS group.

This isn't just a problem in the USA, by the way.  Here's a quote I came across recently:


Your IT curriculum focuses on teaching how to use software, but gives no insight into how it's made.  That is just throwing away your great computing heritage.

--Eric Schmidt, Chairman of Google, MacTaggart Lecture at the Edinburgh Television Festival, August 2011, on the state of CS Education in England.


Guess what?  They're teaching programming in China and India.  Real programming, not just how to create a tri-fold pamphlet in Microsoft Word.

So that's my introduction to this case study, and in the rest of the installments I will try to focus on the development process, the decisions made, and the current state of web standards.  If you made it this far, you must be awesome!



Saturday, June 30, 2012

iMac speaker buzz annoyance

I tend to use my iMac for a lot of stuff.  I dual boot Linux on it and find I use both operating systems about equally.

I recently had a strange problem start occuring when listening to iTunes: a strange buzz noise that would sound every once in a while.  At first I though maybe I had some corrupted mp3 files.  I could never get the sound to repeat at the same place on a song, though.

So I did what anyone should do when experiencing something like this: think of anything you recently did that may be caused the change.  For me, it was adding an external hard drive the day before.  However, the external drive wasn't even connected when this was happening.  Still, it seemed too big of a coincidence to NOT have something to do with the external hard drive being added.

After googling a bit, it appears that speaker buzzing is pretty common on iMacs, especially when you have a recording studio set-up with monitors and an audio interface like I do.  The problem is a ground loop issue, and some people solve it by getting rid of the ground in their outlet plugs!  Okay, I think I'll pass on that approach.  Others buy special cables to help eliminate the problem.  Others power their monitors on a different circuit.  Since my speakers already were powered on a different circuit, I was having trouble even thinking where to begin on this.

Then I got lucky.  I was looking at images of various cables on Amazon that were supposed to solve this problem.

Then I remembered something.  When I added the external hard drive, I had to unplug my Bamboo tablet.  Since I use a non-Apple mouse and keyboard, the 4 usb ports on my mac are almost always used:

  1. USB Keyboard
  2. USB Mouse
  3. USB Audio Interface
  4. USB to External Hard Drive
To make switching components easier, I used a high quality USB extension of about 2 feet so that I didn't have to reach around the back of the iMac to change components.  I had added it to the Audio Interface USB cable and would swap the interface out for the Bamboo tablet, etc.  

Removing that 2 foot USB extension solved all the problems.  Except for having to reach around to swap USB components, of course, but that I can live with.

Sunday, June 24, 2012

Human Nature has it's good parts


I don't mind if you use this image elsewhere!


Spent most of the day today getting some php scripts to work on my personal site.  While wrestling with the fact that browsers are ****ing anal, I had to do a lot of scrambling to figure out what was going wrong on the server that had worked fine on my local development server.

And of course the answers were all out there.  Not on some big PHP or SVG site, but on forums where other programmers were nice enough to help others deal with the same problem.  That reminded me of something I wrote a long time ago about copyright law and how it goes against the human nature of those in the teaching profession.  It's even in their vernacular, as they say "well, if you don't mind, I'm going to steal these plans from you and use them with my class."

That drives me nuts.  What kind of atmosphere are we in when teachers feel that way about lesson plans that they use in their classrooms?  Teachers are constantly altering lesson plans to adapt them for different students.  They are also constantly creating their own tests, activities, and examples to use with their students.  Too bad the slimeball lawyers have made everyone gun shy about doing what is natural to us: sharing with others.  Enough already.  Amen.  Break.

Of course there are excellent publishers out there that have entered the new millenium, and we need to support them as much as possible.  Also, one of my oldest complaints was about Key Curriculum posting teacher creations in Geometer's Sketchpad on their site and then keeping all copy rights to them.  Well, it appears that has changed and they now have a Sketch Exchange site where teachers can upload their sketches.  The sketches themselves are Creative Commons licensed, and you can download them even in "lurker mode."

Of course, I still use Geogebra instead, as I find it easier to use.  :-)

Tuesday, June 5, 2012

Inkscape crashing in Ubuntu 12.04 (on iMac 27")

Just thought I'd document something that was really bothering me a lot lately: Inkscape kept crashing whenever I'd try to use the "generate from path" commands.

I'm pretty good at searching for hours and finding what I need to fix something.  Since Inkscape is one of my main applications, I thought it was deserving of the attention.

After finding surprisingly little about this, I decided to try running the development version of Inkscape.  Here's how I did this.

First, I choose to use synaptic for this:
 sudo apt-get install synaptic 
Then, I had to add the development build to my sources:
sudo add-apt-repository ppa:inkscape.dev/trunk


In synaptic, check to confirm that you have the development repository added:




After uninstalling your current Inkscape, use synaptic to install the development version:



Worked like a charm.  I wish I had more to report on what was causing the crashes, but this was a problem that I spent a lot of failed attempts to fix it.  So, I was just happy to have it working again.

Sunday, May 6, 2012

Structure Synth for Generative Art



I've been messing around with Structure Synth lately, and it's a lot of fun.  The scripting language it uses is great for most of the things I want to design.  Still, there are a few situations where my students and I have not been able to make Eisen Script do what we require.  For that, what better language to use for "playing nicely" with Structure Synth than Python? 

I'm writing a Python module to help students bridge the gap between their imagination and Eisen Script. 

The image above was made during some rendering experiments I ran today.  Trying to find the right combination of depth of field and reflectivity is more fun than it sounds.

Monday, April 30, 2012

Okay, so maybe I was wrong about Unity



I just spent most of the past weekend installing and configuring Ubuntu Studio 12.04 on my 27" iMac.  The plan was to dual boot (I use REFIT) and be able to use OSX for ... well, a few of my recording studio apps, and Ubuntu for just about everything else. 

I mean, there are sooooo many excellent music production apps on Linux!  The problem, though, has long been the fact that music is the final frontier of Linux--unless you are willing to totally get into the guts of your system and do a ton of work to configure everything correctly.  Which I was willing to try!

Well, after 17 hours, I was pretty happy with my setup.  I had installed the realtime kernel and even put KXStudio on top of everything else.  I was like a kid in a candy store with unlimited funds.  There was so much excellent stuff to try out!

And it worked.  Sort of.  I had to do a bunch of stuff to kill off Pulseaudio [great current poll question: what do you hate more: Unity or Pulseaudio?], and then I had to alter config files to make sure it didn't respawn. 

It was NOT easy, but I was damn happy with the setup in the end.  I had my USB audio interface working, MIDI input was working--I turned it off and told my wife how happy I was and that it was worth it in the end. 

Today I got home from work and decided to record a guitar riff or two....

...crashes galore.  No sound at all.  Couldn't start Jack. 

I gave up. 

Since I had already switched to regular Ubuntu 12.04 (yep, the dreaded Unity desktop interface) on my laptop, I decided to just bite the bullet and go with Ubuntu on the iMac too.

Unity has improved.  Not sure if I'll get sound to work great or not, but I can always use OSX for that.  In the end I learned a LOT more about how Linux works--which is never a bad thing; it's good to become familiar with the future.

Thursday, March 29, 2012

CrunchBang on a 27" iMac

CrunchBang on 27" iMac screenshot



I think it's funny how some of the best Linux distros unfortunately gain a reputation for being "a good choice for older hardware."  What, you need a huge bloated distro to make you feel more like you're using sluggish osX or Windows?  Not me!  I like to take a smaller footprint distro, set it up in 64 bit mode, and then watch it smoke the competition.  What better way to run GIMP or Inkscape.  Want to apply a path interpolation with over 20,000 nodes?  No problem....

Now I just need to get the wacom bamboo pen working without throwig segfault errors at me.... :-/

Tuesday, March 27, 2012

Don't let yourself be hijacked by your ISP







I use Firefox, Chrome, Iceweasel and Chromium as my browsers.  One thing I have really gotten to like is simply typing search words directly into the url field on the browser.  Recently, though, my ISP has started to hijack anything that was not a working url--pushing me over to the CenturyLink Web Helper/ Yahoo page full of spam and ads. 

After trying to opt out of the service via the Web Helper page itself, I finally concluded that you can NOT opt out of the service--even if you connect directly to your modem as per their instructions.

Luckily, I use Linux and it's really easy to use Google's Public DNS service to put an end to the CenturyLink Web Helper nonsense for good.  I just followed the instructions on the Google page itself and had no problems.  Haven't tried this yet on a Mac, but will soon.

Now, when I type "frogs" into the url field on Firefox I get this:



Sooooooo much better!

Monday, March 26, 2012

Think Complexity by Allen B. Downey


Yesterday I picked up a physical copy of Allen Downey's new Python book Think Complexity.  Allen does a great job on both fronts in this book, presenting key topics in Complexity Science and also clear Python code.  

Last year some students and I worked on a Genetic Algorithms case study that was inspired by Melanie Mitchell's book Complexity.  Our work on the case study was NOT for any course and NOT for pay or credit in any way.  It was "just for fun", and we learned a lot together.  But... since Allen is looking for Case Study submissions, we just may be resurrecting the Python code we wrote and submitting a new chapter for the next edition of this great little book.

Sunday, March 11, 2012

laissez-faire cuts both ways



I got hacked.  Well, not really--but nowadays whenever something bad happens people say things like "I got hacked."  What happened was that I host a Creative Commons wiki and a Bulletin Board on a shared server with Dreamhost.  I have been very happy with Dreamhost for the past several years, and I think we have to appreciate what we get all the time--not just get angry when something bad happens. 

I don't know a lot about the Dec 29th hacks that tried to install backdoors in every php file in the directories (and sub directories) of two applications I had installed using the easy 1-click installer.  I know the blame has been on Wordpress, but the actual damage done was ... well, minimal.  Besides altering a bunch of php files and attempting to create a few HTML forms for gaining access to other parts of my site, not much else happened.  I was planning on moving the Creative Commons site to a dedicated server anyway, so in a way this was almost refreshing.  Also--I tend to have a soft spot for hackers--real hackers, not script kiddies, mind you.  This was more like the work of script kiddies cutting and pasting some php code than true hacking, of course, but that's not what really matters.

What does matter is that we keep things in perspective.  Although I grumbled about it at the time, I did learn a lot the last few nights as I ssh'd in via Linux terminal and worked on cleaning up the mess.  [Basically I grabbed all the media and got rid of the php files.]  At times, when I was researching this intrusion, I came across long and heated arguments about how this was Dreamhost's fault.  That made me a bit angry, and here's why:

I chose Dreamhost back when a lot of suckers were choosing GoDaddy or other hosts that 1) offered little ability to access the unix terminal to mess around with the guts of your account on the server, and 2) made you believe you owned the domain name you registered through them, when you did NOT. 

I chose Dreamhost because they appeared to be one of the most Python-friendly and Linux-friendly providers around.  I remember emailing them a few questions about using server-side Python scripts, and terminal access to my home directory.  They were very honest and helpful every time I had a question.  I have had no problems with them in four years now--until the Feb 29th thing.

But, you need to be honest with yourself when something like this happens.  First of all, Dreamhost is not the only victim that this happened to.  Also, you can't have your cake and eat it too.

For years I was frustrated by not having more admin rights from our district in my computer lab.  At times it got so annoying that several students and I ended up just booting into Linux on a stick rather than deal with a crappy setup that we could not customize for our needs.  Those days are past, though, and I now have full admin rights to every machine in my lab.  What caused the change?  I had to work at it for a long time, trying to build up positive connections with the district tech department.  Eventually we realized that giving me admin rights was a win for both sides--but I had to fulfill my end of that bargain.  I clearly told them, over and over, that I would handle all the troubleshooting and maintenance of the machines in the lab, and (most importantly) if we broke something, we were responsible.  Turned out that they liked the arrangement, and it continues to this day.  In the past two years I have had only one problem that I had to have help with--an iMac monitor that had a flaw in it that was apparent only a day after we got it.  Other than that, I have not had to ask for help installing software that runs on X11, or needed their help in finding lost files or troubleshooting software problems.

I see Dreamhost along the same lines.  They're a host that lets you mess around with the terminal, use version control, write your own CGI scripts--and so on.  So I was a little upset at clients that immediately started badmouthing Dreamhost and threatening that they were going to take their business elsewhere.  Typical human reaction, of course, but typical is pretty sucky when it comes to societal norms.  I'm still with Dreamhost.  My nightmare would be having them come out and change their policy in order to make us all "safer."  That would cause me to leave.

Friday, March 2, 2012

Arrrgh -- me tresure map to me code, scallywags!



Just purchased a new copy of yet one more book I had already downloaded as a pdf file.  I buy so many programming books that it appears I'm stuck in recursion with no base case in sight....

Wednesday, February 22, 2012

Oh Hey, THIS makes me wanna buy corporate music and videos!



Got a warning about a video I put on Youtube.  Used a template in iMovie and I'm 100% sure that I did NOT violate any terms of copyright.  Googled it and found out this is really common.  Still--wtf?!  This kind of shotgun spraying hits innocents like me and simply makes me want to embrace the cold and impersonal world of BIG MEDIA COMPANIES.  I don't know about you, but I sure feel like running out and buying a mp3 after getting this email.  ;-)

Next thing you know they'll copyright the act of flicking a booger onto a wall.

Tuesday, February 21, 2012

Holy Crap--New Life for an old Aspire One



I got my Acer Aspire One back in the good old days when it appeared that Linux was going to dominate the newly emerging netbook scene.  Of course that never happened for various reasons.  I won't go into that--but when Microsoft decided that they needed to dominate the netbook market, they also managed to annihilate the netbook market.

My Aspire One is one of the first ones made.  It came with Linpus Linux, which was pretty horrible.  The first thing I did was to unlock the hidden advanced features of the desktop.  The second thing I did was to start trying other Linux distributions in search of one that would make me happy.

I found Ubuntu's netbook remix to be too slow.  Although I had flirted with many other distros, I ended up using an Ubuntu alternate install cd and went the geeky route of installing no GUI desktop.  My plan was to use it for ssh-ing to a server, and also for programming CLISP and Python (using Vim).  The only problem was that I couldn't get the darn wifi to work right, so I had to be plugged in right next to my desktop.  Obviously NOT the best setup for a netbook.

So recently I started thinking of this little Apsire One as I was wrestling with dual booting Linux on my Macs.  What is so amusing about installing Linux is that some things that are difficult to get to work in some situations (wifi, sound, etc) are surprisingly easy in others.  I simply wasn't using the Aspire One, and I felt a little guilty about that, as I had such high hopes for Linux Netbooks.

So a couple years went by, and things changed a lot while I wasn't looking.  I had used CrunchBang on the Aspire One quite a while ago and thought it was pretty impressive.  I don't recall why I moved away from it, but I do remember that CrunchBang was pretty new at the time.

Last night I downloaded the CrunchBang iso file and put it on a USB stick using some excellent guide I found through a Google search.

This morning I installed CrunchBang with no problems.  Everything works, and I was happy to see my favorite text editor Geany already installed for me.  Writing this blog post was surprisingly easy, especially considering how clunky Linux can feel on newer Mac hardware.

Thanks CrunchBang!

Monday, February 20, 2012

Linux Mint: I sense a strange disturbance in the force...



I have chosen to NOT address the whole Ubuntu Unity desktop controversy, for several reasons. 

First of all, I tend to be pretty liberal and embrace change.  First impressions are often flat out wrong, and nothing bothers me more than people who won't even give something new a chance.

Second, I have heard very good things about Unity from people that I respect.  That DOES mean a lot to me, and by no means have I written off Unity altogether.  In fact, I recently installed Ubuntu (with Unity) on a Macbook Pro 6,2 and I'm really trying to get used to it. 

That said, I can't help but feel as if there is a major shift going on here, in the world of popular Linux distributions.  I don't remember exactly when Mint passed up Ubuntu on the page hit rankings on distrowatch, but it sure seems like the times they are a changin'.

So today I burned my first Mint DVD.  Like any Linux user, I have drawers full of all sorts of old Linux cds.  Some of those helped me get out of a mess in the past, and some opened the world to a new distribution.  Some failed so miserably that I couldn't even get them to boot up, but that's a different topic.

Sunday, February 5, 2012

Major GuiltTrip Reporting for duty!



It's tough, really.  With all the recent SOPA stuff (I was firmly on the side opposing SOPA) there has been a lot of meditating, contemplating, and half-assed rants about the whole piracy and intellectual property rights mess.

So I found a copy of Free Ride by Robert Levine at the local public library and decided to check it out.  It's well-written, if not all that convincing.  Nonetheless, I can't help but wonder what Robert Levine would think about the fact that I checked this book out for zero cost at a public library.  The heart of the issue is so much more complex, isn't it?  I mean, there are books at the library that I would gladly spend 5 or 10 bucks to "rent"--and then there are books like this, that I came across almost by accident and decided to check out.

There are books I have checked out from the library that I have subsequently gone on to buy (Visualizing Data being the latest).  I just prefer to sample stuff first.

Monday, January 30, 2012

Silicon Valley's Secret in the Modern Classroom

Just read this great article, and now I'm simply making a note of this as something to consider for implementation in the classroom.

Might work for some of my CS classes.

Saturday, January 21, 2012

On Choosing a Web Application Framework



The Skyline MAD Team (Mobile Apps Development) has produced 3 working apps from scratch, using HTML5, CSS3, a little JavaScript and some PHP.  During the process, students noticed that we could re-use certain parts of our code between the apps.  Of course this meant that we did a LOT of copying and pasting of code from computer to computer--not the best development situation by any means.

We had looked briefly at a form-based web application framework that we experimented with.  To their credit, my students felt uncomfortable NOT being able to see all the parts of the framework.  We also had little knowledge about which database was being used, etc.

So it didn't take long for some of my Python hackers to write up a couple helper scripts that would lead the user through making HTML forms.  Python did all the work pasting the proper tags around the content.  The only problem was that we found ourselves having to tweak the HTML later on because we were using JQuery Touch or some other toolset.

We like PHP, but it is not our go-to language for scripting--that would be Python.  Although I'm not currently teaching a Python course at Skyline, Python is still the most popular language choice from my top programmers.  So, with 10 minutes to go before I had to leave for an eCSite meeting in Boulder, one of my students, tritan67, asked if we could update our server's Python installation to include something newer than the 2.4 that CentOS uses internally.  I started to say, "no, I gotta go, so maybe tomorrow...", but when it comes to Computer Science, I almost never take that approach.  So instead I said, "What the hell, let's do it!"  The next 10 minutes saw us googling stuff, downloading Python source code, and finally installing Python 2.6 alongside the 2.4 version on the server--compiling it from source.  After all the recent debugging frustrations with the MAD Team, it was like going home again when the Python installation "just worked."

I'm still a bit surprised how easy it was.  Not only did we get 2.6 installed from source, but tritan67 jumped onto a terminal, wrote up a helloWebWorld.py and we confirmed that it was all working.

That was such a good feeling, that we started to immediately look for ways we could write our own framework using Python CGI scripts.  But--since there are more Python web frameworks than there are programmers--we figured we'd look into something like web2py or Django.

Haven't decided yet what we'll settle on, but it looks like either Django or the Google App Engine will be where we take this.  Of course I'd just prefer Django on our own server, but there's something to be said for the Google App Engine as a platform for teaching students how to make web apps.

Back to coding.  Python, we missed you a LOT.

Monday, January 16, 2012

SOPA is a bad idea

I was happy to read today that Wikipedia will be blacking out this coming Wednesday in protest of the SOPA legislation that I hope you have been hearing a lot of outrage about. 

In fact I was so happy that I made a donation to Wikipedia just minutes after getting the good news.