Created
October 21, 2022 03:29
-
-
Save victormurcia/cb0b931d69ab43ac87acdca841b0ecc4 to your computer and use it in GitHub Desktop.
process entire soccer game footage for color detection
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| def getJerseyColorsFromGame(jsonPath,MP4Path,whichVideo,nClusters): | |
| mp4_list = getListOfFiles(MP4Path , ".mp4") | |
| n_mp4 = len(mp4_list) | |
| df_list = [] | |
| for vid in range(n_mp4): | |
| jerseyColor_df = getJerseyColorsFromMP4(jsonPath,MP4Path,vid,nClusters) | |
| df_list.append(jerseyColor_df) | |
| allJerseyColors = pd.concat(df_list) | |
| return allJerseyColors |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment