-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
Added new augmentation methods and the option of augmentation by addition instead of replacement #653
Merged
Merged
Added new augmentation methods and the option of augmentation by addition instead of replacement #653
Changes from all commits
Commits
Show all changes
89 commits
Select commit
Hold shift + click to select a range
17065c5
NOTEBOOK FOR DATA AUGMENTATION
xaviersantos 0b243c8
SMALL SAMPLE DATASET
xaviersantos 852f049
TRANSLACTIONS GLOBAL AND LOCAL
xaviersantos 39e957f
LOCAL AUGMENTATIONS FINISHED
xaviersantos c85634b
ADJUSTED DATA FORMATS TO PCDET YAML COMPATIBILITY
xaviersantos 5b57485
BUGFIX
xaviersantos c95313e
ADDED TITLES
xaviersantos fcc16c5
ADAPTED OPENPCDET TO FIT NEW AUGMENTATIONS
xaviersantos bf49660
SAVE IMAGES OF THE DATA AUGMENTATION EXAMPLES
xaviersantos 58692d7
LOCAL TRANSFORMATION RANDOM VALUES VARY WITH OBJECT AND NOT SCENE
xaviersantos 4cdfd92
FIXED YAML
xaviersantos 005b48e
FIXED BUGS IN PARAMETERS
xaviersantos c153789
FIX IN LOCAL BOXES
xaviersantos d61277d
NEW BOX FILTER
xaviersantos f244993
FRUSTUM DROPOUT
xaviersantos 2f5270f
FRUSTUM DROPOUT IMPLEMENTED ON OPENPCDET
xaviersantos c20c448
REMOVE FIGURES FROM VERSION CONTROL
xaviersantos c1e9e5d
MORE EFFICIENT LOCAL METHOD
xaviersantos 7f1f088
LOCAL TRANSFORMATION WITH NUMPY SPED UP
xaviersantos 2736850
BUGFIX ON AUGMENTATION FUNCTION
xaviersantos f55055d
GET PREDICTED LABELS
xaviersantos a44e6b6
AUGMENTATION DONE BY ADDITION
xaviersantos 57d5b37
RANDOM SELECTION OF REMAINIG FRAMES
xaviersantos d07eb76
LOGGER WITH TRANSFORMATION DETAILS
xaviersantos 78cdb44
CHANGED COUNTER TO SAMPLE IDX SELECTION METHOD
xaviersantos be1cfde
BUGFIX ON KITTY_DATABASE
xaviersantos def3c5c
BUGFIX
xaviersantos 7c71e94
Merge branch 'dev' of https://github.com/xaviersantos/OpenPCDet into dev
xaviersantos a906ece
BUGFIX
xaviersantos 51e90a6
FIX ON GENERATOR
xaviersantos fe0180c
DEBUG LOGS TO FILE
xaviersantos 193010e
FIXED LOGGER
xaviersantos 8017f64
SAVE POINT CLOUDS TO OBJ FILE
xaviersantos ae7b228
UPDATED NOTEBOOK
xaviersantos e827761
CLEANUP
xaviersantos 1610864
.gitignore is now working
xaviersantos 90b2811
fixed .gitignore
xaviersantos a20816f
REMOVED YAML FILES FROM .gitignore
xaviersantos 575ea35
parse results to a csv
xaviersantos 615d43d
yaml changed
xaviersantos c6e6bba
fixed gitignore
xaviersantos c3cc6fc
Merge branch 'dev' of https://github.com/xaviersantos/OpenPCDet into dev
xaviersantos 8d99396
FIXED BUG THAT DUPLICATED THE TEST SET
xaviersantos 765eb93
small fixes on yaml
xaviersantos ad8f7ca
fix gitignore
xaviersantos 7139a59
updated generate_sets.py
xaviersantos a5f2cc9
fixed csv_parser.py
xaviersantos 68b2e53
Delete output directory
xaviersantos 97e7d5e
Delete output directory
xaviersantos dbe3ab3
saving figures with better resolution
xaviersantos 3e70520
implemented a way to chose to augment the raw pcs
xaviersantos 3679d3f
updated csv_parser.py
xaviersantos 0945547
Merge branch 'dev' of https://github.com/xaviersantos/OpenPCDet into dev
xaviersantos 27326dc
fixed yamls to include the new selection system
xaviersantos 1ca2d19
notebook updated
xaviersantos fabd838
Merge branch 'dev' of https://github.com/xaviersantos/OpenPCDet into dev
xaviersantos 75c2014
mosaic added
xaviersantos c74f6c6
new models
xaviersantos 3eb969b
fixed gitignore
xaviersantos c176d46
fixed gitignore
xaviersantos ec8a112
applied changes
xaviersantos 82be976
Merge branch 'master' of https://github.com/xaviersantos/OpenPCDet
xaviersantos c60b53d
Delete data_aumentation.ipynb
xaviersantos 0859079
Delete pointpillar_fullaug.yaml
xaviersantos e4727de
updated gitignore
xaviersantos 94bd8f6
Merge branch 'master' into dev
xaviersantos 9dae743
bugfix
xaviersantos 6623a16
Merge branch 'dev' of https://github.com/xaviersantos/OpenPCDet into dev
xaviersantos 0c4cd7e
updated training and notebook
xaviersantos 585072c
Merge branch 'dev' of https://github.com/xaviersantos/OpenPCDet into dev
xaviersantos 5fa4acc
updated gitignore
xaviersantos b98711f
cleanup code
xaviersantos 4bdf3d6
updated yamls
xaviersantos 6c85734
Merge branch 'dev'
xaviersantos 0794d5c
reset
xaviersantos 39e9c52
Merge branch 'master' of https://github.com/xaviersantos/OpenPCDet
xaviersantos eeb9ffa
Merge branch 'master' of https://github.com/xaviersantos/OpenPCDet
xaviersantos 976d5bb
new augmentation methods
xaviersantos c5eedbd
example conf for pointpillars
xaviersantos f0b2e06
updated example config
xaviersantos 099dcc1
bugfix on the config file
xaviersantos 887f8a2
fixed get_points_in_box function
xaviersantos 3c8c5d5
fixed local frustum dropout
xaviersantos bdbe9b6
fixed pointpillar_newaugs.yaml
xaviersantos 5a7a8df
bugfixed: import math for some augmentations
sshaoshuai 1a0f213
Merge branch 'master' into xaviersantos-master
sshaoshuai 3db5c1b
increased margin in point selection for local augmentation
xaviersantos 6896834
bugfixed: velocity should not be translated for translation augs. Add…
sshaoshuai 46bc7f7
bugfixed: add back the aug of random_image_flip
sshaoshuai File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
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.
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.
Is this right?
Since you do not consider the orientation of gt_box, so simply checking the points with (xyz, dxdydz) may return wrong points.
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.
The results were visually validated using this tool: https://github.com/xaviersantos/OpenPCDet/blob/dev/data_augmentation.ipynb
Here are some images taken from these augmentations (the magnitude of the transformations was exaggerated for better visualization):
Original image:
Local Translation along Y:
Local Rotation:
Local Scaling:
Comparing the results of the new augmentation methods with the ones already implemented, these were the improvements:
These models models were trained for 80 epochs keeping all the same default hyperparameters.
As for the orientation of the gt_boxes, it should have no influence on the selection of the points inside its bounds (function get_points_in_box), as the center of the box and its dimensions are enough to the describe all the points within the box.
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.
The performance looks good!
But I still do not understand why you do not need to consider the orientation.
Simply checking the center+dimensions of boxes for selecting inside points should only work for boxes with heading_angle=0.
What would happen when you conduct this function for a gt_box with heading_angle=pi/4? I think the inside points could not be well selected by this function since the gt_box is oblique.
Actually I have implemented a function to select inside points from a rotated box (https://github.com/open-mmlab/OpenPCDet/blob/master/pcdet/ops/roiaware_pool3d/src/roiaware_pool3d.cpp#L121-L140), could you comment on the difference between your function and my function?
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 see what you mean and you're right.
I've fixed the get_points_in_box function using a numpy logical mask based on your code, as well as the local frustum dropout functions which had the same mistake.
The results were validated visually in scenes with objects in oblique positions and everything seems to be working as intended. I couldn't, however, train a model with this new fix to see if there are further improvements in performance yet, because the workstation I've been using for training is currently unavailable.
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.
Great! Thank you!
I will try to train with your config and get back to here soon.
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.
@xaviersantos I find a function
points_in_boxes_cpu
implemented in./pcdet/ops/roiaware_pool3d/roiaware_pool3d_utils.py
similar with your vesionget_points_in_box
. I would like to know why you don't use it.