Skip to content
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

Frame rate not adjusting with new ROI #197

Open
J-C-Haley opened this issue Jan 4, 2024 · 2 comments
Open

Frame rate not adjusting with new ROI #197

J-C-Haley opened this issue Jan 4, 2024 · 2 comments

Comments

@J-C-Haley
Copy link

Hello, I'm trying to use the SetROI service to reduce data load, and my expectation was that frame rate would rise to the maximum (as a function of exposure, allowed bandwidth, and set frame rate), as it does in the pylonviewer GUI. However, current behavior is to limit the frame rate on startup (here), based on the startup settings (ROI/exp/framrate), and this overrides the frame_rate ROS parameter, even if the SetROI (here) were to attempt to reset the frame rate the original parameter has been destroyed, so further dynamic changes have no rate increase effect.

So, my question is, shall we either:

  • have a separate parameter to store the intended max framerate (e.g. target_frame_rate), so we preserve the user intent, or,
  • not override the ros frame_rate parameter with the startup max framerate, and simply report achieved rate in the terminal or possibly another param (achieved_frame_rate)

I'd prefer the latter, it's a quick fix I can contribute, but I'd like to hear input on if this would break anything.

Thank you!

@J-C-Haley
Copy link
Author

Ah, I see this is a bigger problem than I assumed, frame rate gets baked into the main ros::Rate spin on startup, which is not adjustable from within the pylon_camera_node. Either of these fixes would require transferring ownership of the rate into the node, so it can be adjusted...

@FrancoisPicardDTI
Copy link
Collaborator

FrancoisPicardDTI commented Jan 31, 2024

Hello @J-C-Haley
I just added a section in the documentation.
There are several issues, and several solutions, to increase the frame rate.
If the camera image acquistion is triggered by sofware trigger (default setting), then it is not possible to get the maximum frame rate, because the image acquisition is sequentially triggered, which is not overlapping then.
Several possible solutions are mentionned and tested in issue #21, #28, #29, #81, #116, #147, and #200. Please refer to them for more information and hopefully find a solution for your use case.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants