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

Reconstrucring recorded data #3

Open
raghad1234 opened this issue Feb 5, 2019 · 12 comments
Open

Reconstrucring recorded data #3

raghad1234 opened this issue Feb 5, 2019 · 12 comments

Comments

@raghad1234
Copy link

Hi,
I am trying to use your package to reconstruct the scene of a new recorded(i am using DAVIS240C and running it using rpg_dvs_ros (davis_mono.launch file))

I tried the following:
1- I recorded a bag file and run the same command line $rosrun mapper_emvs run_emvs --bag_filename=/home/user/ros_ws_kinetic/data/test.bag --flagfile=cfg/slider_depth.conf
but it shows me this error
I0205 15:35:53.154494 22741 data_loading.cpp:61] initial stamp: 1549366232.709949495 F0205 15:35:53.212122 22741 trajectory.hpp:118] Check failed: poses_.size() >= 2u (0 vs. 2) At least two poses need to be provided *** Check failure stack trace: *** @ 0x7f4750dfa43d google::LogMessage::Fail() @ 0x7f4750dfc253 google::LogMessage::SendToLog() @ 0x7f4750df9fcb google::LogMessage::Flush() @ 0x7f4750dfcc3e google::LogMessageFatal::~LogMessageFatal() @ 0x418833 LinearTrajectory::LinearTrajectory() @ 0x4112cf main @ 0x7f474efc9830 __libc_start_main @ 0x412f09 _start
Looking at your bag file (slider_depth.bag), I can see the following topics recorded
/clock
/dvs/camera_info
/dvs/events
/dvs/image_raw
/optitrack/davis
/rosout
/rosout_agg

However, when I list the topic of my DAVIS, I didn't find the /optitrack/davis nor the /clock
Here is the list of my topics

/davis_ros_driver/parameter_descriptions
/davis_ros_driver/parameter_updates
/dvs/calibrate_imu
/dvs/camera_info
/dvs/events
/dvs/exposure
/dvs/image_raw
/dvs/imu
/dvs/reset_timestamps
/dvs/trigger_snapshot
/dvs_accumulated_events
/dvs_accumulated_events/compressed
/dvs_accumulated_events/compressed/parameter_descriptions
/dvs_accumulated_events/compressed/parameter_updates
/dvs_accumulated_events/compressedDepth
/dvs_accumulated_events/compressedDepth/parameter_descriptions
/dvs_accumulated_events/compressedDepth/parameter_updates
/dvs_accumulated_events/theora
/dvs_accumulated_events/theora/parameter_descriptions
/dvs_accumulated_events/theora/parameter_updates
/dvs_accumulated_events_edges
/dvs_accumulated_events_edges/compressed
/dvs_accumulated_events_edges/compressed/parameter_descriptions
/dvs_accumulated_events_edges/compressed/parameter_updates
/dvs_accumulated_events_edges/compressedDepth
/dvs_accumulated_events_edges/compressedDepth/parameter_descriptions
/dvs_accumulated_events_edges/compressedDepth/parameter_updates
/dvs_accumulated_events_edges/theora
/dvs_accumulated_events_edges/theora/parameter_descriptions
/dvs_accumulated_events_edges/theora/parameter_updates
/dvs_rendering
/dvs_rendering/compressed
/dvs_rendering/compressed/parameter_descriptions
/dvs_rendering/compressed/parameter_updates
/dvs_rendering/compressedDepth
/dvs_rendering/compressedDepth/parameter_descriptions
/dvs_rendering/compressedDepth/parameter_updates
/dvs_rendering/theora
/dvs_rendering/theora/parameter_descriptions
/dvs_rendering/theora/parameter_updates
/dvs_undistorted
/dvs_undistorted/compressed
/dvs_undistorted/compressed/parameter_descriptions
/dvs_undistorted/compressed/parameter_updates
/dvs_undistorted/compressedDepth
/dvs_undistorted/compressedDepth/parameter_descriptions
/dvs_undistorted/compressedDepth/parameter_updates
/dvs_undistorted/theora
/dvs_undistorted/theora/parameter_descriptions
/dvs_undistorted/theora/parameter_updates
/events_off_mean_1
/events_off_mean_5
/events_on_mean_1
/events_on_mean_5
/image_view/output
/image_view/parameter_descriptions
/image_view/parameter_updates
/rosout
/rosout_agg

The questions are:
1- how can I record the /optitrack/davis topic knowing that I don't have an optitrack system in the lab?
2- Does the /clock topic need to be there to reconstruct the area
3- Will DAVIS be able to reconstruct the scene if it doesn't move?
4- Is there a way to reconstruct a live stream data?

