Apollo 10.0
自动驾驶开放平台
conti_ars_preprocessor.h
浏览该文件的文档.
1/******************************************************************************
2 * Copyright 2018 The Apollo Authors. All Rights Reserved.
3 *
4 * Licensed under the Apache License, Version 2.0 (the License);
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
7 *
8 * http://www.apache.org/licenses/LICENSE-2.0
9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an AS IS BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 *****************************************************************************/
16#pragma once
17
18#include <string>
19#include <unordered_map>
20
21#include "cyber/common/macros.h"
23
24namespace apollo {
25namespace perception {
26namespace radar {
27
29 public:
30 ContiArsPreprocessor() : BasePreprocessor(), delay_time_(0.0) {}
32
40 bool Init(const PreprocessorInitOptions& options) override;
41
51 bool Preprocess(const drivers::ContiRadar& raw_obstacles,
52 const PreprocessorOptions& options,
53 drivers::ContiRadar* corrected_obstacles) override;
54
60 std::string Name() const override { return "ContiArsPreprocessor"; }
61
67 inline double GetDelayTime() { return delay_time_; }
68
69 private:
70 void SkipObjects(const drivers::ContiRadar& raw_obstacles,
71 drivers::ContiRadar* corrected_obstacles);
72 void ExpandIds(drivers::ContiRadar* corrected_obstacles);
73 void CorrectTime(drivers::ContiRadar* corrected_obstacles);
74 int GetNextId();
75
76 float delay_time_ = 0.0f;
77 static int current_idx_;
78 static std::unordered_map<int, int> local2global_;
79
81
83};
84
85} // namespace radar
86} // namespace perception
87} // namespace apollo
std::string Name() const override
The name of the ContiArsPreprocessor
bool Init(const PreprocessorInitOptions &options) override
Init ContiArsPreprocessor config
bool Preprocess(const drivers::ContiRadar &raw_obstacles, const PreprocessorOptions &options, drivers::ContiRadar *corrected_obstacles) override
Correct radar raw obstacles.
#define DISALLOW_COPY_AND_ASSIGN(classname)
Definition macros.h:48
class register implement
Definition arena_queue.h:37