I would like to save the output of Yolo detection as a txt file for each image into a folder. I wrote the following code to save annotations( .txt files) based on the class