-
Notifications
You must be signed in to change notification settings - Fork 15
Z-axis support integration #262
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: 3.0
Are you sure you want to change the base?
Conversation
Screen.Recording.2026-01-16.at.3.40.01.PM.movHere's how everything looks (Its with goal resampling). |
Greptile SummaryThis PR adds comprehensive 3D spatial awareness to the driving environment, enabling agents to navigate maps with elevation changes like bridges and overpasses. Key Changes:
Critical Issues:
Other Observations:
Confidence Score: 2/5
Important Files Changed
Sequence DiagramsequenceDiagram
participant Agent
participant move_dynamics
participant checkNeighbors
participant compute_z_distance
participant qsort
participant compute_observations
participant collision_check
participant check_z_collision
Note over Agent,check_z_collision: 3D Spatial Processing Flow
Agent->>move_dynamics: Update position (x, y)
move_dynamics->>checkNeighbors: Get nearby road segments (15x15 grid)
checkNeighbors-->>move_dynamics: GridMapEntity list
loop For each road segment
move_dynamics->>compute_z_distance: Calculate z-distance
compute_z_distance-->>move_dynamics: DepthPoint{dis, z}
end
move_dynamics->>qsort: Sort by distance
qsort-->>move_dynamics: Sorted DepthPoints
Note over move_dynamics: Find max gap in distances<br/>Average z-coords up to gap
move_dynamics->>Agent: Set agent.z
Agent->>compute_observations: Generate observations
Note over compute_observations: Ego: 8 features (x,y,z,vx,vy,heading_x,heading_y,speed)<br/>Partners: 8 features each (rel_x,rel_y,rel_z,w,l,heading_x,heading_y,speed)<br/>Road: 8 features each (rel_x,rel_y,rel_z,length,width,cos,sin,type)
compute_observations-->>Agent: 3D observations
Agent->>collision_check: Check collisions
collision_check->>collision_check: AABB collision (2D)
alt AABB collision detected
collision_check->>Agent: Set aabb_collision_state=1
collision_check->>check_z_collision: Check z-overlap
alt Z-ranges overlap
check_z_collision-->>collision_check: True collision
collision_check->>Agent: Set collision_state=1
else Z-ranges separated
check_z_collision-->>collision_check: No collision
Note over Agent: Different vertical levels<br/>(e.g., bridge/underpass)
end
end
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Additional Comments (1)
-
pufferlib/ocean/drive/drive.h, line 93-95 (link)style: Feature counts updated from 7→8 for classic and 10→11 for jerk to include z-coordinate in observations.
20 files reviewed, 3 comments
This PR contains the following new features -
demo()function indrive.c, and the other render views can now support 3D contour depending on the mapSome Carla maps are also added/updated to match their latest versions.