Open thepian opened 5 years ago
The output following raw coordinates as of now.
For those who I can help: If you happen to know which are the rotated images, then annotate them as it is. Then it can be translated to the actual bounding box coordinates by doing this
import numpy as np
import cv2
import pandas as pd
df = pd.read_csv('Annotations-export.csv')
df_copy = df.copy()
length = df.index.size
width = np.zeros((length))
for i, name in enumerate(df['image']):
width[i] = cv2.imread(name).shape[1]
df['xmin'] = width - df_copy['ymax']
df['ymin'] = df_copy['xmin']
df['xmax'] = width - df_copy['ymin']
df['ymax'] = df_copy['xmax']
df.to_csv('Corrected_annotations.csv', index = False)
Describe the bug The tool only considers the raw jpeg and ignore rotation attribute. Will the label rects follow the raw coordinates or rotated in the frameworks consuming the output. Even if it will work it is uncertain when tagging the picture, and they are shown the wrong way around.
To Reproduce Steps to reproduce the behavior:
Expected behavior Options to control how to handle rotation.
Screenshots If applicable, add screenshots to help explain your problem.
Desktop (please complete the following information):