Exporting subsets of an image as smaller images

Hi there!

I’m working on an image segmentation application and I’m looking to export lots of ‘fragments’ of an input image and save these small arbitrarily-shaped smaller fragments as individual image files.

I was wondering if anybody has had any experience with this and could recommend, from a high level, any approaches I ought to consider in breaking down the pixels of the larger image.

Thanks for looking, have a great day.

James.

you can just use ofImage
load -> crop -> save.
these steps can generate cropped image from original image.