Comments (5)
Hi Pascal,
Thanks for reporting the issue. Yes you are right that this would result in the feature being zero which could lead to problems depending on how the optimizer initializes the optimization coefficients.
I agree that it makes sense to safeguard against this behavior. I would propose to add a general test as a function for this in the optimizer base template. Hereby we could test each row of the feature matrix X for having non descriptive features and setting all corresponding coefficients to zero.
Would you like to add a PR this in a new PR?
from data-driven-dynamics.
Sorry for responding so late (busy week). After analyzing the problem I have the following proposition:
The issue can arise in two cases:
- The model is ill posed (in this example there is no lever for this rotor)
- The actuator is never actuated in the log.
In my opinion there should be two changes to address this issue:
- The Model should not produce ill-posed features. If it detects for example that the crossproduct is zero it should omit these features since the result will be nonsense anyway. This should apply to all other models that produce features.
- The optimizer should also check for correct features and warn the user that the result for this specific parameter will be undefined. I don't think that just returning zero is the proper way to handle this case, since the program should indicate to the user that something went wrong. I would rather suggest returning something like NAN or None if this happens.
from data-driven-dynamics.
To your problem analysis:
I do not think that the model automatically ill posed when there is no leaver moment for a certain rotor. If we think about a fw aircraft with only a single rotor it is actually desirable to not have a moment contribution of this rotor (Or at least be very close to zero contribution.
To your proposed changes:
-
I do not think including branching in the amount of model features (e.g. reducing the amount of coefficients when they have no influence) is the way to go here. This will just result in us needing to check whether every component is present in the model output yaml file in the gazebo implementation of every model. So if it is the case that a coefficient has no influence on the output it would be correct and the easiest to let the optimizer return 0 I think.
-
Yes that is a very good point! We definitely need that for the case where the rotor is never actuated in the log! I have been thinking about making some kind of PDF report that includes significance and correlation metrics for each coefficient. This way it would be more information than just a binary classification. But that might take some time to implement so your suggestion would certainly be a step in the right direction.
How would you suggest to determine whether a feature is ill posed?
from data-driven-dynamics.
I do not think that the model automatically ill posed when there is no leaver moment for a certain rotor. If we think about a fw aircraft with only a single rotor it is actually desirable to not have a moment contribution of this rotor (Or at least be very close to zero contribution.)
I agree. I think it is very important to differentiate between the case of the feature is zero due to geometry or due to actuator inactivity during the logging and should be handled differently. If dropping the feature causes issues later on in the pipeline I would consider setting the parameter to zero if the cause is a geometrical problem. A solution would be that the model could set a flag or prematurely set the result of the parameter to zero before the optimizer does it's work. And if the optimizer detects zero columns in the feature matrix it can check if the parameter is already defined and in this case proceed with optimization or abort and report that the problem is ill-posed.
from data-driven-dynamics.
#174 Implements a brute force check to look for invalid features given to the optimizer. The handling of invalid feature due to geometry still has to be implemented
from data-driven-dynamics.
Related Issues (20)
- Evaluation with identified model HOT 10
- [FeatureRequest] Non-dynamic parameter estimation HOT 2
- Compute features before dataselection HOT 4
- Failure on using quadrotor model with plot enabled
- Pipeline fails with data selection HOT 1
- Online Sys ID HOT 6
- Pipeline fails with default models HOT 2
- Plotting broken(again)
- Moment prediction doesn't seem to be correct with QP HOT 2
- Multi instance topic logs break the pipeline
- Simulation and testing problem (inconsistent behavior) HOT 27
- Unified formatter for python code HOT 3
- Model estimation broken for upstream PX4 HOT 6
- ID data gathering FW/VTOL HOT 3
- self.prepare_regression_matrices() issue. HOT 3
- Are real flight logs available HOT 5
- make install-depdencies fail HOT 1
- Build failure
- Product of inertia problem
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from data-driven-dynamics.