Efficient Roadway Modeling and Behavior Control for Realtime
Efficient Roadway Modeling and Behavior Control for Real-time Simulation Hongling Wang Department Of Computer Science University of Iowa Oct. 28, 2004
Overview • • • Research introduction Motivation Model of roadways Behavior control on roadways Contributions Future work
Research Introduction • Dynamic Virtual Environment – Vehicles, pedestrians, etc… – Lots of them! • Roadway Modeling – Put some activities on roadways • Behaviors – Control the activities happing on roadways
Motivation • Virtual environments – Laboratories for psychology – Understanding driver/rider behavior – Test future car concepts • More applications
Roadway Modeling • Ribbon network – Modeling roads, streets, sidewalks, and other navigable ways as ribbons • Ribbon defines geometry and orientation of navigable surface – – Centerline curve Ribbon twisting around centerline Boundaries on two sides Orientation
Ribbon • Ribbon coordinate system – Distance, Offset, and loft (D, O, L) • Provides a frame of reference for local spatial relationships
Ribbon Centerline • Modeled by cubic spline Q(t)=(x(t), y(t), z(t)) • Arc-length parameterization – Compute arc length s as a function of parameter t – Compute the inverse function t=A-1(s) – Replace parameter t with A -1(s) P(s)=(x(A-1(s)), y(A-1(s)), z(A-1(s)))
Arc-length Parameterization • Generally integral for A(t) does not integrate s=A(t)= • Function t=A-1(s) is not elementary function • Numeric methods impractical for real-time applications Solution: Approximately arc-length parameterized cubic spline curve
Approximately Arc-length Parameterized Cubic Spline Curve n n n Compute length of input curve Find m+1 equally spaced points on input curve Interpolate the equally space points to arc length s to derive a new cubic spline curve
Errors Analysis • Match error – Misfit of the derived curve from an input curve – Measured by difference between the two curves at corresponding points, |Q(t)-P(s)| • Arc-length parameterization error – Deviation of the derived curve from arc-length parameterization – Measured by formula
Experimental Results (1) m=5 (2) m=10 Experimental curve(blue) and the derived curve (red) with their knot points
Experimental Results (cont. ) (1) m=5 (2) m=10 Match error of the derived curve
Experimental Results (cont. ) (1) m=5 (2) m=10 Arc-length parameterization error of the derived curve
A parametric model for ribbons • Through any point on a ribbon passes a line that lies on it and is perpendicular to the central axis – Intersection between the line and the central axis (x(s), y(s), z(s)) – Unit normal vector v on the line pointing to left side – A parametric surface model
Mapping between Ribbon and Cartesian coordinates • Some computations are most naturally expressed in Cartesian coordinates (D, O, L) – Kinematics code computing object motion • Other computations require object locations expressed in ribbon coordinates (X, Y, Z) – Behavior code tracking roads • Efficient and robust code to map between ribbon and Cartesian coordinates
Mapping DOL to XYZ • Compute p 1 with distance coordinate Dp • Compute p 2 with p 1 and offset coordinate Op • Compute p with p 2 and loft coordinate Lp Conclusion: this mapping is very efficient
Mapping XYZ to DOL • Locate the closest point p 1 and get Dp • Compute p 2, the projection of p • Offset Op is |p 1 -p 2| • Loft Lp is |p-p 2| Problem: computation of the closest point
Closest Point Computation • Modeled as an optimization problem of computing the minimum distance between a spatial point and a parametric spatial curve – Quadratic minimization – Newton’s method – Combining quadratic minimization and Newton’s method
Method 1: Quadratic Minimization Let s 1, s 2, and s 3 be estimates of s* 1) Compute a quadratic polynomial p(s) that interpolates D(s) at s 1, s 2, and s 3 2) Solve s 4 that minimizes p(s) 3) if then s* ¬ s 4 else { si ¬ s 4 with i such that p(si) = ( p(sj) ) repeat }
Observation of Quadratic Minimization Rates of slow convergence and divergence make this method unacceptable by itself. • Fails on seemingly simple cases. • In these cases the method usually makes progress in the initial iterations and then stalls.
Method 2: Newton’s Method Solve the rootfinding problem Let s 0 be initial estimate of s* repeat until
Observation of Newton’s Method Infrequent divergence causes unacceptable failure rate. • Unpredictably diverges for some points • With a good initial estimate converges in 1 or 2 iterations.
Method 3: Combining Quadratic Minimization and Newton’s Method Exploits the complementary strengths of the two optimization techniques • Run the quadratic method for a small number of steps (typically about 4). • Run Newton’s method initialized with the result from the quadratic method.
Observation of Composite Method • Reliable and rapid convergence – Quadratic method provides a good estimate to initialize Newton’s method – Newton’s method robustly converges (usually in 1 or 2 iterations. ) • The method has undergone rigorous testing in the Hank Simulator – We have had no failures.
Results of Three Methods Example curve and some spatial points Statistics of three methods
Intersections—Where Roads Join • Shared regions of way • Non-oriented • Corridors splice together incoming and outgoing lanes – Seen as single lane ribbons
Limitations of ribbons • Transition between ribbons is hard – Different ribbons represent different local coordinate systems – Hard to understand the spatial relationship of positions on different ribbons • Solution: a uniform ribbon called a path to unite connected, aligned ribbons – Lanes on roads and corridors on intersections are seen ribbons
Path • Single-lane ribbon overlaid on the road network – Easy transition between a road an intersection • An interface between behaviors and the environment – The path relates behaviors to environment • Augmented dynamically – The vehicle is never behind or ahead of its path.
A Path as a Basis for Building Behaviors • A path is a frame of reference for tracking – Aim for a succession of pursuit points on the path • A frame of reference for local spatial relationships
Tracking Behavior • Ribbon coordinates • Pursuit point • Project pursuit point onto the vehicle’s local XY plane • Compute a circular track • Move the vehicle to a new position on the circular track • Project the new position onto ribbon surface
Cruising Behavior • Determine desired speed of an vehicle • Proportional controller
Path Based Following Behavior • Query the leader on path • Compute relative distance and relative speed • Proportional-derivative controller • Discarded if positive otherwise applied
Intersection Behavior n Gates access to a shared region of roads – An intersection is a resource n Decision of action selection – Going forward/stopping – Stop a vehicle on a desired position n n Right-of-way rules and social conventions embedded in environment database Regulate the motion of a vehicle before it enters an intersection
Intersection Behavior (Cont’) n Solve deadlock problem – Two vehicles yield right of way to other two vehicles to block them at the same time n Solve starvation problem – A vehicle yielding right of way gets stuck if vehicles having right of way come in a continuous stream
Limitations of a Path • An action-oriented geometric steering guide – A path between the current and goal positions does not always exist • Solution: a goal-oriented topological directional steering guide called a route
Route • A succession of roads and intersections • A global, strategic goal of an agent – The route is determined ahead of the path – The path is updated according to the requirements of the route • Support lane changing behaviors – Discretional lane change (DLC) – Mandatory lane change (MLC)
Route Based Lane Changing Decision Making • The route forms constraints for choice of lane on a road • Lane change decisions subject to the constraints – A DLC must consider route constraints – An MLC must enforce route constraints
Path Based Lane Changing Action • A lane changing gap determined by the spatial relationship between the vehicle and nearby vehicles • The path forms a frame of reference to deviate the pursuit point from the current lane to the target lane
Behavior Combination • Combine acceleration contributions from – Cruising behavior – Following behavior – Intersection behavior • Combine steering angle contributions from – Tracking behavior – Lane changing behavior
Solve Disturbances between Component Behaviors • The switch in leaders when a vehicle leaves one lane and enters another – Abrupt acceleration change – Start two copies of following behavior • Following behavior stops lane changing progress – Relaxing following distance
Solve Disturbances between Component Behaviors (Cont. ) • Following behavior unnecessarily slows down lane changing process – Disable following behavior in the original lane when it has a clear trajectory to the target lane – Visibility computation in DO plane
Contributions • An accurate, efficient, robust roadway model – Ribbon network – Arc length parameterization – Efficient mapping between ribbon and Cartesian coordinates • A framework for modeling behaviors – Ribbon based tracking – Path based behaviors – Route as a strategic goal
Future Work • Accuracy, efficiency, and robustness of geometric computations for off-road objects • Efficient model for non-oriented navigable surfaces, i. e. , intersections • Good pursuit point control • Behavior diversity • Non autonomous behaviors
- Slides: 43