Comments (4)
Good one. I would like to make this configurable. When combining data from different providers it easier to use shirt numbers.
For what use case would you like the provider ids?
OR implement #3 and add a little helper / layer to go from shirt number to provider id. Although in some cases - like statsbomb - it requirements metadata (Lineup) to load the events, even when you donβt need the shirt numbers. That would be an argument to go for the provider ids by default and have a mapper to go to shirt numbers.
I think Iβd prefer the last one. Would that work for you?
from kloppy.
By last one you mean "go for the provider ids by default and have a mapper to go to shirt numbers"? I'd agree with that. The game model on #3 could have field to specify which provider are the tracking and event from and that can be used in the mapper to go from ids to shirt number.
from kloppy.
Brainfart here for the internals: introduce a PlayerIdentifier type which holds IdentifierType (Jersey, Provider[Statsbomb], Provider[Metrica], etc) and the value.
and use player_id instead of jersey_number everywhere.
The PlayerIdentifier eq method should check type and raise exception when types don't match. This will prevent mistakes when trying to match different types of identifiers
from kloppy.
Fixed in #34
from kloppy.
Related Issues (20)
- Create OWN_TEAM Orientation HOT 3
- Inconsistency in the player ID's used between different tracking data deserializers HOT 4
- Add support for parsing events that occur during extra time HOT 2
- A few issues and discussion points wrt #242 HOT 9
- receiver_coordinates naming
- [Opta] Ordering of events HOT 14
- [Wyscout v2] Bug in deserializing Offensive Duel events which are also an interception
- [Wyscout v2] Implement desirialization of take ons
- [Wyscout v2] Impute goal kick start location and result
- [Wyscout v2] Deserialize accelerations as carries
- [Wyscout v2] Fix keeper save coordinates
- [Opta] Fix end coordinates of deflected passes
- Store the position of a player at moment of event execution and not only starting position HOT 10
- Creating support for expected goals and game state values in our kloppy data model HOT 2
- Add pressure event HOT 1
- Add counter attack parsing in StatsBomb deserializer HOT 1
- Different unit used for shot_event.result_coordinates.z dimension for Opta vs StatsBomb HOT 3
- Incorrect Stats Perform coordinate system
- Store the formation changes of a team in Team object
- Tracab with string path not working
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
π Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. πππ
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google β€οΈ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from kloppy.