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

Add augmentors to chip classification #859

Merged
merged 7 commits into from Nov 19, 2019
Merged

Add augmentors to chip classification #859

merged 7 commits into from Nov 19, 2019

Conversation

lewfish
Copy link
Contributor

@lewfish lewfish commented Nov 18, 2019

This PR adds augmentation options for PyTorch chip classification using the albumentations library.

I tested this by using the ToGray augmentation on a sample chip classification experiment and saw that some of the debug chips were greyscale.

This supercedes #851

Connects #831

lmbak and others added 6 commits Nov 18, 2019
Added ToNumpyArray transform for compatibility with Albumentations

Finished preliminary implementation of albumentations augmentors

Added more augmentors

Fixed the to protobuf for the augmentors

Fixed typo

Changed return value for the mock augmentor

Updated changelog.rst

Cleaning up of some imports and requirements

Cleaning up code
Added ToNumpyArray transform for compatibility with Albumentations

Finished preliminary implementation of albumentations augmentors

Added more augmentors

Fixed the to protobuf for the augmentors

Fixed typo

Changed return value for the mock augmentor

Updated changelog.rst

Cleaning up of some imports and requirements

Removed unneeded import

Removed another unneeded import

Added augmentor description

Added missing ']'

Style fixes
We want to be able to use the augmentations with any Dataset
without having to alter that Dataset
@lewfish
Copy link
Contributor Author

lewfish commented Nov 18, 2019

@lmbak I made some changes to get this over the line faster. The main change is that I created an AlbumentationsDataset adapter which makes it so we don't need to make any changes to the original Dataset.

@lewfish
Copy link
Contributor Author

lewfish commented Nov 18, 2019

Also, I made it so the validation dataset doesn't have any data augmentations applied to it. This is a best practice that reduces the variance in the validation metrics from one run to the next.

@lmbak
Copy link
Contributor

lmbak commented Nov 18, 2019

Great! Thanks for the feedback. In line with your comment I'm assuming that oversampling is also not applied to the validation set, I'll fix that in the corresponding PR.

@lewfish lewfish merged commit 39d21f3 into master Nov 19, 2019
1 check passed
@lewfish lewfish deleted the lf/aug branch Nov 19, 2019
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

Successfully merging this pull request may close these issues.

None yet

2 participants