feat: add Fujimura sugihara model to SpaceControlModel#162
Open
tehbeh86 wants to merge 21 commits intofloodlight-sports:mainfrom
Open
feat: add Fujimura sugihara model to SpaceControlModel#162tehbeh86 wants to merge 21 commits intofloodlight-sports:mainfrom
tehbeh86 wants to merge 21 commits intofloodlight-sports:mainfrom
Conversation
build!: release 0.5.0
This implements a new space control model based on the approach by Taki and Hasegawa (2000), as described in "Visualization of dominant region in team games and its application to teamwork analysis". The model is integrated into `space.py` and enables the calculation of dominant regions based on arrival time under directional acceleration constraints.
- Added data quality tests for the Euclidean model - Introduced helper method for masked np.nanargmin - Declared internal methods and added concise internal docstrings - Changed out-of-pitch ValueError to UserWarning
- Added model identifier 'fujimura_sugihara' to supported models - Implemented _calculate_shortest_times_fujimura_sugihara() - Added helper method _stack_pos_vel() to reduce code duplication
…nd pitch bounds for fujimura_sugihara model
- Improved performance via vectorized exp(-αt) and norm reuse - Applied validity masks and clamped delta to 90% of t - Enhanced readability using symbolic math notation (φ, x₀, v₀, etc.) - Fixed incorrect mesh point assignment due to overshooting Newton step - Updated docstring and structure for clarity
…odel - Prevents propagation of NaNs in time computation - Ensures players with missing velocity are treated as starting from rest - Fixes failing test_nan_horizontal_fujimura_sugihara
…e/hex mesh - Added 4 tests for square mesh variant of the model - Added 4 tests for hexagonal mesh variant
… NaNs - Enforce vmax limit on player velocities for realistic time estimation - Replace NaN velocities with 0.0 to ensure stable control calculation
- Replace magic numbers with named constants in Fujimura-Sugihara method - Use descriptive variable names and section headers for better structure - Limit Newton iteration to 3 steps for consistent and efficient convergence - Extend class docstring to document the Fujimura-Sugihara model and parameters
added 2 commits
June 18, 2025 13:20
- Use motion-based center estimate for better interval bounds - Remove zero-distance override for on-spot players - Ensure consistent use of capped velocities in all calculations
- Use motion-based center estimate for better interval bounds - Remove zero-distance override for on-spot players - Ensure consistent use of capped velocities in all calculations
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This adds a motion-based space control model following Fujimura and Sugihara (2005), which introduces a velocity-dependent resistive force that limits acceleration and produces asymptotic speed behavior—yielding more realistic estimates of how quickly players can reach each point on the pitch.
Includes: