提交 ac6f203c 编写于 作者: C changsh726 提交者: Liu Jiaming

{Drivers,Perception}: fix typo

上级 3feb611e
......@@ -5,7 +5,7 @@ package apollo.drivers.hesai;
import "modules/common/proto/header.proto";
enum Model {
UNKOWN = 0;
UNKNOWN = 0;
HESAI40P = 1;
HESAI64 = 2;
}
......
......@@ -5,7 +5,7 @@ package apollo.drivers.velodyne;
import "modules/common/proto/header.proto";
enum Model {
UNKOWN = 0;
UNKNOWN = 0;
HDL64E_S3S = 1;
HDL64E_S3D = 2;
HDL64E_S2 = 3;
......
......@@ -3,7 +3,7 @@ syntax = "proto2";
package apollo.drivers.microphone.config;
enum ChannelType {
UNKOWN = 0;
UNKNOWN = 0;
ASR = 1; // Automatic Speech Recognition
RAW = 2;
PLAYBACK = 3;
......@@ -11,7 +11,7 @@ enum ChannelType {
message MicrophoneConfig {
enum MicrophoneModel {
UNKOWN = 0;
UNKNOWN = 0;
RESPEAKER = 1;
}
optional MicrophoneModel microphone_model = 2;
......
......@@ -14,12 +14,13 @@
* limitations under the License.
*****************************************************************************/
#include "modules/perception/fusion/common/dst_evidence.h"
#include <boost/format.hpp>
#include "cyber/common/log.h"
#include "gtest/gtest.h"
#include "modules/perception/fusion/common/dst_evidence.h"
#include "cyber/common/log.h"
namespace apollo {
namespace perception {
......@@ -27,14 +28,15 @@ namespace fusion {
// elementary hypotheses
enum { F111 = (1 << 0), FA18 = (1 << 1), P3C = (1 << 2) };
// compound hypotheses
enum { FAST = (F111 | FA18), UNKOWN = (F111 | FA18 | P3C) };
enum { FAST = (F111 | FA18), UNKNOWN = (F111 | FA18 | P3C) };
static const std::vector<uint64_t> fod_subsets = {F111, FA18, P3C, FAST,
UNKOWN};
static const std::map<uint64_t, std::string> hypo_names = {{F111, "F111"},
{FA18, "FA18"},
{P3C, "P3C"},
{FAST, "FAST"},
{UNKOWN, "UNKOWN"}};
UNKNOWN};
static const std::map<uint64_t, std::string> hypo_names = {
{F111, "F111"},
{FA18, "FA18"},
{P3C, "P3C"},
{FAST, "FAST"},
{UNKNOWN, "UNKNOWN"}};
class DSTEvidenceTest : public ::testing::Test {
public:
......@@ -42,7 +44,7 @@ class DSTEvidenceTest : public ::testing::Test {
: sensor1_dst_("test"), sensor2_dst_("test"), fused_dst_("test") {
DstManager *dst_manager = DstManager::Instance();
std::vector<std::string> fod_subset_names = {"F111", "FA18", "P3C", "FAST",
"UNKOWN"};
"UNKNOWN"};
dst_manager->AddApp("test", fod_subsets, fod_subset_names);
vec_equal_ = [](const std::vector<double> &vec,
const std::vector<double> &gt) {
......@@ -70,7 +72,7 @@ class DSTEvidenceTest : public ::testing::Test {
}
void assign_dst_test() {
std::map<uint64_t, double> dst_map = {
{F111, 0.3}, {FA18, 0.18}, {FAST, 0.42}, {UNKOWN, 0.1}};
{F111, 0.3}, {FA18, 0.18}, {FAST, 0.42}, {UNKNOWN, 0.1}};
std::vector<double> dst_vec_gt = {0.3, 0.18, 0.00, 0.42, 0.1};
Dst dst("test");
dst.SetBba(dst_map);
......
......@@ -103,7 +103,7 @@ void DstExistenceFusion::UpdateWithMeasurement(
Dst existence_evidence(fused_existence_.Name());
existence_evidence.SetBba(
{{ExistenceDstMaps::EXIST, obj_exist_prob},
{ExistenceDstMaps::EXISTUNKOWN, 1 - obj_exist_prob}});
{ExistenceDstMaps::EXISTUNKNOWN, 1 - obj_exist_prob}});
// TODO(all) hard code for fused exist bba
const double exist_fused_w = 1.0;
ADEBUG << " before update exist prob: " << GetExistenceProbability();
......@@ -147,7 +147,7 @@ void DstExistenceFusion::UpdateWithoutMeasurement(const std::string &sensor_id,
double obj_unexist_prob = unexist_factor * dist_decay;
existence_evidence.SetBba(
{{ExistenceDstMaps::NEXIST, obj_unexist_prob},
{ExistenceDstMaps::EXISTUNKOWN, 1 - obj_unexist_prob}});
{ExistenceDstMaps::EXISTUNKNOWN, 1 - obj_unexist_prob}});
// TODO(all) hard code for fused exist bba
const double unexist_fused_w = 1.0;
double min_match_dist_score = min_match_dist;
......@@ -283,7 +283,7 @@ void DstExistenceFusion::UpdateToicWithoutCameraMeasurement(
Dst toic_evidence(fused_toic_.Name());
toic_evidence.SetBba({{ToicDstMaps::NTOIC, 1 - dist_score},
{ToicDstMaps::TOICUNKOWN, dist_score}});
{ToicDstMaps::TOICUNKNOWN, dist_score}});
// TODO(yuantingrong): hard code for fused toic bba
const double toic_fused_w = 1.0;
fused_toic_ = fused_toic_ + toic_evidence * in_view_ratio * toic_fused_w;
......@@ -334,7 +334,7 @@ void DstExistenceFusion::UpdateToicWithCameraMeasurement(
Dst toic_evidence(fused_toic_.Name());
toic_evidence.SetBba({{ToicDstMaps::TOIC, association_prob},
{ToicDstMaps::TOICUNKOWN, 1 - association_prob}});
{ToicDstMaps::TOICUNKNOWN, 1 - association_prob}});
// TODO(yuantingrong): hard code for fused toic bba
const double toic_fused_w = 0.7;
fused_toic_ = fused_toic_ + toic_evidence * toic_fused_w * in_view_ratio;
......
......@@ -28,15 +28,15 @@ namespace fusion {
struct ToicDstMaps {
// for (N)TOIC: (not)target of interest in camera judgement
enum { TOIC = (1 << 0), NTOIC = (1 << 1), TOICUNKOWN = (TOIC | NTOIC) };
std::vector<uint64_t> fod_subsets_ = {TOIC, NTOIC, TOICUNKOWN};
std::vector<std::string> subset_names_ = {"TOIC", "NTOIC", "TOICUNKOWN"};
enum { TOIC = (1 << 0), NTOIC = (1 << 1), TOICUNKNOWN = (TOIC | NTOIC) };
std::vector<uint64_t> fod_subsets_ = {TOIC, NTOIC, TOICUNKNOWN};
std::vector<std::string> subset_names_ = {"TOIC", "NTOIC", "TOICUNKNOWN"};
};
struct ExistenceDstMaps {
enum { EXIST = (1 << 0), NEXIST = (1 << 1), EXISTUNKOWN = (EXIST | NEXIST) };
std::vector<uint64_t> fod_subsets_ = {EXIST, NEXIST, EXISTUNKOWN};
std::vector<std::string> subset_names_ = {"EXIST", "NEXIST", "EXISTUNKOWN"};
enum { EXIST = (1 << 0), NEXIST = (1 << 1), EXISTUNKNOWN = (EXIST | NEXIST) };
std::vector<uint64_t> fod_subsets_ = {EXIST, NEXIST, EXISTUNKNOWN};
std::vector<std::string> subset_names_ = {"EXIST", "NEXIST", "EXISTUNKNOWN"};
};
struct DstExistenceFusionOptions {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册