Skip to content
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

feat(proccesing_time_visualizer): use autoware_internal_debug_msgs #222

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion common/autoware_debug_tools/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ This package provides tools for debugging Autoware.

## Processing Time Visualizer

This tool visualizes `tier4_debug_msgs/msg/ProcessingTimeTree` messages.
This tool visualizes `autoware_internal_debug_msgs/msg/ProcessingTimeTree` messages.

### Usage

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
import rclpy
import rclpy.executors
from rclpy.node import Node
from tier4_debug_msgs.msg import ProcessingTimeTree as ProcessingTimeTreeMsg
from autoware_internal_debug_msgs.msg import ProcessingTimeTree as ProcessingTimeTreeMsg

from .print_tree import print_trees
from .topic_selector import select_topic
Expand All @@ -27,10 +27,10 @@
self.trees: Dict[str, ProcessingTimeTree] = {}
self.worst_case_tree: Dict[str, ProcessingTimeTree] = {}
self.total_tree: Dict[str, ProcessingTimeTree] = {}
self.stdcscr = init_curses()

Check warning on line 30 in common/autoware_debug_tools/autoware_debug_tools/processing_time_visualizer/node.py

View workflow job for this annotation

GitHub Actions / spell-check-differential

Unknown word (stdcscr)
self.show_comment = False
self.summarize_output = True
print_trees("🌲 Processing Time Tree 🌲", self.topic_name, self.trees, self.stdcscr)

Check warning on line 33 in common/autoware_debug_tools/autoware_debug_tools/processing_time_visualizer/node.py

View workflow job for this annotation

GitHub Actions / spell-check-differential

Unknown word (stdcscr)

self.create_timer(0.1, self.update_screen)

Expand All @@ -40,7 +40,7 @@
for topic_name, topic_types in self.get_topic_names_and_types():
if (
topic_name == self.topic_name
and "tier4_debug_msgs/msg/ProcessingTimeTree" in topic_types
and "autoware_internal_debug_msgs/msg/ProcessingTimeTree" in topic_types
):
topic_found = True
break
Expand All @@ -63,7 +63,7 @@
for topic_name, topic_types in self.get_topic_names_and_types():
for topic_type in topic_types:
if (
topic_type == "tier4_debug_msgs/msg/ProcessingTimeTree"
topic_type == "autoware_internal_debug_msgs/msg/ProcessingTimeTree"
and topic_name not in topics
):
topics.append(topic_name)
Expand All @@ -87,7 +87,7 @@
return subscriber

def update_screen(self):
key = self.stdcscr.getch()

Check warning on line 90 in common/autoware_debug_tools/autoware_debug_tools/processing_time_visualizer/node.py

View workflow job for this annotation

GitHub Actions / spell-check-differential

Unknown word (stdcscr)

self.show_comment = not self.show_comment if key == ord("c") else self.show_comment
self.summarize_output = (
Expand All @@ -97,7 +97,7 @@
"🌲 Processing Time Tree 🌲",
self.topic_name,
self.trees.values(),
self.stdcscr,

Check warning on line 100 in common/autoware_debug_tools/autoware_debug_tools/processing_time_visualizer/node.py

View workflow job for this annotation

GitHub Actions / spell-check-differential

Unknown word (stdcscr)
self.show_comment,
self.summarize_output,
)
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
from typing import Dict

from tier4_debug_msgs.msg import ProcessingTimeTree as ProcessingTimeTreeMsg
from autoware_internal_debug_msgs.msg import ProcessingTimeTree as ProcessingTimeTreeMsg


class ProcessingTimeTree:
Expand Down
Loading