Skip to content

Commit c849544

Browse files
committed
remove viz
1 parent ac16563 commit c849544

4 files changed

Lines changed: 7 additions & 14 deletions

File tree

GEMstack/onboard/perception/pedestrian_detection.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -401,6 +401,9 @@ def create_agent_states(self, obj_centers: List[np.ndarray], obj_dims: List[np.n
401401
if (obj_centers[idx].size == 0) or (obj_dims[0].size == 0):
402402
del obj_centers[idx]
403403
del obj_dims[idx]
404+
elif (obj_centers[idx].size != obj_dims[0].size):
405+
del obj_centers[idx]
406+
del obj_dims[idx]
404407

405408
# Create list of agent states in current vehicle frame:
406409
agents = []

GEMstack/onboard/visualization/mpl_visualization.py

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@
55
import matplotlib.animation as animation
66
import time
77
from collections import deque
8-
from ...state.agent import AgentEnum
98

109
class MPLVisualization(Component):
1110
"""Runs a matplotlib visualization at 10Hz.
@@ -77,14 +76,7 @@ def update(self, state):
7776
return
7877
self.num_updates += 1
7978
self.debug("vehicle","velocity",state.vehicle.v)
80-
self.debug("vehicle","front wheel angle",state.vehicle.front_wheel_angle)
81-
82-
# Add pedestrian tracking
83-
for agent_id, agent in state.agents.items():
84-
if agent.type == AgentEnum.PEDESTRIAN:
85-
self.debug(f"ped_{agent_id}", "x", agent.pose.x)
86-
self.debug(f"ped_{agent_id}", "y", agent.pose.y)
87-
79+
self.debug("vehicle","front wheel angle",state.vehicle.front_wheel_angle)
8880
time_str = time.strftime("%Y-%m-%d %H:%M:%S", time.localtime(state.t))
8981
#frame=ObjectFrameEnum.CURRENT
9082
#state = state.to_frame(frame)

launch/fixed_route.yaml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,6 @@ variants:
7474
agent_detection : OmniscientAgentDetector
7575
visualization: !include "klampt_visualization.yaml"
7676
#visualization: !include "mpl_visualization.yaml"
77-
visualization: [!include "klampt_visualization.yaml", !include "mpl_visualization.yaml"]
7877
log_ros:
7978
log:
8079
ros_topics : !include "../GEMstack/knowledge/defaults/standard_ros_topics.yaml"

launch/pedestrian_detection.yaml

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -57,10 +57,9 @@ variants:
5757
detector_only:
5858
run:
5959
description: "Run the pedestrian detection code"
60-
drive:
61-
planning:
62-
trajectory_tracking:
63-
visualization: !include "mpl_visualization.yaml"
60+
drive:
61+
planning:
62+
trajectory_tracking:
6463
real_sim:
6564
run:
6665
description: "Run the pedestrian detection code with real detection and fake simulation"

0 commit comments

Comments
 (0)