Comments (6)
You can use the sklearn gridsearch on nested or composed estimators as well: https://scikit-learn.org/stable/modules/grid_search.html#composite-estimators-and-parameter-spaces
We need to make sure though, that all nested objects inherit properly from the BaseEstimator
class, as this implements the two methods (set_params
and get_params
) needed.
Also, internally we are using a MultiOutput(Pipeline). As you said, this might clutter the parameter names. If this is the case, we can overwrite set_params
and get_params
for a cleaner interface.
from pysindy.
Should be interesting an example at documentation
from pysindy.
I was looking into this again and your suggestion, @Ohjeah, now works smoothly (since we have refactored the optimizer code).
However there's another problem: the SINDy fit
and score
methods take an optional parameter t which isn't standard for scikit-learn. When a uniform time step other than 1 is used, the cross validation object doesn't have a way to pass it into both the fit
and score
methods. You can pass in a fixed time step to SINDy.fit
via the **fit_params
argument of the cross validation object, but not the score
function.
One option is to not try to feed t in and assume a uniform time step of 1. If you then divide the coefficients of the resulting model by the true time step you'll arrive at the correct equation, but you'll also have to shrink the thresholds by the same factor.
Another option could be to add a parameter to the SINDy
constructor allowing you to specify a fixed uniform time step that would be used as a default if other values are not passed in. I think this might be the cleanest solution. I'll play around with it and see how it looks.
Nonuniform time steps or control variables are another story. I haven't thought much about how to incorporate them into this framework.
from pysindy.
Closed with #84
from pysindy.
@briandesilva I overlooked your last comment and assumed this issues was closed with the corresponding PR.
Should we re-open, or open a separate issue to discuss parameters for the derivative?
Btw: you can also use a custom scorer in gridsearches/crossvalidation.
from pysindy.
I don't think we need to re-open the issue. I'm satisfied with our current cross-validation capabilities.
from pysindy.
Related Issues (20)
- [BUG] Multiple trajectories raises a ValueError HOT 2
- Allow explicit control of randomness for ensembling
- [BUG] cannot import name 'enzyme' HOT 1
- Library truncation issue in E-SINDy HOT 1
- Setting up a model identification in real life data HOT 11
- [BUG] Remove `interaction_only` arg from PDELibrary
- Bayesian Sindy HOT 2
- [BUG] TypeError for keyword normalize when instantiating optimizer. HOT 1
- Documentation for Handling Trigonometric Functions in SINDy-PI Library Functions HOT 1
- Be explicit about CVXPY solvers
- polynomial library to include second order derivative HOT 2
- Unsure on the correct use of pySINDy
- LinearRegression unknown keyword normalize HOT 2
- Implementation of graph data HOT 5
- Issue in plotting the graph using model.simulate
- Total freedom in library functions with CustomLibrary HOT 1
- SINDy-PI for a system of ODEs
- simulating error(overflow) when expanded to the third order HOT 3
- [BUG] A lot of issues with the bayesian implementation (UQ-SINDy) HOT 3
- [BUG] No consistency in model.fit() HOT 5
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 pysindy.