DGM compile error

Post a reply


This question is a means of preventing automated form submissions by spambots.
Smilies
:D :) ;) :( :o :shock: :? 8-) :lol: :x :P :oops: :cry: :evil: :twisted: :roll: :!: :?: :idea: :arrow: :| :mrgreen: :geek: :ugeek:

BBCode is ON
[img] is ON
[flash] is OFF
[url] is ON
Smilies are ON

Topic review
   

Expand view Topic review: DGM compile error

Re: DGM compile error

Post by Bryan » Sat Jul 15, 2017, 12:26

Sorry I have solved the problem. Sorry to disturb you. I can run the demo train. Now I try to learn how to extract road using my samples. Thank you for your help. :D

Re: DGM compile error

Post by Bryan » Fri Jul 14, 2017, 20:58

I think I have the right setting, I can run D:\DGM\build\install\bin\Demo Train.dat. But I still wanna renew an independent folder and add "Demo Train" project then run it. But there are still some errors I am so confused about. I compared my project with "Demo Train" project, I found that "Demo Train" project have reference and mine has not but I could not add reference.
Could you please help me renew an independent project under folder E:\DGM_Feature\project with VS2015 and add Demo Train project then make it run. Thank you!

Re: DGM compile error

Post by Creator » Thu Jul 13, 2017, 22:12

In order to copy the setting, all you need to do is to perform the steps 4 and 5 of the Installing DGM guide.
Please make sure, that the dependencies on the OpenCV are also specified in the “Configuration Properties” of your new project. When you finish, the Configuration properties of your new project should be the same as the Configuration Properties of the “Demo Train” project in DGM. Here you can find a good manual how to work with the Configuration Properties: https://msdn.microsoft.com/en-us/library/669zx6zc.aspx

P.S.
I do not really understand why you want to do it manually. CMake does all of it automatically.

Re: DGM compile error

Post by Bryan » Sun Jul 09, 2017, 14:15

I added source from demo-train.cpp in demos folder. Maybe VS can find that. Sorry I didn't copy setting from demo train project. Could I ask you how to copy? Copy certain file or content of the project? I will try it again. Sorry!

Re: DGM compile error

Post by Creator » Sun Jul 02, 2017, 14:36

It looks like the errors with linking visual studio libraries. I think that copying the properties files does not work.

Re: DGM compile error

Post by Bryan » Sun Jul 02, 2017, 00:46

I found I missed something so I renew a project add DGM/demos/demo_train.cpp and the two properties (debug__.props and opencv32.props) and compiled. Many LNK errors. Then I removed demo_train.cpp and add extract.cpp and extract.h, the errors is the same with above. Maybe I met something serious. If you can, I think remote assistant is the best way. You can control my PC and figure it out. Thank you!
Attachments
LNKE.PNG
LNK.PNG
image.png

Re: DGM compile error

Post by Creator » Tue Jun 27, 2017, 21:07

I can’t say from the attached image the reason for these two errors... “print_help” seems very strange to me, have you copied the source code of the demo_train completely?
As a remedy, and in order to gain fast results, I would suggest you to edit the demo_train code directly in the library. Optionally, f you need to work in a separate project, please try to edit your new project setting manually, with respect to the demo_train settings. Just add new dependencies in the C/C++ and Linker directories of the project’s property pages.

Re: DGM compile error

Post by Bryan » Sun Jun 25, 2017, 21:43

Thank you for your patient reply. I have followed your first propose and change to VS2015 platform. I built 14 projects successfully. Then I didn't move content of install folder to build folder as the instruction (http://research.project-10.de/dgm/doc/a ... nstall_dgm) said. Next I new a project with VS2015 and added two property (opencv32.props,debug__.props), one for opencv3.2 setting(opencv setting is ok, I think) and another for DGM. At the same time I copied code of demo train to main.cpp and compiled them but error appeared just like attachment showed.
Attachments
error.PNG
error.PNG (5.22 KiB) Viewed 19301 times

Re: DGM compile error

Post by Creator » Wed Jun 21, 2017, 21:48

The errors in Random.h CameraControl.h and AveragePrecision.cpp are caused by the fact, that your Visual Studio does not fully support the C++11 standard. Here, I can suggest you 2 solutions:
  1. Download and Install Visual Studio 2015 (or 2017) Community (free): https://www.visualstudio.com/downloads/ (the best silution). In this case you will be obliged to re-build the OpenCV library. This procedure is very the same as for building the DGM
  2. Exclude the C++11 code from the library:
    • delete AveragePrecision.cpp and AveragePrecision.h and exclude it from the CMakeLists.txt file and from the “#include” directives
    • disable ENABLE_PPL in the types.h file
    • rewrite the function T rand(T min, T max) in random.h file

Re: DGM compile error

Post by Bryan » Tue Jun 20, 2017, 21:57

I have downloaded the DGM opencv_2.4.13 branch from github. And I downloaded opencv2.4.13.exe and extracted the folder including build and source folder. And I compiled with cmake-gui and open .sln with 2013 VS and compile, then get the following result.
Attachments
!cid_ii_159505b95a359eff.png

Top