Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
Signed-off-by: Takamasa Horibe <horibe.takamasa@gmail.com>
  • Loading branch information
TakaHoribe committed Jul 21, 2022
1 parent 5515dd5 commit ef3a045
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -86,13 +86,13 @@ class TrajectoryAnalyzer

TrajectoryDebugInfo data;
data.stamp = node_->now();
data.size = points.size();
data.curvature = calcCurvature(points);
const auto arclength_offset = motion_utils::calcSignedArcLength(points, 0, ego_p);
data.arclength = calcPathArcLengthArray(points, -arclength_offset);
data.velocity = getVelocityArray(points);

const auto s = data.curvature.size();
if (s != data.arclength.size() || s != data.velocity.size()) {
if (data.size != data.arclength.size() || data.size != data.velocity.size()) {
RCLCPP_ERROR(node_->get_logger(), "computation failed.");
return;
}
Expand Down
1 change: 1 addition & 0 deletions planning/planning_debug_tools/msg/TrajectoryDebugInfo.msg
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
builtin_interfaces/Time stamp
uint32 size
float64[] arclength
float64[] curvature
float64[] velocity

0 comments on commit ef3a045

Please sign in to comment.