Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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
[proto] Ported SimpleCopyPaste transform #6451
[proto] Ported SimpleCopyPaste transform #6451
Changes from 3 commits
17866a2
eb087d6
dce3a29
9a52b8b
1fa9a29
541b3d3
430f16e
ec770d7
3c7a9cd
cf6e028
1b22f32
902e0f2
fc73a88
File filter
Filter by extension
Conversations
Jump to
There are no files selected for viewing
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.
As our input is a non-collated batch of datapoint, we need to fetch images, bboxes, masks, labels.
We then transform them and finally put into their places.
I'm not a fan of this code but this helps to do what we want. Maybe we could specify a bit more the input structure and thus code
forward
in a more elegant way.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.
Can't we save these indices the first time we iterate over the flat sample? If yes, maybe we can get away with only doing
flat_sample[i] = output[i]
and only looping over the output.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.
yes, we can do that. I just found that passing indices everywhere would be a bit bulky...