-
Notifications
You must be signed in to change notification settings - Fork 18.7k
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
Non-square cropping #1980
Non-square cropping #1980
Conversation
This is a great addition. Small suggestion: I think it's a good idea to add in some checks (in the
(this was adapted from checks done in the convolution layer https://github.com/BVLC/caffe/blob/master/src/caffe/layers/base_conv_layer.cpp#L16 ) |
@seanbell Tahnk you for your suggestion. |
This is very helpful for Deep Learning work on non-CV fields . Any chance that it could be merged soon? |
I am working with 1d time series data and a 1d crop could be very useful. I am wondering if this change would be merged? |
} | ||
cv::Rect roi(w_off, h_off, crop_size, crop_size); | ||
cv::Rect roi(w_off, h_off, crop_h, crop_w); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think the crop_h and crop_w are swapped.
👍 |
Can this non-square crop be implemented using the ND crop layer as in #3570? |
Closing as better handled by a Python data layer. Thanks for extending crop, but I think including all these varieties of augmentation adds too much code which is more clearly expressed in Python anyway. |
Add
crop_h
andcrop_w
toTransformationParameter
.This PR is implemented similar to h/w kernel size.
Related issue: #1834