-
Notifications
You must be signed in to change notification settings - Fork 13.5k
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
process_sensor_caldata.py: regularly weighted over temperature thermal fitting #14091
Conversation
This issue has been automatically marked as stale because it has not had recent activity. Thank you for your contributions. |
I like the idea and we shouldn't drop it. What's blocking this? |
I began to implement the onboard version but let it paused because I was in a rush on other tasks. I can try to finish it at the end of the month |
How about bringing it in with an option to output the parameters based on the resampled data? Then by default it's in sync with the onboard calibration method, but we can still view the impact of resampling, and opt into the change trivially. |
We should get this in and handle the online version in a separate PR. In the interim, a note could be added to the documentation https://docs.px4.io/master/en/advanced_config/sensor_thermal_calibration.html to indicate the importance of maintaining a rate of temperature increase throughout the calibration range when using the internal method. |
@NicolasM0 can you rebase or merge with master to resolve the conflicts? |
bcdefd7
to
874c395
Compare
This commit have been rebased but it is still a draft. |
If there are no objections and it's documented I'm fine with it. |
If it's not too much trouble then simply adding an option to skip the resampling might be worthwhile for anyone considering using online calibration in production and wanting to sanity check the results with offline (more than visually). |
the option '--no_resample' allows to disable resampling and have the previous behavior
874c395
to
099e5b4
Compare
I opened a thread here to discuss about an issue and propose a fix: https://discuss.px4.io/t/issue-with-thermal-calibration-fitting/14582
Describe problem solved by this pull request
If the temperature ramp is not constant during heat up, the fitting give more weight to temperature with lower change rate. If heating become very slow (typically at the high temperature), the calculated polynomial can not fit at all where the temperature change rate was high (typically at low temperature)
Describe your solution
This commit add a re sample before fitting to have a more regular weight over temperature