Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SegDataGenerator questions #22

Open
ahundt opened this issue May 20, 2017 · 2 comments
Open

SegDataGenerator questions #22

ahundt opened this issue May 20, 2017 · 2 comments

Comments

@ahundt
Copy link
Collaborator

ahundt commented May 20, 2017

Questions by @mptorr in keras-team/keras#6538 (comment)

I was going to try your SegDataGenerator however wanted to ask 2 things about it, as they may pertain to your request for features/suggestions:

[1] it appears it currently does not support pixelwise weighting to compensate for class imbalance. This would be an important feature to me, as most of my segmentation tasks will have disproportionately over/under-represented classes. Currently I balance classes using Keras' sample_weighting as temporal, however without data augmentation due to my issues above. Since the sample weighting matches each pixel in the image/mask pair, it would need to be appropriately transformed to match augmented images/masks. Let me know if I'm overlooking this feature in SegDataGenerator.

It isn't there yet unfortunately. Suggestions/pull requests are welcome.

[2] I'm a bit confused on how SegDataGenerator loads images. The comment in the class perhaps could be reworded (or have examples) for the most important arguments. I also didn't understand how to use this info: for a file name 2011_002920.jpg, each row should contain 2011_002920. Of course, this lack of understanding may reflect my own limitations, but just thought it could help development.

SegDataGenerator expects the data to be in pascal_voc format, since the images are in jpg and the labels are in png the authors decided to put neither in the dataset list txt files. If you walk through the process in the README.md you'll end up with a folder properly set up for running which makes things much more clear.

@Fahim-F
Copy link

Fahim-F commented Jul 13, 2017

Hi
My work is semantic segmentation. if I want to increase the number of the images that my network can see, (something like data augmentation), is there any prepared code for doing this?
Something like the "ImageDataGenerator" of the keras does.

@Zundock
Copy link

Zundock commented Apr 16, 2018

Is this still needed? or have the features of SegDataGenerator been implemented into the Keras ImageDataGenerator?
I am doing an implementation of U-net for semantic segmentation and was hoping to use the Keras ImageDataGenerator. Then I can across this repo and it is the first I read about the Keras ImageDataGenerator not handling segmentation.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants