ImageMonkey / imagemonkey-core

ImageMonkey is an attempt to create a free, public open source image dataset.
https://imagemonkey.io
47 stars 10 forks source link

fisheye images / undistorted versions #105

Open dobkeratops opened 6 years ago

dobkeratops commented 6 years ago

So now I wish I got a regular camera for the stills (the spell of good weather is over) The fisheye images have their use (hence their choice in actioncameras) but some people are going to require regular images (especially for extracting textures), although overall I think they should be fine for neural net training (knowing about the maxpooling distortion approximations they do..)

At the same time your site is scaling things to 1024 wide. The original stills are 3200x2400, but not all of that is useful resolution (quite fuzzy zoomed in).. infact I dont think you lose much salient detail at 1024. I'd guess the useful resolution is around 1600.

I wondered if there would be any point in submitting the centre part of the image undistorted, at 1024 wide - the hazard being 'asking people to label the same things twice' (which is a big waste of user time).

To conclude, I wont do these uploads, but I'll show you what I was trying. You'll need to click to see the full resolution images on this GitHub forum to see the fine detail (What it might be worth doing is making the full original resolution available for images with annotations? or it might be worth replacing some with uploads of the undistorted versions? - I imagine loads of the submissions are still in 'quarantine')

[1] remove the fisheye effect (GIMP filter) effectively giving a flat 170degree image [2] crop the centre half in x/y, removing a lot of the sky/ground and skewed areas to the side. [3] rescaling that to 1024

Not sure there's much useful additional detail, but looking at the faces and license plates, it's possible there is some - plus the lines at the edges are straighter - look at the horizontal road line

However, it's not much different from just taking the centre half of the original (the fisheye effect is not so extreme in the middle).

here's the two areas of interest side by side - the middle from the image you'll have on the site already, and a 1024-wide middle from the straightened image:-

comparison

The original image:- 20151009_000113

Here's GIMP's lens distortion straightening it out:-

corrected_street

Finally here's just the middle 1024-wide region from the original image.. again you can see the horizontal line bending toward the edge.. but it's not so severe

fisheye_middle_1024

The only thing I would conclusively recomend is making sure a user can filter the fisheye images out (maybe you could add tag filtering to your browser view.. a feature which would have a lot of other use)

There might even be a point to trying 'cylindrical distortion' (i.e. a 170degree subset of a horizontal panorama) and finally imagine splitting the 170degrees into side by side 2x 85degree images un-distorted (I really need to draw a diagram of the 2 regions that would get to explain that better..)

bbernhard commented 6 years ago

Cool stuff! I wasn't aware that GIMP is capable of doing that. Do you need to specify some parameters to the GIMP filter or does it work without ones? I am wondering whether it would be possible to automatically correct the distortion (in the backend) and if we should do that. Or are there use cases in the image processing/machine learning universe where a fisheyed image is superior to a normal image?

The only thing I would conclusively recomend is making sure a user can filter the fisheye images out (maybe you could add tag filtering to your browser view.. a feature which would have a lot of other use)

Definitely! Out of interest: Have you looked at the EXIF information of your images? I am wondering if there is some information in there to detect fisheye images.

dobkeratops commented 6 years ago

Do you need to specify some parameters to the GIMP filter or does it work without ones?

yes you have to set a couple of parameters ..roughly '-38..-45' on the main slider seemed to do it, but there's further opportunity to refine that with a seperate 'edge' value

(I wonder if someone somewhere has trained a neural net to figure that out..)

Or are there use cases in the image processing/machine learning universe where a fisheyed image is superior to a normal image?

All I can say is agree with your point that storing raw data is helpful. I'm guessing the wider FOV could be useful for navigation (drones etc) although in practice you might use multiple cameras offset (like I see on that starship delivery-bot).

Maybe having it aware that it's fisheye and orientating bounding boxes aproximately would be interesting.. (conversely you could just default to a 'fuzzy-ellipse' tool as we talked about elsewhere..)

I need to figure out how GIMP 'script-fu' works to do batch processes

Have you looked at the EXIF information of your images?

no idea.. i'll google

dobkeratops commented 6 years ago

Perhaps it would be possible to allow image replacement, to keep the full resolution of the fisheye originals ... or just allow linking the originals to ; Then if someone needs to straighten, they can. (downressing then straightening definitely loses more, hence the data in it's current form will discourage some users).

or perhaps some kind of 'image association' would be possible to give the full resolution in the centre region , linked making it clear that when you annotate one it maps directly onto the other

The original files are about 1.5mb each; I dont know what your hosting limits are. I see the site is up to 12000 donations, which would be about 18gb at that size, I guess the next milestone would be 20,000 images ..