-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
db3da67
commit 272ca95
Showing
16 changed files
with
487 additions
and
48 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
<launch> | ||
<arg name="bag_file" default="" /> | ||
<arg name="results_file" default="$(arg bag_file).odometry.hdf5" /> | ||
<arg name="camera_model" default="double_sphere" /> | ||
<arg name="camera_params" default="{fx: 295.936, fy: 295.936, cx: 512, cy: 512, chi: 0.3, alpha: 0.6666667}" /> | ||
<arg name="rate" default="1" /> | ||
<node pkg="omni_slam_eval" type="omni_slam_odometry_eval_node" name="omni_slam_odometry_eval_node" required="true" output="screen"> | ||
<param name="bag_file" value="$(arg bag_file)" /> | ||
<param name="results_file" value="$(arg results_file)" /> | ||
<param name="image_topic" value="/unity_ros/Sphere/FisheyeCamera/image_raw" /> | ||
<param name="depth_image_topic" value="/unity_ros/Sphere/FisheyeDepthCamera/image_raw" /> | ||
<param name="pose_topic" value="/unity_ros/Sphere/TrueState/pose" /> | ||
<param name="tracked_image_topic" value="/omni_slam/tracked" /> | ||
<param name="odometry_topic" value="/omni_slam/odometry" /> | ||
<param name="odometry_ground_truth_topic" value="/omni_slam/odometry_truth" /> | ||
<param name="rate" value="$(arg rate)" /> | ||
<rosparam subst_value="true"> | ||
camera_model: '$(arg camera_model)' | ||
camera_parameters: $(arg camera_params) | ||
detector_type: 'GFTT' | ||
detector_parameters: {maxCorners: 5000, qualityLevel: 0.001, minDistance: 5, blockSize: 5} | ||
tracker_window_size: 128 | ||
tracker_num_scales: 4 | ||
tracker_delta_pixel_error_threshold: 3.0 | ||
tracker_error_threshold: 20.0 | ||
min_features_per_region: 10 | ||
pnp_inlier_threshold: 5.0 | ||
pnp_iterations: 1000 | ||
bundle_adjustment_max_iterations: 1000 | ||
bundle_adjustment_logging: true | ||
</rosparam> | ||
</node> | ||
</launch> | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
#include "odometry_module.h" | ||
|
||
using namespace std; | ||
|
||
namespace omni_slam | ||
{ | ||
namespace module | ||
{ | ||
|
||
OdometryModule::OdometryModule(std::unique_ptr<odometry::PNP> &pnp) | ||
: pnp_(std::move(pnp)) | ||
{ | ||
} | ||
|
||
OdometryModule::OdometryModule(std::unique_ptr<odometry::PNP> &&pnp) | ||
: OdometryModule(pnp) | ||
{ | ||
} | ||
|
||
void OdometryModule::Update(std::vector<data::Landmark> &landmarks, data::Frame &frame) | ||
{ | ||
pnp_->Compute(landmarks, frame); | ||
} | ||
|
||
OdometryModule::Stats& OdometryModule::GetStats() | ||
{ | ||
return stats_; | ||
} | ||
|
||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
#ifndef _ODOMETRY_MODULE_H_ | ||
#define _ODOMETRY_MODULE_H_ | ||
|
||
#include <vector> | ||
#include <set> | ||
#include <memory> | ||
|
||
#include "odometry/pnp.h" | ||
#include "data/landmark.h" | ||
|
||
#include <pcl/common/projection_matrix.h> | ||
#include <pcl/point_types.h> | ||
|
||
using namespace Eigen; | ||
|
||
namespace omni_slam | ||
{ | ||
namespace module | ||
{ | ||
|
||
class OdometryModule | ||
{ | ||
public: | ||
struct Stats | ||
{ | ||
}; | ||
|
||
OdometryModule(std::unique_ptr<odometry::PNP> &pnp); | ||
OdometryModule(std::unique_ptr<odometry::PNP> &&pnp); | ||
|
||
void Update(std::vector<data::Landmark> &landmarks, data::Frame &frame); | ||
|
||
Stats& GetStats(); | ||
|
||
private: | ||
std::shared_ptr<odometry::PNP> pnp_; | ||
|
||
Stats stats_; | ||
}; | ||
|
||
} | ||
} | ||
|
||
#endif /* _ODOMETRY_MODULE_H_ */ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.