-
Notifications
You must be signed in to change notification settings - Fork 33
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
How to use repository #2
Comments
@tanujamohan Just follow the doc and use the provided python sample that run all the openMVG SfM tools If you want to run the code samples see here: http://openmvg.readthedocs.io/en/latest/openMVG_Samples/openMVG_Samples/ |
I was able to get the tutorial_python with the castle images to work. Now I am trying to use the SfM_GlobalPipeline.py with my own images that I took. This is the command that I am running: python SfM_GlobalPipeline.py [path to my images] [path to output] I am currently receiving a sfm_data.bin cannot be read and robust.bin cannot be read. How can I fix this? I've tried recompiling and running the command but that does not solve the issue. |
Can you send the log there? |
Here is my log: `user-osx:SfM user$ python SfM_GlobalPipeline.py /Users/user/Desktop/openMVG_Build/software/SfM/myCamera /Users/user/Desktop/openMVG_Build/software/SfM/tutorial_out2 useruser ('Using input dir : ', '/Users/user/Desktop/openMVG_Build/software/SfM/myCamera') (' output_dir : ', '/Users/user/Desktop/openMVG_Build/software/SfM/tutorial_out2')
/Users/user/Desktop/openMVG_Build/Darwin-x86_64-RELEASE/RELEASE/openMVG_main_SfMInit_ImageListing --imageDirectory /Users/user/Desktop/openMVG_Build/software/SfM/myCamera --sensorWidthDatabase /Users/user/Desktop/openMVG/src/software/SfM/../../openMVG/exif/sensor_width_database/sensor_width_camera_database.txt --outputDirectory /Users/user/Desktop/openMVG_Build/software/SfM/tutorial_out2/matches --focal -1 --intrinsics --camera_model 3 --group_camera_model 1
0% 10 20 30 40 50 60 70 80 90 100% |----|----|----|----|----|----|----|----|----|----| Warning & Error messages: .DS_Store: Unkown image file format. SfMInit_ImageListing report: listed #File(s): 21 usable #File(s) listed in sfm_data: 20
/Users/user/Desktop/openMVG_Build/Darwin-x86_64-RELEASE/RELEASE/openMVG_main_ComputeFeatures --input_file /Users/user/Desktop/openMVG_Build/software/SfM/tutorial_out2/matches/sfm_data.json --outdir /Users/user/Desktop/openMVG_Build/software/SfM/tutorial_out2/matches --describerMethod SIFT --upright 0 --describerPreset NORMAL --force 0
0% 10 20 30 40 50 60 70 80 90 100% |----|----|----|----|----|----|----|----|----|----| Task done in (s): 0.001
/Users/user/Desktop/openMVG_Build/Darwin-x86_64-RELEASE/RELEASE/openMVG_main_ComputeMatches --input_file /Users/user/Desktop/openMVG_Build/software/SfM/tutorial_out2/matches/sfm_data.json --out_dir /Users/user/Desktop/openMVG_Build/software/SfM/tutorial_out2/matches Optional parameters: --force 0 --ratio 0.8 --geometric_model e --video_mode_matching -1 --pair_list --nearest_matching_method AUTO --guided_matching 0
0% 10 20 30 40 50 60 70 80 90 100% |----|----|----|----|----|----|----|----|----|----|
PREVIOUS RESULTS LOADED; #pair: 21 sh: neato: command not found
0% 10 20 30 40 50 60 70 80 90 100% |----|----|----|----|----|----|----|----|----|----| Task done in (s): 0.002 Export Adjacency Matrix of the pairwise's geometric matches sh: neato: command not found
Global Structure from Motion: Open Source implementation of the paper: "Global Fusion of Relative Motions for Robust, Accurate and Scalable Structure from Motion." Pierre Moulon, Pascal Monasse and Renaud Marlet. ICCV 2013.
0% 10 20 30 40 50 60 70 80 90 100% |----|----|----|----|----|----|----|----|----|----| CleanGraph_KeepLargestBiEdge_Nodes():: => connected Component: 0 Cardinal of nodes: 0 Cardinal of edges: 0 Invalid input image graph for global SfM
The input SfM_Data file "/Users/user/Desktop/openMVG_Build/software/SfM/tutorial_out2/reconstruction_global/sfm_data.bin" cannot be read.
Compute Structure from the provided poses The input SfM_Data file "/Users/user/Desktop/openMVG_Build/software/SfM/tutorial_out2/reconstruction_global/sfm_data.bin" cannot be read. The input SfM_Data file "/Users/user/Desktop/openMVG_Build/software/SfM/tutorial_out2/reconstruction_global/robust.bin" cannot be read. user-osx:SfM user$ ` |
It seems that your image graph is empty once the pairwise filtering is done. Something like:
If you have nothing defined it's because the sensor size of your camera is not defined. |
It appears that I do not have anything in the intrinsics. I'm using an LG G3 to take my photos, so I went into the sensor_width_camera_database.txt and added "LG G3;4.69". Ran the python script again and still get the same error. Can you explain further how I should define the sensor size of my camera? |
Also, what I have tried modifying the Global Pipeline script so that the intrinsic analysis now has (first line is commented out): print ("1. Intrinsics analysis") Running the python code gives me this as output in the command line: ('Using input dir : ', '/Users/user/Desktop/openMVG_Build/software/SfM/myCamera') (' output_dir : ', '/Users/user/Desktop/openMVG_Build/software/SfM/tutorial_out2')
Traceback (most recent call last): File "SfM_GlobalPipeline.py", line 50, in
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/subprocess.py", line 659, in init
TypeError: bufsize must be an integer |
Command line You must move the option inside the [] So change pIntrisics = subprocess.Popen( [os.path.join(OPENMVG_SFM_BIN, "openMVG_main_SfMInit_ImageListing"), "-i", input_dir, "-o", matches_dir, "-d", camera_file_params, "-f", "1152"] ) Database |
Hi , @pmoulon |
Great,it works for me! |
I do have similar logs . can you share any suggestion that how do i convert html report to pdf ?? |
I have cloned the OpenMVG repository and used Xcode to successfully build it. Now I would like to run this example. How should I go about doing this and what commands do I need to use?
The text was updated successfully, but these errors were encountered: