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

Accessing elements in a 2D array #205

Open
willy-bit opened this issue Feb 2, 2024 · 0 comments
Open

Accessing elements in a 2D array #205

willy-bit opened this issue Feb 2, 2024 · 0 comments

Comments

@willy-bit
Copy link

I noticed there is a bug in the way you are accessing elements in the translation vector, t.
It is a 2D array, yet you are treating it as a single list.
Here is how you are accessing the elements: trans_params = np.array([w0, h0, s, t[0], t[1]]). This definitely raises a value error!

However, the correct way of accessing elements in a 2D array would be : trans_params = np.array([w0, h0, s, t[0][0], t[1][0]])

The bug is line 196 in the preprocess.py script under utils.

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