Skip to content
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

GTD algorithm implementation #1

Closed
Amir-19 opened this issue Jun 10, 2018 · 1 comment
Closed

GTD algorithm implementation #1

Amir-19 opened this issue Jun 10, 2018 · 1 comment

Comments

@Amir-19
Copy link

Amir-19 commented Jun 10, 2018

I was reading the GTD implementation and I got a little confused about updating the weights. Based on the code these are the update rules.

        self.w += alpha*(delta*self.e + gm_p*(1-lm_p)*np.dot(self.e, self.h)*xp)
        self.h += beta*(delta*self.e + np.dot(self.h, x)*x)

However, based on Maei's thesis the update rules are a little different.

        self.w += alpha*(delta*self.e - gm_p*(1-lm_p)*np.dot(self.e, self.h)*xp)
        self.h += beta*(delta*self.e - np.dot(self.h, x)*x)

screen shot 2018-06-09 at 6 56 51 pm
Is there a reason for these differences?

@rldotai
Copy link
Owner

rldotai commented Aug 4, 2018

That looks like an error on my part.
I referred to code that I'd already written when I was benchmarking these algorithms (for example) but presumably made a typo.

I'll fix that and add some tests to make sure everything else works.
Thanks for point that out!

@rldotai rldotai closed this as completed Aug 4, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants