Skip to content
Snippets Groups Projects
Commit 85204425 authored by Joaquim Casals Buñuel's avatar Joaquim Casals Buñuel
Browse files

Revert "Add check sensor type processors"

This reverts commit 12bc2974.
parent 6ca3e505
No related branches found
No related tags found
No related merge requests found
Pipeline #5249 failed
......@@ -42,7 +42,7 @@ class ProcessorOdom2d : public ProcessorMotion
public:
ProcessorOdom2d(ParamsProcessorOdom2dPtr _params);
virtual ~ProcessorOdom2d();
virtual void configure(SensorBasePtr _sensor) override;
virtual void configure(SensorBasePtr _sensor) override { };
// Factory method for high level API
WOLF_PROCESSOR_CREATE(ProcessorOdom2d, ParamsProcessorOdom2d);
......
......@@ -36,8 +36,7 @@ void ProcessorDiffDrive::configure(SensorBasePtr _sensor)
{
assert(_sensor && "Provided sensor is nullptr");
SensorDiffDriveConstPtr sensor_diff_drive = std::dynamic_pointer_cast<SensorDiffDrive>(_sensor);
assert(sensor_diff_drive != nullptr && "Sensor is not of type SensorDiffDrive");
SensorDiffDriveConstPtr sensor_diff_drive = std::static_pointer_cast<SensorDiffDrive>(_sensor);
radians_per_tick_ = sensor_diff_drive->getRadiansPerTick();
}
......
......@@ -16,11 +16,6 @@ ProcessorOdom2d::~ProcessorOdom2d()
{
}
void ProcessorOdom2d::configure(SensorBasePtr _sensor)
{
auto sensor_ = std::dynamic_pointer_cast<SensorOdom2d>(_sensor);
assert(sensor_ != nullptr && "Sensor is not of type SensorOdom2d");
}
void ProcessorOdom2d::computeCurrentDelta(const Eigen::VectorXd& _data, const Eigen::MatrixXd& _data_cov,
const Eigen::VectorXd& _calib, const double _dt, Eigen::VectorXd& _delta,
Eigen::MatrixXd& _delta_cov, Eigen::MatrixXd& _jacobian_calib) const
......
......@@ -21,8 +21,8 @@ ProcessorOdom3d::~ProcessorOdom3d()
void ProcessorOdom3d::configure(SensorBasePtr _sensor)
{
assert (_sensor && "Trying to configure processor with a sensor but provided sensor is nullptr.");
auto sen_ptr = std::dynamic_pointer_cast<SensorOdom3d>(_sensor);
assert(sen_ptr != nullptr && "Sensor is not of type SensorOdom3d");
SensorOdom3dPtr sen_ptr = std::static_pointer_cast<SensorOdom3d>(_sensor);
// we steal the parameters from the provided odom3d sensor.
k_disp_to_disp_ = sen_ptr->getDispVarToDispNoiseFactor();
......@@ -151,7 +151,7 @@ void ProcessorOdom3d::deltaPlusDelta(const Eigen::VectorXd& _delta1, const Eigen
void ProcessorOdom3d::statePlusDelta(const Eigen::VectorXd& _x, const Eigen::VectorXd& _delta, const double _Dt,
Eigen::VectorXd& _x_plus_delta) const
{
{
assert(_x.size() >= x_size_ && "Wrong _x vector size"); //we need a state vector which size is at least x_size_
assert(_delta.size() == delta_size_ && "Wrong _delta vector size");
assert(_x_plus_delta.size() >= x_size_ && "Wrong _x_plus_delta vector size");
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment