Grasshopper

algorithmic modeling for Rhino

...but I'm holding on.

The Challenge is to read the tidal height using this graph:

The vertical axis scale is:

0 - 5m

and the Horizontal axis is:

31-Dec-2011 00:00:00 to 3-Jan-2012 00:00:00.

Specific time:

1-Jan-2012 13:51:30

..............................

For those who did not see my previous Question you can use the attached user component to change the date and time into a more usable format.

..............................


I know of two very different methodologies. But as ever with GH I would like to see more :)

Views: 668

Attachments:

Replies to This Discussion

This seems to work pretty well. Not super accurate just because of the .png's resolution.

Attachments:

Ah, noticed a mistake. Here is my revised reader.

Andrew, I got a (slightly) different value than you (3.18m). I wonder if I made a mistake or if it's just the method that I went about reading the png (color hue). 

I guess the thickness of the line is counted toward the total, maybe that's it.

Attachments:

Here's an alternate method. Same value though (3.18)

9 components not including panels

Attachments:

Well it won't win any beauty contests...

I'll go on the record with my specific-time solution at 2.87m.

Attachments:

When I do the job manually in rhino, drawing lines on top of the image, dividing, measuring, I wind up with something very close to my value. 

If you look at your "Find similar item" component, the value it's finding is actually a white rather than a blue pixel... perhaps that has something to do with the discrepancy? Converting your colors to points before passing them through returns 2.9 in the final measurements. 

Ah gotcha. I thought the find similar component would take each of the three components of color into account, looks like it doesn't. Good call with the point conversion. 

So thanks to Andrew, here's a (much more accurate) version with 11 components not including panels. 

Attachments:

nice, very elegant and clean solution. 

Very nice indeed, I think Brian you are the winner, with a meritorious assist for Andrew for pointing out the follies of your method along the way. :)

For completeness I'll try and post my definition at lunchtime today if I get a chance. 

RSS

About

Translate

Search

Photos

  • Add Photos
  • View All

Videos

  • Add Videos
  • View All

© 2024   Created by Scott Davidson.   Powered by

Badges  |  Report an Issue  |  Terms of Service