Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Problem when try to run with my own bag #8

Open
maxwu8416 opened this issue Jul 4, 2019 · 1 comment
Open

Problem when try to run with my own bag #8

maxwu8416 opened this issue Jul 4, 2019 · 1 comment

Comments

@maxwu8416
Copy link

hi ~
Thanks for your great works and sharing it !
Recent days i was try to run your optimized VINS-MONO with my own bag file, there shows some problem i still cannot figure it out.
And the problem is when i launch the vins_estimator by the command in terminal

roslaunch vins_estimator realsense_color.launch

it seems nothing error message shows up, and then i play the bag file, there has image in "tracked image" window(/attention_viewer/output), but the image was rgb image not the grayscale image then i think that's why there has no feature point detected on it.

vins_rviz_config rviz- - RViz_030

My camera hardware : Intel realsense zr300

Launch file i changed:

pwd/vins_estimator/launch/realsense_color.launch

<launch>
    <arg name="config_path" default = "$(find feature_tracker)/../config/realsense/realsense_color_config.yaml" />
	<arg name="vins_path" default = "$(find feature_tracker)/../" />
    
    <node name="feature_tracker" pkg="feature_tracker" type="feature_tracker" output="log">
        <remap from="feature_tracker/image" to="/zr300_node/color/image_raw" />
        <remap from="feature_tracker/output" to="feature_tracker/feature_img" />
        <param name="config_file" type="string" value="$(find feature_tracker)/config/zr300_color.yaml" />
        <param name="vins_folder" type="string" value="$(arg vins_path)" />
    </node>

    <node name="vins_estimator" pkg="vins_estimator" type="vins_estimator" output="screen">
       <param name="config_file" type="string" value="$(arg config_path)" />
       <param name="vins_folder" type="string" value="$(arg vins_path)" />
    </node>

    <node name="pose_graph" pkg="pose_graph" type="pose_graph" output="screen">
        <param name="config_file" type="string" value="$(arg config_path)" />
        <param name="visualization_shift_x" type="int" value="0" />
        <param name="visualization_shift_y" type="int" value="0" />
        <param name="skip_cnt" type="int" value="0" />
        <param name="skip_dis" type="double" value="0" />
    </node>

   <!-- attention visualization -->
    <node name="attention_viewer" pkg="feature_tracker" type="attention_viewer" output="screen">
        <remap from="attention_viewer/image" to="/zr300_node/color/image_raw" />
        <remap from="attention_viewer/feature" to="feature_tracker/feature" />
        <remap from="attention_viewer/selection_info" to="vins_estimator/selection_info" />
        <param name="config_file" type="string" value="$(find feature_tracker)/config/zr300_color.yaml" />
        <param name="vins_folder" type="string" value="$(arg vins_path)" />
    </node>

</launch>

Config file i changed :

pwd/config/realsense/realsense_color_config.yaml

%YAML:1.0

#common parameters
imu_topic: "/zr300_node/imu"
image_topic: "/zr300_node/color/image_raw"
output_path: "/home/max/vins_mit/src/vins_mit"

add the yaml file under feature_tracker's config folder
/pwd/feature_tracker/config/zr300_color.yaml

%YAML:1.0

#camera calibration 
model_type: PINHOLE
camera_name: camera
image_width: 640
image_height: 480
distrotion_parameter:
  k1: 9.2615504465028850e-02
  k2: -1.8082438825995681e-01
  p1: -6.5484100374765971e-04
  p2: -3.5829351558557421e-04
projection_parameter:
  fx: 6.0970550296798035e+02
  fy: 6.0909579671294716e+02
  cx: 3.1916667152289227e+02
  cy: 2.3558360480225772e+02

# Feature Tracker Parameters
stride: 2           # only process every `stride`th frame 
                    
eqalization: 1      # histogram equalization for lighting variance
                    
border_margin: 1    # ignore the features found in border pixels
                   
min_distance: 30    # GFTT minimum distance 
                    
max_feature: 150    # number of GFTT to maintain
                   
F_reproj_error: 1.0 # reprojection error threshold for findFundamentalMat
                   
@plusk01
Copy link
Owner

plusk01 commented Jul 10, 2019

Your suspicion about the image being color may be valid. This version has a reimplementation of the vins-mono feature tracker. So there are likely edge cases that I did not account for when writing it since I only tested it on the euroc dataset.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants