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

Second Ed (p 272): Listing 9.19: invalid syntax due to dangling code #224

Open
9nut opened this issue Jun 6, 2023 · 0 comments
Open

Second Ed (p 272): Listing 9.19: invalid syntax due to dangling code #224

9nut opened this issue Jun 6, 2023 · 0 comments

Comments

@9nut
Copy link

9nut commented Jun 6, 2023

The listing in the book looks something like this:

for i in range(n):
 for j in range(n):
 image = all_images[i * n + j]
 stitched_filters[
 row_start = (cropped_width + margin) * i
 row_end = (cropped_width + margin) * i + cropped_width
 column_start = (cropped_height + margin) * j
 column_end = (cropped_height + margin) * j + cropped_height
 stitched_filters[
 row_start: row_end,
 column_start: column_end, :] = image

the first stitched_filters[ line in the listing shouldn't be there.

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