Open Jmuccigr opened 10 years ago
Hi John, VSFM can get the laptop running pretty hot, which can be quite a worry. Currently there is a bit of an issue with VSFM not respecting the number of threads in the preferences file located at vsfm/bin/nv.ini I think this is what I'd do. Install vlfeat sift from https://github.com/vlfeat/vlfeat/tree/master . Then change these lines in the nv.ini file.
param_use_vlfeat_or_lowe 1
param_use_siftmatchgpu 0 # do this to disable GPU matching, it's definitely going to slow things down, but keep your macbook alive!
param_cpu_siftmatch_num_thread 2 # I can't seem to get this to use less CPUs... which is essentially you're problem, it's using the GPU for matching and all cores of the CPU, so it's working the computer very hard!
All the best, don't cook that macbook! Please keep me posted. I will update the installer to offer that config and compile vlfeat sift. Cheers, Dan
Dan, That's not my problem. When I SSH in, I can run top and see that the cpu is fine, as is RAM. Instead all I get on the laptop is the cursor, which moves all over the place, but nothing else is responsive. Killing what I think are the obvious processes (like xquartz) doesn't get me out of the freeze, so I think something fairly bad happens when VSFM starts that matching process.
I'm also a little confused about the GPU. The read.me says "1. libpba_no_gpu.so is made, sorry, no gpu at this stage." So is it being used or not? When I use the Tools menu to stop using the GPU, I get that error I reported above about not finding the binary.
Going to wait for you on this.
Thanks.
Any more on this?
Again, the problem isn't the cpu's pegging, it's something else.
Bump
Try this... change from 0 to the number of threads you want to limit it too... edit the file in vsfm/bin/nv.ini
param_maximum_cpu_usage 0
Does it require gcc-4.8 or will gcc-4.9 work too?
I had the same issue as John - my computer locked up hard on matching - and I believe that the issue is indeed related GPU usage (I'm running with only 512MB graphics memory).
By setting 'param_use_siftmatchgpu 0' in the nv.ini (which I see is what Dan suggested, although I did not install VLFeat) I was able to get around this problem successfully.
Thanks to Dan for putting this installer together!
gordonro: i'm sure gcc 4-9 will be fine, it's just getting around Clang which is the issue, you may need to do a search and replace on every 4.8 to say 4.9, or as a hack you could just alias gcc-4.9 to gcc-4.8 in your path.
Pretty sure I tried changing param_use_siftmatchgpu, but I'll try it again.
Threads aren't the issue, I don't think. Again, my cpu isn't getting slammed; the computer is becoming mostly unresponsive due to something else.
OK, here's what happened:
Output is:
Compute Missing Pairwise Matching, begin... ***** WARNING *** More than 182MB of graphic memory may be allocated under the default settings. If the program halts here, adjust parameters to save memory and rerun the task: [Tools->Enable GPU->Set Maximum DIM] Note some octaves may be automatically skipped ERROR: unable to load libsiftgpu.so ERROR: unable to get function address SIFT: 0000, 3264x2448, ERROR1 ERROR: unable to locate sift binary.
###########-------timing------######### 1 Feature Detection finished, 0 sec used #############################
91 pairs to compute match NOTE: using 2 matching workers
###########-------timing------######### 91 Image Match finished, 1 sec used #############################
Compute Missing Pairwise Matching, finished Totally 1.000 seconds used
libsiftgpu.so is in VisualSFM_OS_X_Mavericks_Installer-master/SiftGPU/bin/, which ought to be the expected place, no?
Hi John,
Sorry about the situation here... however "param_maximum_cpu_usage 0"
is different to "param_use_siftmatchgpu 0". It should throttle over all cpu usage. The reason you are getting the ERROR 1 is because you have switched over to needing to use the Sift binary, so it can't find it... and although VLFeat Sift is great, it's just as processor intensive, so it's no great solution. Since you have an 8 core machine, I suspect if you just set "param_maximum_cpu_usage 0" to about 2 of the eight CPU threads, the activity on the GPU may not be quite as taxing. I did a fair bit of work on my Macbook Pro over the years and I'd literally have the laptop on its side so it wouldn't be heated from the table, then I'd have a desk fan pointing at the thing too, and matching a thousand images could take days even still.
I use the command line too, as it's a bit quicker + the gui doesn't need to load. All you would need to do is ...
VisualSFM sfm+pmvs . out.nvm
An update:
Compute Missing Pairwise Matching, finished Totally 0.000 seconds used"
Hmmm, now that I think about it, what units is the 3200 in?
param_use_siftmatchgpu to 0 caused the problem where it couldn't find the sift executable. Reading the docs a bit over at ccwu.me, I discovered that the program expects that to be at ./sift, which is wasn't. So here's what I did. In nv.ini:
param_use_siftgpu 0 param_use_siftmatchgpu 0 param_use_vlfeat_or_lowe 1
In order for that last to work, the vlfeat sift executable has to be in bin, so I downloaded vlfeat from the link at the vxlm website, soft-linked the sift executable into bin and ran vxlm again. Voila! Took 173 seconds to do 13 images. Then took 29 minutes for a dense reconstruction. (Which wasn't very good, but I haven't played with this at all, so that might be why.)
So, Dan, maybe it's worthwhile adding a download of vlfeat and a copy of sift to bin into the .sh just to save some people time? It shouldn't make the install much longer, and having the binary there means changing nv.ini is all someone would have to do.
Bump
Could you explain the vlfeat part in more detail? where did you download it? did you just drag the sift file into bin?
@tabbailey091,
Honestly, it's been so long that I couldn't tell you beyond what I wrote there.
Installation seems to have gone fine on my late MacBook Pro 8,1 with an Intel Core i7 @ 2.7 GHz running 10.9.4. 16GB RAM, about 15GB free on the hard drive.
I load some photos. Fine. Then I click to run the feature detection & full pairwise image matching and the Mac locks up hard. The mouse still moves and I can SSH into the MBP to find that Windows Manager is using about 100% of a cpu (4 cores). Tried in vain to kill enough processes to regain control, but in the end I had to hard reboot. Nothing obvious (to me!) in Console afterwards.
Went in and tried killing SiftGPU, since there's no GPU support, and then it throws an error: "Unable to locate sift binary".
So I'm stuck.