c42f/displaz

Manual classification of points

Opened this issue · 5 comments

c42f commented

Eric has asked that points can be classified by hand (and the results saved into an output file). This seems like a good idea - probably want to be able to lasso them with the mouse from various directions to add/remove points. It may be a good idea to take cues from the various mask tools in gimp.

c42f commented

Some initial work has been done in c1113a3. Needs UI polishing though, since it's not very easy to use.

A screen-coordinate convex polygon corresponds to a world-space convex solid region (use plane equations for inside/outside test) if combined with near and far viewing places. Intersecting two or more of those from different viewing directions ought to work well.

c42f commented

Hi Nigel, you're quick off the mark!

I think there's a few semi-distinct problems to be solved here:

  • Make a 3D selection UI which is nice to use. My work on the selection branch used a sphere, but to be honest it sucked, which is why it never got merged. If you grab the example data I sent and try to classify a roof next to some trees, you'll see what I mean (spacebar to select, ctrl+RMB to scale sphere, ctrl+LMB to move sphere, t to toggle selection class). I don't have strong feelings about what exact method should be used here, so feel free to prototype. I do want the final result to involve minimal new UI elements and be easy to use (perhaps it's a selection mode which is off by default).
  • Figure out how to save the points back to a file. I guess this is a tedious but straightforward use of laslib.
  • Extra: decide how multi-class classification is going to work. In the branch, there's only two classes and you can toggle between them, but the underlying code is already set up for multiple classes.

To give you a bit of background, the aim for this feature is to manually classify areas to create training sets for machine learning problems. This is why it makes sense to have in a developer tool.

c42f commented

By the way, the selection branch is pretty stale. I'll try to rebase it onto master now.

c42f commented

I rebased the selection branch onto master so it should compile easily. I'd basically forgotten the hacks I'd put on there, the code's not entirely pretty, but it does work.