SoccerNetv2-DevKit
SoccerNetv2-DevKit copied to clipboard
Question about the input image channels of Features/ExtractResNET_TF2.py
When I read preprocess_input in tf.keras, it seems that the input image channel is expected to be "RGB", but the image loaded by OpenCV is supposed to be "BGR", right? In that case, FrameCV.frames would still be BGR, which would be different from the input image expected by tf.keras.preprocess_input and tf.keras.applications, right?
Please let me know if I am wrong as I am not a frequent user of tensorflow.
You are absolutely right about OpenCV extracting frames in the order BGR, and as a results, FrameCV.frames would be BGR. Now, each library has a different way of pre-processing the images to extract features, and by experience, they mostly get similar performances in the end task of action spotting, with the best results obtained as explained in this repo. I fact, note that the central channel is green, and since most of the frames are grass, well the BGR and RGB looks very similar! :)