OpenVSLAM uses too much CPU #73
-
Have anyone tried using OpenVSLAM in RGBD mode? I tried to use it with Intel Realsense D435i. it uses CPU like 1000%, which I find it weirded. Have anyone experience the same issue? |
Beta Was this translation helpful? Give feedback.
Replies: 6 comments 9 replies
-
Are you running on Windows? I have seen some heavy CPU use when using the g2o library on windows in multi-threaded mode. |
Beta Was this translation helpful? Give feedback.
-
Can you post the output of the |
Beta Was this translation helpful? Give feedback.
-
I'm interested in the following
|
Beta Was this translation helpful? Give feedback.
-
If you have built g2o with |
Beta Was this translation helpful? Give feedback.
-
One other reason you see a high CPU-usage might be because OpenCV will try to use all available CPUs for processing. Your machine has a lot of CPUs (40) where this parallelization might not be that efficient any more. You can limit OpenCV's parallelism with So OpenCV will just use 8 threads now. This will limit the occupancy of your cores. At the same time you can see if the frame gets slower by this change or not. Cheers. |
Beta Was this translation helpful? Give feedback.
-
When building OpenCV with TBB enabled, the load could be reduced under certain conditions. |
Beta Was this translation helpful? Give feedback.
One other reason you see a high CPU-usage might be because OpenCV will try to use all available CPUs for processing. Your machine has a lot of CPUs (40) where this parallelization might not be that efficient any more. You can limit OpenCV's parallelism with
this command:
cv::setNumThreads(8)
https://docs.opencv.org/4.5.2/db/de0/group__core__utils.html#gae78625c3c2aa9e0b83ed31b73c6549c0
So OpenCV will just use 8 threads now. This will limit the occupancy of your cores. At the same time you can see if the frame gets slower by this change or not.
And as @ymd-stella proposed, try turning off G2O parallelism as I have seen some bad behavior of this feature before.
Cheers.