Code Monkey home page Code Monkey logo

chickenbestlover / online-recurrent-extreme-learning-machine Goto Github PK

View Code? Open in Web Editor NEW
150.0 11.0 68.0 189.49 MB

Online-Recurrent-Extreme-Learning-Machine (OR-ELM) for time-series prediction, implemented in python

Python 2.08% Jupyter Notebook 97.92%
oselm elm os-elm or-elm extreme-learning-machine online-sequential-elm time-series time-series-prediction online-learning online-learning-algorithms sequential-learning online-sequential-learning

online-recurrent-extreme-learning-machine's Issues

Dividing the dataset into train and test

Two issues related to each other:

  1. As I can see in the code, self.beta is directly responsible for prediction. However, this matrix is being updated recursively up to the end of the process (to be more exact len(sequence)-predictionStep.
    For instance in FOS_ELM we have:
    self.beta = self.beta + np.dot(self.M, np.dot(Ht, targets - np.dot(H, self.beta)))
    and this train process is in a for loop with prediction of the next:
    for i in range(numLags, len(sequence)-predictionStep-1):
    net.train(X[[i], :], T[[i], :])
    Y = net.predict(X[[i+1], :])
    predictedInput[i+1] = Y[-1]
    I believe this update should be continued up to the end of the training, then one needs to feed the testdata only to prediction function.

  2. The whole data is normalized but if you divide the dataset to test and train, you cannot normalize test set. (you can use mean and variance of train set for normalizing test).

Based on these two issues, the NRMSE mentioned at the end of the process is not reliable.

A question about the training process

Hi, I have successfully ran through your code, but I have a question I want to communicate with you.

As shown in codes below, why you choose to compare the gap between predictedinput [i+1] and targetInput [i+1] instead of comparing the gap between predictedinput [i+1] and trueData [i+1] .

I think predictedinput [i+1] is the prediction at time i+1 which is correspond to trueData [i+1]

image

OR-ELM python3 (or R)

Dear Jin,

First of all I would like to thank you for developing this repo. I read with great pleasure your paper on the OR-ELM algorithm and I would like to use it as part of my PhD thesis.
I was wondering if your code will work on Python3 or if you are aware of any R implementation of OR-ELM.

Thank you.

Best Wishes,
Ahmed

Ramp Function Diverges

As a low-effort test of the ORELM, I substituted for NYC Taxi traffic, the attached ramp function from 0 to 20000 in increments of 10000, backed up the nyc_taxi.csv and copied therampified_nyc_taxi.csv in its place. It seems not to converge.

This isn't necessarily an issue with the code. It is interesting in that it raises the issue of parameter seeking in the ORELM algorithm. What is it about the ramp function that causes ORELM to diverge and how would one find the parameter(s) values that converge on a solution?

rampified_nyc_taxi.zip

image

For comparison, this is with a sine function rather than ramp function -- although in this case, I synchronized the time of day with the phase:

sine_nyc_taxi.zip

image

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.