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

Code improvements #6

Open
Dirguis opened this issue Apr 6, 2019 · 3 comments
Open

Code improvements #6

Dirguis opened this issue Apr 6, 2019 · 3 comments

Comments

@Dirguis
Copy link

Dirguis commented Apr 6, 2019

Hello jiangqy,
Thanks for sharing the code. A quick note, to mention that the code could be improved by using a few tricks here and there, in 20 epochs.
Using an updated code and the exact same data as you, I get an accuracy of 0.933. Note that I got the same accuracy as described by you in your Readme the first time I ran your code.
Let me know if you are interested in updating your code and I can start a pull request. If not, I would like to then create a repo if this example and the updated code, mentioning you and your repo as well of course.
Cheers!

LSTM_classifier_08-Apr-04-1554736103

@jiangqy
Copy link
Owner

jiangqy commented Apr 7, 2019 via email

@Dirguis
Copy link
Author

Dirguis commented Apr 8, 2019

Hello Qing-Yuan,

Sorry, I had the wrong numbers, I edited my first message.
I get an accuracy of 0.933, with a slightly increasing loss, which is a nice improvement.

The main changes are about creating my own custom dataset, changing the optimizer and packing the sequences. I cleaned up the repo a bit as well. There are several other things I would like to do with this dataset, but for now I have a running code here. Note that it is the model_upgrade branch.

You can see if this is good enough with you or if you want to add other modifications or wait for a bit more improvements if I can.

Cheers!

Damien

@Dirguis
Copy link
Author

Dirguis commented Apr 23, 2019

Hello Qing-Yuan,

I have pushed my changes to master on my repo:
https://github.com/Dirguis/LSTM-Classification-Pytorch/tree/master

I can get around 95%-96% accuracy. If you scroll to the end of the readme, you will see that I reference your repo and I mentioned what I changed.
I can see submit a pull request to your repo if you are interested. There are a few other things that I could add if I have the time. Like I could add the full attention layer mechanism (not the simplified version). I have that done on my computer, but it is not very pretty. We'll see. It works very well as is so far.

Let me know what you think if you have time.

Cheers!

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