Thanks in advance
Best,
Raghad

@guillermogb
Copy link
Contributor

  1. You do not need optitrack. Any system that provides camera poses (motion capture system, motorized slider, or any pose tracking algorithm) and publishes them in a topic is enough. The name of the topic can be specified in the configuration file (such as slider_depth.conf).
  2. The clock topic is not needed, as you can read in the data loader.
  3. You need to provide the relative motion between the camera and the scene. If the camera does not move, you have to provide the poses of the camera with respect to the moving object. Please read the paper for the requirements of the method, that is, to understand the problem that it solves.
  4. EMVS can reconstruct a live stream data. It runs in real time; you just need to provide the input required by the algorithm: events, camera calibration and camera poses.

@raghad1234
Copy link
Author

Thanks for your reply, now I recorded new data with the required topics and updated the main.cpp file.
but whenever i run the run_emvs, I receive the following error

*** Aborted at 1549544962 (unix time) try "date -d @1549544962" if you are using GNU date ***
PC: @ 0x7f880a160614 data_loading::parse_rosbag()
*** SIGSEGV (@0x0) received by PID 424 (TID 0x7f880f94a7c0) from PID 0; stack trace: ***
@ 0x7f880a38d390 (unknown)
@ 0x7f880a160614 data_loading::parse_rosbag()
@ 0x41129b main
@ 0x7f88094f0830 __libc_start_main
@ 0x412f09 _start
Segmentation fault (core dumped)

Is it related to the .comf file? I've tried some suggestions online but none was working.

@guillermogb
Copy link
Contributor

Did you call the program with the correct path to the bag?
rosrun mapper_emvs run_emvs --bag_filename=myfile.bag (without leaving a space after the = sign

@raghad1234
Copy link
Author

yes, this is exactly the command I am using

rosrun mapper_emvs run_emvs --bag_filename=/home/user/ros_ws_kinetic/fileName.bag --flagfile=cfg/slider_depth.conf

@guillermogb
Copy link
Contributor

Were you able to run the examples provided?

@raghad1234
Copy link
Author

Yes, and I recorded new data with the same pkg used to record the provided example.
Some people suggested it is in google::InitGoogleLogging(argv[0]); which is in the main.cpp file, but even commenting it provides the same error

@guillermogb
Copy link
Contributor

Does the file exist?
ls -lh /home/user/ros_ws_kinetic/fileName.bag

@raghad1234
Copy link
Author

of course it exists, I am able to echo the data for all the needed topics and I compared them with the recorded ones (I can't attach the bag file here)

this is what I get when I run your command
-rw-rw-r-- 1 user user 698M Feb 7 16:55 /home/user/ros_ws_kinetic/fileName.bag

@guillermogb
Copy link
Contributor

It is strange that it worked for the examples and not for a new dataset.
I would check that you are using the right topic names. You can pass them via command line or using the configuration file; there is no need to modify main.cpp at all. Just add the following to the configuration file: --pose_topic=/optitrack/dvs

If it does not work, I suggest you debug the code that loads the data (as you can read in your error data_loading::parse_rosbag())
https://github.com/uzh-rpg/rpg_emvs/blob/master/mapper_emvs/src/data_loading.cpp#L11
Sorry, but we do not provide support for the code, as mentioned in the License.

@raghad1234
Copy link
Author

raghad1234 commented Feb 10, 2019

Hi again,
I manged to solve the error above and the package now works fine
However, I am getting a really weird reconstruction, Any clue of why I am getting this output?
The original image is below

dvs

And the reconstructed image is here
confidence_map

Note: DAVIS is moving in a good speed (i.e. I can see the pixels generated around the objects due to the motion when running the bag file)

Also, does the slider have to move in a straight motion in order to reconstruct the area?

@raghad1234
Copy link
Author

Hi Guillermo,

Just two small questions
1- Does the camera need to move in a linear motion in this package?
2- Do I have to do any transformation between the camera's frame and the position of the camera that is coming from the motion capture system?

Appreciate your reply.

@guillermogb
Copy link
Contributor

Hi Raghad,

  1. The camera can move in arbitrary motion. See the examples (dynamic scene, boxes, etc.) in the readme.md
  2. Yes, you need to apply the transformation between the hand (motion-capture) and the camera (the eye) if you have not done so. The examples from the Event Camera Dataset incorporate this transformation in the poses provided. See the last paragraph of the Hand-eye calibration section of our dataset paper: https://arxiv.org/pdf/1610.08336.pdf

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