rpg_svo_example icon indicating copy to clipboard operation
rpg_svo_example copied to clipboard

Self designed interface: Map destructed

Open laxnpander opened this issue 7 years ago • 0 comments

Hey guys,

I am currently trying to integrate SVO 2.0 in a mapping framework for testing. However I run into problems copying the mono example interface provided (I use my own interface, because it suits my needs better). The following code snippet is used for construction:

  _cam = vk::cameras::NCamera::loadFromYaml("/valid/path/to/calib.yaml");

  std::cout << "loaded " << _cam->numCameras() << " cameras";
  for(const auto& cam : _cam->getCameraVector())
    cam->printParameters(std::cout, "");

  // Init VO
  svo::FrameHandlerMono::Ptr _slam =
      std::make_shared<svo::FrameHandlerMono>(
          loadBaseOptions(),
          loadDepthFilterOptions(),
          loadDetectorOptions(),
          loadInitializationOptions(),
          loadReprojectorOptions(),
          loadTrackerOptions(),
          _cam);

  svo::Transformation T_world_imuinit(
      Eigen::Quaterniond(1.0, 0.0, 0.0, 0.0),
      Eigen::Vector3d(0.0, 0.0, 0.0));

  _slam->setInitialImuPose(T_world_imuinit);
  _slam->start();

The camera is read and printed correctly, however directly after creation as well the map as the depth filter are destructed. I copied all parameters and compared them with the ones in the example. The only difference I currently see, is that I don't establish a visualization, because it gets handled from my own framework.

Any suggestions what to try here, or in what cases such behaviour might occure?

Thanks and best regards,

Alex

laxnpander avatar May 12 '18 12:05 laxnpander