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

Running the code in Python 3.6 #14

Open
Bellman281 opened this issue Apr 20, 2018 · 6 comments
Open

Running the code in Python 3.6 #14

Bellman281 opened this issue Apr 20, 2018 · 6 comments

Comments

@Bellman281
Copy link

I changed lstm.py code , so I can test it on Python 3.6:
change xraneg to range.
change range(len(data)/prediction_len): to range(len(data)//prediction_len):
I got this error:
TypeError: %i format: a number is required, not list

any help please

@Bellman281
Copy link
Author

issue solved! thanx

@Sir-Jaybob
Copy link

Thanks for this post, was having the same issue with that range line. Cheers!

@dewmal
Copy link

dewmal commented Aug 5, 2018

@Bellman281 How did you solve that issue.

@MartinMacek
Copy link

  1. Replace all xrange to just range
  2. Use two // in range(len(data)//prediction_len):

note: I had to do it manualy in different editor, then save it and restart the script in jupyter

@MoAfshar
Copy link

MoAfshar commented Dec 5, 2019

"TypeError: %i format: a number is required, not list" still exists after those changes. Anyone else experience this?

@SungchulLee
Copy link

Instead of range(len(data)//prediction_len), I use range(int(len(data)/prediction_len)). I think both should work.

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

6 participants