deep_sort icon indicating copy to clipboard operation
deep_sort copied to clipboard

How to save every tracking object as image into its respective folder?

Open prnvjb opened this issue 7 years ago • 3 comments

I've been trying to save every trackable object into image and save into their respective folder. I observed that a single time appeared objects are not being in tracks-objects. Would somebody tell me how to save as cropped image of every track-id assigned object even a single time appeared object? Thanks a lot.

prnvjb avatar Mar 23 '19 08:03 prnvjb

Personally, I would do it outside of the actual tracking code in a way similar to how the results are saved here. The question how to crop and save image regions is a bit off topic for this issue tracker, but I'll leave it open for a while in case someone finds the time to help you with that.

nwojke avatar Apr 30 '19 09:04 nwojke

@prnvjb you've already got the bounding boxes for each object so it should be pretty easy to save. Just create a new image using numpy slicing (e.g., something like new_image = old_image[y:y+h, x:x+w,:]) and then save using opencv cv2.imwrite.

EricThomson avatar Mar 11 '20 14:03 EricThomson

@prnvjb I have been currently facing this issue and have you already finding the solution? If so, could you please let me know how to handle this issues?

ImSuMyatNoe avatar Oct 06 '21 07:10 ImSuMyatNoe