| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
Sorry, something went wrong.
Improve the performance of DEKR predictor. Use advanced indexing instead of for loops and remove TODO.
There was a problem hiding this comment.
The refactoring looks great — the vectorized version is much cleaner.
I’ve run the full integration testing suite on my side, and everything passes without issues. Nice work on this improvement!
Sorry, something went wrong.
There was a problem hiding this comment.
I ran the code step-by step and confirmed that evaluation results are close to previous implementation. The vectorization looks great, also happy that you added the tensor shapes in the comments. Looks all good to me!
Sorry, something went wrong.
This commit updates the DEKRPredictor to follow the DeepLabCut implementation in version 3.0.0rc13. see DeepLabCut/DeepLabCut#3121
* DEKRPredictor: add non-maximum suppression (NMS) This commit Updates the DEKR predictor to follow the DeepLabCut implementation in version 3.0.0rc7, see DeepLabCut/DeepLabCut#2907 * DEKRPredictor: speed up with vectorized operations This commit updates the DEKRPredictor to follow the DeepLabCut implementation in version 3.0.0rc13. see DeepLabCut/DeepLabCut#3121 * PartAffinityFieldPredictor (PAF): Speed up cost computation This commit updates the PAF predictor to follow the DeepLabCut implementation in version 3.0.0.rc13. See DeepLabCut/DeepLabCut#3117 * HeatmapPredictor (single animal): speed up with vecorized operations This commit updates the `HeatmapPredictor` in single_predictor.py to follow the implementation in DeepLabCut 3.0.0rc13. See DeepLabCut/DeepLabCut#3110
| Back | FazBrowse Home | New Git URL |
Summary
This PR improves the performance of DEKR predictor.
Details
Profiling the DEKR predictor's forward call, shows a significant increase in speed. But the overall inference time of the architecture remains mostly unchanged (very minor improvements) since it is largely dominated by HRNet and torch native modules. (thanks to @maximpavliv for running the benchmark)
Below shows (the rectangle in blue) that most of the inference time is spent in the HRNet and PyTorch native inference procedures.
I have optimized the rest of it (the rectangle in red) as much as I could.