floodlight.io.skillcorner
- floodlight.io.skillcorner.read_position_data_json(file_path_structured_data, file_path_match_data, teamsheet_home=None, teamsheet_away=None)[source]
Parse and process position data and match data from the SkillCorner Open Dataset from disk.
This dataset was published by SkillCorner in a joint initiative with Friends Of Tracking. It contains 9 matches of broadcast tracking data in JSON format. The data for each match is structured in two separate files. The match data file contains meta information about the match and its competitors, like team and player’s identifiers. The structured data file contains the position data for each frame.
- Parameters:
file_path_structured_data (str) – The file path to the positions JSON file.
file_path_match_data (str) – The file path to the match data JSON file.
teamsheet_home (Teamsheet, optional) – The teamsheet for the home team (default is None).
teamsheet_away (Teamsheet, optional) – The teamsheet for the away team (default is None).
- Return type:
tuple[Dict[str,Dict[str,XY]],Dict[str,Dict[str,Code]],Dict[str,Dict[str,Code]],Dict[str,Teamsheet],Pitch]- Returns:
xy_objects (dict) – A dictionary containing XY objects for each half and each team.
possession_objects_team (dict) – A dictionary containing team possession codes for each half.
possession_objects_player (dict) – A dictionary containing player possession codes for each half.
teamsheets (dict) – A dictionary containing the teamsheets for ‘Home’, ‘Away’, and ‘Ball’.
pitch (Pitch) – The Pitch object representing the match pitch.