Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
Pinoxchio
apollo
提交
68c10d1e
A
apollo
项目概览
Pinoxchio
/
apollo
与 Fork 源项目一致
从无法访问的项目Fork
通知
2
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
A
apollo
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
68c10d1e
编写于
11月 14, 2019
作者:
X
Xiangquan Xiao
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Prediction: Migrate StrCat to absl::StrCat.
上级
7b15ac20
变更
4
隐藏空白更改
内联
并排
Showing
4 changed file
with
16 addition
and
16 deletion
+16
-16
modules/prediction/common/feature_output.cc
modules/prediction/common/feature_output.cc
+11
-12
modules/prediction/common/road_graph.cc
modules/prediction/common/road_graph.cc
+2
-2
modules/prediction/container/obstacles/obstacle_test.cc
modules/prediction/container/obstacles/obstacle_test.cc
+2
-2
modules/tools/manual_traffic_light/manual_traffic_light.cc
modules/tools/manual_traffic_light/manual_traffic_light.cc
+1
-0
未找到文件。
modules/prediction/common/feature_output.cc
浏览文件 @
68c10d1e
...
...
@@ -18,15 +18,14 @@
#include <vector>
#include "absl/strings/str_cat.h"
#include "cyber/common/file.h"
#include "modules/common/util/string_util.h"
#include "modules/prediction/common/prediction_system_gflags.h"
namespace
apollo
{
namespace
prediction
{
using
apollo
::
common
::
TrajectoryPoint
;
using
apollo
::
common
::
util
::
StrCat
;
Features
FeatureOutput
::
features_
;
ListDataForLearning
FeatureOutput
::
list_data_for_learning_
;
...
...
@@ -162,8 +161,8 @@ void FeatureOutput::WriteFeatureProto() {
if
(
features_
.
feature
().
empty
())
{
ADEBUG
<<
"Skip writing empty feature."
;
}
else
{
const
std
::
string
file_name
=
StrCat
(
FLAGS_prediction_data_dir
,
"/feature."
,
idx_feature_
,
".bin"
);
const
std
::
string
file_name
=
absl
::
StrCat
(
FLAGS_prediction_data_dir
,
"/feature."
,
idx_feature_
,
".bin"
);
cyber
::
common
::
SetProtoToBinaryFile
(
features_
,
file_name
);
features_
.
Clear
();
++
idx_feature_
;
...
...
@@ -174,8 +173,8 @@ void FeatureOutput::WriteDataForLearning() {
if
(
list_data_for_learning_
.
data_for_learning
().
empty
())
{
ADEBUG
<<
"Skip writing empty data_for_learning."
;
}
else
{
const
std
::
string
file_name
=
StrCat
(
FLAGS_prediction_data_dir
,
"/datalearn."
,
idx_learning_
,
".bin"
);
const
std
::
string
file_name
=
absl
::
StrCat
(
FLAGS_prediction_data_dir
,
"/datalearn."
,
idx_learning_
,
".bin"
);
cyber
::
common
::
SetProtoToBinaryFile
(
list_data_for_learning_
,
file_name
);
list_data_for_learning_
.
Clear
();
++
idx_learning_
;
...
...
@@ -187,8 +186,8 @@ void FeatureOutput::WritePredictionResult() {
ADEBUG
<<
"Skip writing empty prediction_result."
;
}
else
{
const
std
::
string
file_name
=
StrCat
(
FLAGS_prediction_data_dir
,
"/prediction_result."
,
idx_prediction_result_
,
".bin"
);
absl
::
StrCat
(
FLAGS_prediction_data_dir
,
"/prediction_result."
,
idx_prediction_result_
,
".bin"
);
cyber
::
common
::
SetProtoToBinaryFile
(
list_prediction_result_
,
file_name
);
list_prediction_result_
.
Clear
();
++
idx_prediction_result_
;
...
...
@@ -199,8 +198,8 @@ void FeatureOutput::WriteFrameEnv() {
if
(
list_frame_env_
.
frame_env
().
empty
())
{
ADEBUG
<<
"Skip writing empty prediction_result."
;
}
else
{
const
std
::
string
file_name
=
StrCat
(
FLAGS_prediction_data_dir
,
"/frame_env."
,
idx_frame_env_
,
".bin"
);
const
std
::
string
file_name
=
absl
::
StrCat
(
FLAGS_prediction_data_dir
,
"/frame_env."
,
idx_frame_env_
,
".bin"
);
cyber
::
common
::
SetProtoToBinaryFile
(
list_frame_env_
,
file_name
);
list_frame_env_
.
Clear
();
++
idx_frame_env_
;
...
...
@@ -212,8 +211,8 @@ void FeatureOutput::WriteDataForTuning() {
ADEBUG
<<
"Skip writing empty data_for_tuning."
;
return
;
}
const
std
::
string
file_name
=
StrCat
(
FLAGS_prediction_data_dir
,
"/datatuning."
,
idx_tuning_
,
".bin"
);
const
std
::
string
file_name
=
absl
::
StrCat
(
FLAGS_prediction_data_dir
,
"/datatuning."
,
idx_tuning_
,
".bin"
);
cyber
::
common
::
SetProtoToBinaryFile
(
list_data_for_tuning_
,
file_name
);
list_data_for_tuning_
.
Clear
();
++
idx_tuning_
;
...
...
modules/prediction/common/road_graph.cc
浏览文件 @
68c10d1e
...
...
@@ -94,7 +94,7 @@ RoadGraph::RoadGraph(const double start_s, const double length,
Status
RoadGraph
::
BuildLaneGraph
(
LaneGraph
*
const
lane_graph_ptr
)
{
// Sanity checks.
if
(
length_
<
0.0
||
lane_info_ptr_
==
nullptr
)
{
const
auto
error_msg
=
common
::
uti
l
::
StrCat
(
const
auto
error_msg
=
abs
l
::
StrCat
(
"Invalid road graph settings. Road graph length = "
,
length_
);
AERROR
<<
error_msg
;
return
Status
(
ErrorCode
::
PREDICTION_ERROR
,
error_msg
);
...
...
@@ -118,7 +118,7 @@ Status RoadGraph::BuildLaneGraph(LaneGraph* const lane_graph_ptr) {
Status
RoadGraph
::
BuildLaneGraphBidirection
(
LaneGraph
*
const
lane_graph_ptr
)
{
// Sanity checks.
if
(
length_
<
0.0
||
lane_info_ptr_
==
nullptr
)
{
const
auto
error_msg
=
common
::
uti
l
::
StrCat
(
const
auto
error_msg
=
abs
l
::
StrCat
(
"Invalid road graph settings. Road graph length = "
,
length_
);
AERROR
<<
error_msg
;
return
Status
(
ErrorCode
::
PREDICTION_ERROR
,
error_msg
);
...
...
modules/prediction/container/obstacles/obstacle_test.cc
浏览文件 @
68c10d1e
...
...
@@ -14,8 +14,8 @@
* limitations under the License.
*****************************************************************************/
#include "absl/strings/str_cat.h"
#include "cyber/common/file.h"
#include "modules/common/util/string_util.h"
#include "modules/prediction/common/kml_map_based_test.h"
#include "modules/prediction/common/prediction_gflags.h"
#include "modules/prediction/container/obstacles/obstacles_container.h"
...
...
@@ -36,7 +36,7 @@ class ObstacleTest : public KMLMapBasedTest {
int
num_frame
=
3
;
for
(
int
i
=
1
;
i
<=
num_frame
;
++
i
)
{
const
auto
filename
=
common
::
uti
l
::
StrCat
(
const
auto
filename
=
abs
l
::
StrCat
(
"modules/prediction/testdata/frame_sequence/frame_"
,
i
,
".pb.txt"
);
perception
::
PerceptionObstacles
perception_obstacles
;
cyber
::
common
::
GetProtoFromFile
(
filename
,
&
perception_obstacles
);
...
...
modules/tools/manual_traffic_light/manual_traffic_light.cc
浏览文件 @
68c10d1e
...
...
@@ -22,6 +22,7 @@
#include "modules/common/adapters/adapter_gflags.h"
#include "modules/common/util/color.h"
#include "modules/common/util/message_util.h"
#include "modules/common/util/string_util.h"
#include "modules/map/hdmap/adapter/opendrive_adapter.h"
#include "modules/map/hdmap/hdmap_util.h"
#include "modules/perception/proto/traffic_light_detection.pb.h"
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录