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

Basic questions on depth quality tool and fails #10232

Closed
arothenberg opened this issue Feb 10, 2022 · 12 comments
Closed

Basic questions on depth quality tool and fails #10232

arothenberg opened this issue Feb 10, 2022 · 12 comments

Comments

@arothenberg
Copy link


Required Info
Camera Model D435
Firmware Version 05.12.02.100
Operating System & Version Win (10)
Platform PC
SDK Version 2.32
Language C++
Segment desktop app

Issue Description

The realsense depth quality calibration tools.

I am restoring a project from last year that uses the realsense sdk and camera.
Since it's been awhile I decided to recalibrate the camera. I set it to factory defaults through the depth quality tool.
#10182

It took me a while to get the on board chip calibration to work , trying different lighting and distances, but eventually it did work inconsistently but when it worked it consistently gave a good rating.
I assume this is good enough?
The same with the tare calibration. It was hard to get a reading but when it worked it
looked close to the original.

I could not get the focal length calibration to work after many trys and many set ups.
"failed to extract target information from frames"

Also, I couldn't figure out how to get into advanced mode.

I am going to try dynamic calibration next and see if that goes better.

Is there a good reason to get focal length calibration working? I am working with relative distances in my project.
Is there a reason i would need advanced mode? I noticed a hardware reset option in advanced mode in your screen shots.

If I successfully dynamically calibrate is there then still a reason to use the depth quality calibration tools?

thanks.

Thanks.

@MartyG-RealSense
Copy link
Collaborator

MartyG-RealSense commented Feb 10, 2022

Hi @arothenberg A 'Good' rating from the On-Chip calibration tool is indeed a good result, though you are free to repeat the calibration as often as you wish until you are satisfied with the health score and only then save the calibration to the camera hardware.

There is detailed advice at #10213 (comment) from a Tare expert at Intel that should help to obtain better results with Tare.

On-Chip calibration can improve the depth image quality, whilst Tare calibration can improve depth measurement accuracy.

In regard to Advanced Mode, if you go to the More option of the RealSense Viewer (the same one that the calibration options are under) and ensure that a tick mark is beside the Advanced Mode menu option then Advanced Mode will always be enabled and you do not need to set it again. It should be already enabled by default when the camera is purchased and I would strongly recommend keeping it enabled.

An example feature of Advanced Mode would be to use camera configuration json files, also known as Visual Presets.

https://dev.intelrealsense.com/docs/d400-series-visual-presets

The Intel documentation link below provides further information about Advanced Mode.

https://dev.intelrealsense.com/docs/intel-realsense-d400-advanced-mode

You can also explore Advanced Mode options in the options side-panel of the Viewer. Because these settings interact with each other in complex ways, there is not documentation for most of them as Intel chose to control them with machine learning algorithms instead. You are free to experiment with them though to see what effect it has on the image.

A reason for using Dynamic Calibration would be if you wanted to perform a robust calibration of the camera that includes calibration of the RGB sensor too if the camera has one, whilst On-Chip excels at quick depth calibration and calibration health checks.

@arothenberg
Copy link
Author

Great. I don't need or use RGB at the moment, only depth so I guess I'll skip the dynamic calibration.
I do want to load json in code so that I can easily set different max and min distances for the camera (before the main while loop).
How about the "focal length calibration" which I couldn't get to work.
Should I spend some time on that? Is it useful?

@MartyG-RealSense
Copy link
Collaborator

The API Changes release notes for SDK 2.50.0 provide some information about focal length calibration.

https://github.com/IntelRealSense/librealsense/wiki/API-Changes#version-2500

Focal length calibration is is a significant new feature added in SDK 2.50.0. At the time of writing this though there are no reports from other RealSense users about it. So in the absence of end-user feedback, I would recommend testing it yourself to see what effect it has on the depth image.

@arothenberg
Copy link
Author

I did test and the problem is there are no conditions yet to get it to work(finish), it always ends in error.
I am using a target from here
https://dev.intelrealsense.com/docs/self-calibration-for-depth-cameras

@arothenberg
Copy link
Author

focal length calibration ends with "failed to extract target information"

@arothenberg
Copy link
Author

Also OT
I found an example using realsense in a glfw repository. It's example#2 so if you ever get questions about implementing glfw
in a realsense app loop you can refer to this. I was surprised.

https://cpp.hotexamples.com/examples/-/-/glfwCreateWindow/cpp-glfwcreatewindow-function-examples.html

@MartyG-RealSense
Copy link
Collaborator

MartyG-RealSense commented Feb 12, 2022

The paper recommends that the target should be A4 paper size (21 x 29.7 cm) but the target image in the paper is smaller than that (12.89 x 17.12 cm).

The target that Intel tested with in the paper looks as though it is the one from Section 2.2 and has been printed with the 'fit to page' method so that the small image is stretched out when printed to fit the full size of the selected paper size.

https://dev.intelrealsense.com/docs/self-calibration-for-depth-cameras#section-2-2-example-target-for-calibration-characterization

I would speculate that the target could be printed to page-fit other paper sizes similar to A4 such as US Letter or US Legal so long as the general grain of the texture on the pattern remains.

Thanks very much too for highlighting the GLFW example :)

@MartyG-RealSense
Copy link
Collaborator

MartyG-RealSense commented Feb 12, 2022

I checked the Focal Length calibration information in the Release Notes in addition to the earlier referenced details in the API Changes. The release notes provide a link to a PDF target for Focal Length and Tare Target calibration, which is different from the target in the paper used for On-Chip calibration.

https://librealsense.intel.com/Releases/UCAL/Calibration_Target_v1.pdf

image

@arothenberg
Copy link
Author

arothenberg commented Feb 12, 2022

Excellent. I'll try that latter.
So I cant just print the target for the OCC on 8.5x11? Is there a good target for the OCC that I can just print on letter size and use?
Thanks.

@MartyG-RealSense
Copy link
Collaborator

The only version of the OCC target image available is the 12.89 x 17.12 cm one in the paper. It should not matter if the image is stretched to fill a US Letter sheet's dimensions, as the paper states that "the exact nature of the texture is not critical, as long as it is semi-random and fairly “noisy” with high spatial frequencies".

@MartyG-RealSense
Copy link
Collaborator

Hi @arothenberg Do you require further assistance with this case, please? Thanks!

@MartyG-RealSense
Copy link
Collaborator

Case closed due to no further comments received.

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

No branches or pull requests

2 participants