0.19.1: Added OdometryVINS (VINS-Fusion integration, Odom/Strategy=9)

This commit is contained in:
matlabbe
2019-03-18 20:45:34 -04:00
parent 9c1c88d35e
commit c0a7c3a344
13 changed files with 727 additions and 69 deletions

View File

@@ -5049,7 +5049,7 @@ void MainWindow::startDetection()
_preferencesDialog->getSourceDriver() == PreferencesDialog::kSrcImages) &&
!_preferencesDialog->getIMUPath().isEmpty())
{
if(odomStrategy != Odometry::kTypeOkvis && odomStrategy != Odometry::kTypeMSCKF)
if(odomStrategy != Odometry::kTypeOkvis && odomStrategy != Odometry::kTypeMSCKF && odomStrategy != Odometry::kTypeVINS)
{
QMessageBox::warning(this, tr("Source IMU Path"),
tr("IMU path is set but odometry chosen doesn't support IMU, ignoring IMU..."), QMessageBox::Ok);

View File

@@ -183,6 +183,9 @@ PreferencesDialog::PreferencesDialog(QWidget * parent) :
#ifndef RTABMAP_MSCKF_VIO
_ui->odom_strategy->setItemData(8, 0, Qt::UserRole - 1);
#endif
#ifndef RTABMAP_VINS
_ui->odom_strategy->setItemData(9, 0, Qt::UserRole - 1);
#endif
#if CV_MAJOR_VERSION < 3
_ui->stereosgbm_mode->setItemData(2, 0, Qt::UserRole - 1);
@@ -1175,6 +1178,10 @@ PreferencesDialog::PreferencesDialog(QWidget * parent) :
_ui->OdomMSCKFInitCovExRot->setObjectName(Parameters::kOdomMSCKFInitCovExRot().c_str());
_ui->OdomMSCKFInitCovExTrans->setObjectName(Parameters::kOdomMSCKFInitCovExTrans().c_str());
// Odometry VINS
_ui->lineEdit_OdomVinsPath->setObjectName(Parameters::kOdomVINSConfigPath().c_str());
connect(_ui->toolButton_OdomVinsPath, SIGNAL(clicked()), this, SLOT(changeOdometryVINSConfigPath()));
//Stereo
_ui->stereo_winWidth->setObjectName(Parameters::kStereoWinWidth().c_str());
_ui->stereo_winHeight->setObjectName(Parameters::kStereoWinHeight().c_str());
@@ -4371,6 +4378,23 @@ void PreferencesDialog::changeOdometryOKVISConfigPath()
}
}
void PreferencesDialog::changeOdometryVINSConfigPath()
{
QString path;
if(_ui->lineEdit_OdomVinsPath->text().isEmpty())
{
path = QFileDialog::getOpenFileName(this, tr("VINS-Fusion Config"), this->getWorkingDirectory(), tr("VINS-Fusion config (*.yaml)"));
}
else
{
path = QFileDialog::getOpenFileName(this, tr("VINS-Fusion Config"), _ui->lineEdit_OdomVinsPath->text(), tr("VINS-Fusion config (*.yaml)"));
}
if(!path.isEmpty())
{
_ui->lineEdit_OdomVinsPath->setText(path);
}
}
void PreferencesDialog::changeIcpPMConfigPath()
{
QString path;
@@ -5560,7 +5584,9 @@ void PreferencesDialog::testOdometry()
this->getSourceDriver() == kSrcImages) &&
!_ui->lineEdit_cameraImages_path_imu->text().isEmpty())
{
if(this->getOdomStrategy() != Odometry::kTypeOkvis && this->getOdomStrategy() != Odometry::kTypeMSCKF)
if(this->getOdomStrategy() != Odometry::kTypeOkvis &&
this->getOdomStrategy() != Odometry::kTypeMSCKF &&
this->getOdomStrategy() != Odometry::kTypeVINS)
{
QMessageBox::warning(this, tr("Source IMU Path"),
tr("IMU path is set but odometry chosen doesn't support IMU, ignoring IMU..."), QMessageBox::Ok);

View File

@@ -94,25 +94,16 @@
<property name="geometry">
<rect>
<x>0</x>
<y>-516</y>
<width>680</width>
<height>3082</height>
<y>-631</y>
<width>681</width>
<height>3071</height>
</rect>
</property>
<layout class="QVBoxLayout" name="verticalLayout_16">
<property name="spacing">
<number>0</number>
</property>
<property name="leftMargin">
<number>0</number>
</property>
<property name="topMargin">
<number>0</number>
</property>
<property name="rightMargin">
<number>0</number>
</property>
<property name="bottomMargin">
<property name="margin">
<number>0</number>
</property>
<item>
@@ -5173,16 +5164,7 @@ when using the file type, logs are saved in LogRtabmap.txt (located in the worki
<string>Directory of images (optional settings)</string>
</property>
<layout class="QVBoxLayout" name="verticalLayout_93">
<property name="leftMargin">
<number>0</number>
</property>
<property name="topMargin">
<number>0</number>
</property>
<property name="rightMargin">
<number>0</number>
</property>
<property name="bottomMargin">
<property name="margin">
<number>0</number>
</property>
<item>
@@ -11603,6 +11585,11 @@ If set to false, classic RTAB-Map loop closure detection is done using only imag
<string>MSCKF_VIO</string>
</property>
</item>
<item>
<property name="text">
<string>VINS-Fusion</string>
</property>
</item>
</widget>
</item>
<item row="2" column="1">
@@ -11906,7 +11893,7 @@ If set to false, classic RTAB-Map loop closure detection is done using only imag
<item>
<widget class="QStackedWidget" name="stackedWidget_odometryType">
<property name="currentIndex">
<number>0</number>
<number>9</number>
</property>
<widget class="QWidget" name="page_52">
<layout class="QVBoxLayout" name="verticalLayout_77">
@@ -14944,6 +14931,75 @@ If set to false, classic RTAB-Map loop closure detection is done using only imag
</item>
</layout>
</widget>
<widget class="QWidget" name="page_79">
<layout class="QVBoxLayout" name="verticalLayout_139">
<item>
<widget class="QGroupBox" name="groupBox_odomVINS">
<property name="title">
<string>VINS-Fusion</string>
</property>
<layout class="QVBoxLayout" name="verticalLayout_138" stretch="0,0">
<item>
<widget class="QLabel" name="label_525">
<property name="text">
<string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p&gt;VINS-Fusion: &lt;a href=&quot;https://github.com/HKUST-Aerial-Robotics/VINS-Fusion&quot;&gt;&lt;span style=&quot; text-decoration: underline; color:#0000ff;&quot;&gt;https://github.com/HKUST-Aerial-Robotics/VINS-Fusion&lt;/span&gt;&lt;/a&gt;&lt;/p&gt;&lt;p&gt;IMU input optional depending on the parameters in the config file. Currently tested only with EuRoC data set.&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
</property>
<property name="wordWrap">
<bool>true</bool>
</property>
<property name="openExternalLinks">
<bool>true</bool>
</property>
<property name="textInteractionFlags">
<set>Qt::LinksAccessibleByMouse|Qt::TextSelectableByMouse</set>
</property>
</widget>
</item>
<item>
<layout class="QGridLayout" name="gridLayout_107" columnstretch="0,0,1">
<item row="0" column="1">
<widget class="QLineEdit" name="lineEdit_OdomVinsPath"/>
</item>
<item row="0" column="2">
<widget class="QLabel" name="label_526">
<property name="text">
<string>Path to VINS-Fusion config file (*.yaml). While VINS-Fusion requires calibrations in the config file, they are ignored as those from received images are used instead.</string>
</property>
<property name="wordWrap">
<bool>true</bool>
</property>
<property name="textInteractionFlags">
<set>Qt::LinksAccessibleByMouse|Qt::TextSelectableByMouse</set>
</property>
</widget>
</item>
<item row="0" column="0">
<widget class="QToolButton" name="toolButton_OdomVinsPath">
<property name="text">
<string>...</string>
</property>
</widget>
</item>
</layout>
</item>
</layout>
</widget>
</item>
<item>
<spacer name="verticalSpacer_77">
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>1090</height>
</size>
</property>
</spacer>
</item>
</layout>
</widget>
<widget class="QWidget" name="page_26">
<layout class="QVBoxLayout" name="verticalLayout_88">
<item>
@@ -15883,16 +15939,7 @@ Lower the ratio -&gt; higher the precision.</string>
<property name="spacing">
<number>0</number>
</property>
<property name="leftMargin">
<number>0</number>
</property>
<property name="topMargin">
<number>0</number>
</property>
<property name="rightMargin">
<number>0</number>
</property>
<property name="bottomMargin">
<property name="margin">
<number>0</number>
</property>
<item>
@@ -15972,16 +16019,7 @@ Lower the ratio -&gt; higher the precision.</string>
<property name="spacing">
<number>0</number>
</property>
<property name="leftMargin">
<number>0</number>
</property>
<property name="topMargin">
<number>0</number>
</property>
<property name="rightMargin">
<number>0</number>
</property>
<property name="bottomMargin">
<property name="margin">
<number>0</number>
</property>
<item>
@@ -16093,16 +16131,7 @@ Lower the ratio -&gt; higher the precision.</string>
<property name="spacing">
<number>0</number>
</property>
<property name="leftMargin">
<number>0</number>
</property>
<property name="topMargin">
<number>0</number>
</property>
<property name="rightMargin">
<number>0</number>
</property>
<property name="bottomMargin">
<property name="margin">
<number>0</number>
</property>
<item>