Comments (4)
Take Lorenz System as an example, you can get the code from wiki.
Add them to reservoir.py
:
from scipy.integrate import odeint
rho = 28.0
sigma = 10.0
beta = 8.0 / 3.0
def f(state, t):
x, y, z = state # unpack the state vector
return sigma * (y - x), x * (rho - z) - y, x * y - beta * z # derivatives
state0 = [1.0, 1.0, 1.0]
t = np.arange(0.0, 40.0, 0.01)
states = odeint(f, state0, t)
Then change the config file:
{
"input": {
"nodes": 3,
"functions": [
"lambda x: states[:, 0]",
"lambda x: states[:, 1]",
"lambda x: states[:, 2]"
],
"length": 10000
},
}
from reservoir.
First of all, thanks for your fast help. Sadly I got the following error:
Traceback (most recent call last):
File "reservoir.py", line 200, in
r.run()
File "reservoir.py", line 178, in run
self._run()
File "reservoir.py", line 153, in _run
self.dataset[i, self.train_len+1: self.train_len+self.error_len+1] - self.S[i, 0: self.error_len])) / self.error_len)
ValueError: operands could not be broadcast together with shapes (999,) (1000,)
Program finished! Current node = 400
Any ideas what went wrong?
from reservoir.
Not sure what's wrong, for now, you can set error_len
to a number < 1000, and it should work fine.
In config:
"training": {
"init": 1000,
"train": 5000,
"test": 1000,
"error": 500
}
from reservoir.
That solved it for me. Thanks for your help.
from reservoir.
Related Issues (2)
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 reservoir.