How to combine two models sequentially?

I have two fine-tuned PyTorch models: one for segmentation and one for classification. My goal is to crop an image using a binary mask from the segmentation model and then use the cropped image for classification.

This process is straightforward on my workstation, but I haven’t found useful resources on how to achieve it. Do you have any recommendations or a simple workflow for this task?