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

Intended behaviour of np.roll? #57

Open
johannes-graeter opened this issue Dec 12, 2018 · 0 comments
Open

Intended behaviour of np.roll? #57

johannes-graeter opened this issue Dec 12, 2018 · 0 comments

Comments

@johannes-graeter
Copy link
Contributor

Hi Simon,
I came across a line of code that made me think:

shift = shift % len(filenames_extended)
filenames_extended = list(np.roll(filenames_extended, shift))

If I understand correctly np.roll with axis=None will first flatten the array and then roll.
Is that the intention? In order to shift the training examples to the desired training position it seems to me that np.roll(..., axis=0) would be the desired behaviour (in order to roll complete rows of the array).

Thanks :)
Johannes

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

1 participant