Skip to content

Instantly share code, notes, and snippets.

@TuringNPcomplete
Last active October 29, 2021 17:14
Show Gist options
  • Save TuringNPcomplete/9bec83872329d3f58b6f32172c997762 to your computer and use it in GitHub Desktop.
Save TuringNPcomplete/9bec83872329d3f58b6f32172c997762 to your computer and use it in GitHub Desktop.
#Cropping different parts of the reptile image
#Making row slices
show_images([reptile_arr[int(row_sz*start_mult): int(row_sz*(start_mult+0.2)), :] for start_mult in [0, 0.2, 0.4, 0.6, 0.8]])
#Making column slices
show_images([reptile_arr[:, int(row_sz*start_mult): int(row_sz*(start_mult+0.2))] for start_mult in [0, 0.2, 0.4, 0.6, 0.8]])
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment