OpenDroneMap / ODM

A command line toolkit to generate maps, point clouds, 3D models and DEMs from drone, balloon or kite images. 📷
https://opendronemap.org
GNU Affero General Public License v3.0
4.89k stars 1.11k forks source link

Is possible implement the program on GPU with CUDA? #489

Closed Davidlapalma closed 4 years ago

Davidlapalma commented 7 years ago

I have really insterested in take the code and implemente on a GPU NVIDIA to run the program faster. It is possible, can you any idea about that?

smathermather commented 7 years ago

This is in the wish list -- just waiting on time and funding to implement. Cheers!

Davidlapalma commented 7 years ago

I have the intention to do a final project on my university, maybe its no much work I can try it

Davidlapalma commented 7 years ago

I will try it in a Nvidia Jetson

smathermather commented 7 years ago

👍

gateway commented 7 years ago

An issue is opened up here https://github.com/OpenDroneMap/OpenDroneMap/issues/92 and since Open Drone Map uses OpenSfM they have a old pull request that could use some help https://github.com/mapillary/OpenSfM/pull/49 OpenCV has supported gpu's for some time now.

dakotabenjamin commented 7 years ago

Thanks for digging in @gateway I know that contributor is currently working on their PhD so there's a good reason that pull request remains incomplete. Perhaps this is a good starting place for @Davidlapalma

Davidlapalma commented 7 years ago

thank you @gateway, I will start trying that

PeterSprague commented 6 years ago

Any progress on this?

I now have a working nvidia-docker ODM-cuda-8.0-opencv-3.3.1 image to use as a base [https://github.com/OpenDroneMap/OpenDroneMap/issues/694]. What are the next steps to push this forward?

OpenSfM is not utilizing the GPU yet though OpenDroneMap/OpenCV is built against Cuda: $ nvidia-smi Tue Nov 7 09:50:17 2017 +-----------------------------------------------------------------------------+ | NVIDIA-SMI 384.90 Driver Version: 384.90 | |-------------------------------+----------------------+----------------------+ | GPU Name Persistence-M| Bus-Id Disp.A | Volatile Uncorr. ECC | | Fan Temp Perf Pwr:Usage/Cap| Memory-Usage | GPU-Util Compute M. | |===============================+======================+======================| | 0 GeForce GTX 1080 Off | 00000000:05:00.0 On | N/A | | 27% 34C P8 8W / 180W | 451MiB / 8112MiB | 4% Default | +-------------------------------+----------------------+----------------------+

+-----------------------------------------------------------------------------+ | Processes: GPU Memory | | GPU PID Type Process name Usage | |=============================================================================| | 0 1784 G /usr/libexec/Xorg 414MiB | | 0 2415 G /usr/lib64/firefox/firefox 3MiB | | 0 20753 G /proc/self/exe 29MiB | +-----------------------------------------------------------------------------+

I thought OpenSfM would pick up the GPU if OpenCV was built against Cuda?

mapillary/OpenSfM#49 mentions "First working version for ORB gpu. Some numbers: HAHOG takes 1sec aprox. in Lund images, ORB-GPU 0.008s aprox." Is it even feasible to move to ORB-GPU within the ODM stack? Is this the best approach from ODM perspective?

dakotabenjamin commented 6 years ago

The path to getting it in odm:

  1. fix conflicts in the OpenSfM
  2. Get it merged by mapillary
  3. Make a PR in ODM to pull in latest opensfm changes

If there was trouble getting it pulled into opensfm, then there are ways to patch it into odm otherwise.

I think edgarriba has moved on from this project, probably got busy with their PhD (understandably).

PeterSprague commented 6 years ago

Is this the best approach, aka ORB-GPU, to use from the ODM perspective? Or is a fresh approach the better choice? Most recent work is from 2015.

beedawg1985 commented 5 years ago

Is CUDA supported now or likely to be supported in the near future?

smathermather commented 5 years ago

CUDA support was dependent upon the expiration of the SIFT patent (at least for it to be an easily doable/fundable item). It is now possible, but requires either someone to take it on as a project or find funding.

seangrant82 commented 4 years ago

Just wanted to bump this to see if there is anyone out there that can take this on (I would if I could) or has tried to since last post. I think this would be a HUGE win to get GPU support.

smathermather commented 4 years ago

Nothing yet, but getting SIFT into the tool chain will help, and the patent expires soon: see https://github.com/OpenDroneMap/ODM/pull/1069

smathermather commented 4 years ago

Duplicate. Closing.