I'm trying to get my mind wrapped around Mathematica's image feature recognition functions. I'm intrigued by the ImageLines function for a couple future ideas I have but generally get very poor performance from it.
...as I will now demonstrate:
Let's import some very basic gridlines, surely this will be easy.
pic = Import[ "http://www.samplewords.com/docthumbs/home-graphpaper-thumb.jpg"] 
Straight out of the box, here's how Mathematica recognizes the lines at different thresholds (parallelized because of my impatience):
Row@ParallelTable[Graphics@Line@ImageLines[pic, i], {i, .1, 1, .1}] 
Interesting... not what I would've expected.
Even if I dilate and binarize the image, I still get pretty bad results:

Playing with the distictness parameter, it gets a little better but still pretty weird.

So, Wolfram shows some pretty neat examples, and it seems to work well there.
How can I get improved results from the ImageLines function?





