Error code 35072
I've been trying to run the latest commits with a previous image set that I've run through ODM. I'm hoping to test the latest orthophoto work, but am getting an error early on in the process. You can see the "quitting cause" below. I've dug around as much as I can and can't seem to find the issue. I'm willing to do the work if you can point me in the right direction. Like I said, this wasn't a problem before when I used this imagery to generate a point cloud and mesh.
A dump of the output is below...
- finding keypoints - Sat Dec 27 00:00:04 UTC 2014
When using programs that use GNU Parallel to process data for publication please cite:
O. Tange (2011): GNU Parallel - The Command-Line Power Tool, ;login: The USENIX Magazine, February 2011:42-47.
This helps funding further development; and it won't cost you a cent. Or you can get GNU Parallel without this requirement by paying 10000 EUR.
To silence this citation notice run 'parallel --bibtex' once or use '--no-notice'.
2/87 - Killed parallel: Starting no more jobs. Waiting for 8 jobs to finish. This job failed: echo -n " 2/87 - " && convert -format pgm "/home/ubuntu/caliterra_101914/reconstruction-with-image-size-3000/IMG_9347.jpg" "/home/ubuntu/caliterra_101914/reconstruction-with-image-size-3000/IMG_9347.pgm" && "/home/ubuntu/caliterra_101914/../OpenDroneMap/bin/vlsift" "/home/ubuntu/caliterra_101914/reconstruction-with-image-size-3000/IMG_9347.pgm" -o "/home/ubuntu/caliterra_101914/reconstruction-with-image-size-3000/IMG_9347.key.sift" > /dev/null && perl "/home/ubuntu/caliterra_101914/../OpenDroneMap/bin/../convert_vlsift_to_lowesift.pl" "/home/ubuntu/caliterra_101914/reconstruction-with-image-size-3000/IMG_9347" && gzip -f "/home/ubuntu/caliterra_101914/reconstruction-with-image-size-3000/IMG_9347.key" && rm -f "/home/ubuntu/caliterra_101914/reconstruction-with-image-size-3000/IMG_9347.pgm" && rm -f "/home/ubuntu/caliterra_101914/reconstruction-with-image-size-3000/IMG_9347.key.sift" 8/87 - 89718 4/87 - 84429 7/87 - 85585 6/87 - 91910 5/87 - 101615 3/87 - 98304 1/87 - 120826
quitting cause: "/home/ubuntu/caliterra_101914/../OpenDroneMap/bin/parallel" --halt-on-error 1 -j+0 < "/home/ubuntu/caliterra_101914/reconstruction-with-image-size-3000/_vlsift.templist.txt" returned with code 35072
Just found this in /var/log/syslog:
Dec 27 00:00:32 ip-10-237-147-124 kernel: [32072.482010] Out of memory: Kill process 1143 (vlsift) score 123 or sacrifice child
Dec 27 00:00:32 ip-10-237-147-124 kernel: [32072.491524] Killed process 1143 (vlsift) total-vm:2365784kB, anon-rss:1900840kB, file-rss:620kB
I've made a little progress on this even though I still don't understand what causes the VM to run out of memory. I know it's related to parallel running the vlsift process. What I've done is changed the "-j+0" param to "-j3" which is one less core than what's available on the VM. So my command now looks like this:
"/home/ubuntu/caliterra_101914_hexa/../OpenDroneMap/bin/parallel" --halt-on-error 1 -j3 < "/home/ubuntu/caliterra_101914_hexa/reconstruction-with-image-size-3000/_vlsift.templist.txt"
That gets me through the process for now, but I'd still like to understand the root cause. I'm going to continue to investigate, but if anyone has a theory I'd love to hear it.
Hi @dbaldwin, I'll try to look into this later this week. Sorry -- been out of touch for the holidays.
No sweat. I just wanted to keep this open and add to it as I discover more. Let me know if you dig anything up.
What are your VM specs?
I've been switching between the c3.2xlarge and c3.4xlarge instance types on EC2:
http://aws.amazon.com/ec2/instance-types/
OS is Ubuntu 14.04 LTS 64 bit. I don't have an instance running right now but I'd be happy to fire one up and give you access if that will help.
The week got away from me. I'll try testing early next week.
I'm getting the same error. I'm guessing it's out of memory (my vps - Ubuntu 12.04 1G physical, 1G swap). Dennis, is that amazon service working for you yet?
@goclimbing it's hit or miss for me. I just ran a test this AM on some photos with no problems, but I was on a c3.4xlarge instance, which comes with 16 virtual CPUs and 30 GB RAM. I wanted the job to be done quickly :) What I recommend is trying my suggestion above regarding reducing the number of cores you run parallel on. Just do it with YOUR_NUMBER_OF_CORES - 1 and see what happens. It may be a shot in the dark, but that's what I've been doing when I see this error. Still trying to understand the root cause though. Also, if you can upsize your VPS it will go a long ways in helping you process your imagery. I never do anything less than 8 GBM of RAM.
Hi @dbaldwin How did you change the the "-j+0" param to "-j3", where should I use this? I tried the YOUR_NUMBER_OF_CORES - 1 after ./run.pl and it works on a small set of images i.e. the benchmark but not a larger set like langley. This was tested on a c4.2xlarge and a c4.4xlarge AM
@soler2000 You can change it here in your run script:
https://github.com/OpenDroneMap/OpenDroneMap/blob/gh-pages/run.pl#L478
You'll have to manually edit it and then run it. Let us know what error you're getting. One thing you should check with those instances is the default volume is super small (8 GB). I believe you can run the benchmark series okay, but the langley will definitely run you out of disk space unless you attach an EBS volume. Why don't you confirm that and I'll try to run the langley set in the AM.
@dbaldwin yes the default instances are small at 8gb, i have been setting these at 30gb after it initially crashed out with an out of memory error. the Error code 35072 is with the 30GB volume
When it crashes with this error it always reports a similar error to this, where the number of job writing to finish is relative to the number or Cpu's
2/87 - Killed parallel: Starting no more jobs. Waiting for 8 jobs to finish. This job failed:
I will try changing the script later and run the langley dataset
I changed the the "-j+0" param to "-j3" and its running the Langley set just fine, well its got past the point were it was failing before.
Fixed with https://github.com/OpenDroneMap/OpenDroneMap/pull/37 .
@smathermather I think we should leave this open for the time being. If you look at @soler2000 and his run.pl mod, the number of cores is hardcoded:
https://github.com/OpenDroneMap/OpenDroneMap/commit/2f9013b7ea664c045c671698de62f9c921dc2684
I suggested he hardcode that argument to get around the issue of running out of memory. Obviously if someone is on a system with more than 4 cores then they'll be restricted.
Actually, if you look at the pull request he mentions to not pull his run.pl mod:
https://github.com/OpenDroneMap/OpenDroneMap/pull/37
Wanted to make sure you saw that.
I was trigger happy. You are right, of course @dbaldwin, although neither solution is ideal. If someone wants to add this as a parameter to sub parseArgs { that would be the proper way to do it, then we can just argue over what the sane default is.
Also, the matching portion of the system may go away, depending on the results from OpenSfM additions. These additions aren't integrated into the toolchain in any branch yet, but check out this issue:
https://github.com/OpenDroneMap/OpenDroneMap/issues/19
If all goes well, OpenSfM will replace the bundler and sift portions of the toolchain (at least optionally). If this is the case, we'll leave in CMVS and PMVS for the dense matching portion, but this problem will go with sift.
I encountered the same error code 35072. The latest OpenDroneMap from github was installed on a virtual machine Ubuntu 14.04, maximum RAM 4G, one CPU 2..8GHz, and was used to process 86 images (7360x4912 pixels) captured by a Nikon D800 mounted on an octocopter UAV.
These images were successfully processed with terminal input:
./run.sh --end-with pmvs In this processing, openDroneMap will resize the images to 2400x1602 by default. But it was desired to keep the original image size and to produce high resolution meshes, then I processed these images with terminal input: ./run.sh --resize-to 8000 --end-with pmvs The terminal gave error code 35072, then I tried ./run.sh --resize-to 7360 --end-with pmvs The same error occurred.
So I followed the suggestion by @dbaldwin, modified all of the two "-j+0" in run.sh to "-j1", then run:
./run.sh --resize-to 7360 --end-with pmvs The same error code returned. Then I modified all of the two "-j1" in run.sh to "-j0", then run: ./run.sh --resize-to 7360 --end-with pmvs The virtual machine crashed.
To see to what extent the image size has to do with this error code, changing all of the two "-j0" in run.sh back to "-j+0", I did another test:
./run.sh --resize-to 3680--end-with pmvs It succeeded.
Based on these tests, I believe it is likely that the limited RAM (4G in my case) caused this error rather than the specific number of CPUs. I would like to hear your feedback if you have different opinions about this.
Hey guys, I think the same bug occurs for me while I was trying to run OpenDroneMap on Ubuntu (VM)
VM: Oracle VirtualBox v 4.3.26 (6 cores, 12GB RAM) System: Linux 3.16.0-30-generic #40~14.04.1-Ubuntu SMP Thu Jan 15 17:43:14 UTC 2015 x86_64 x86_64 x86_64 GNU/Linux Photoset: odm_data_langley (30 photos subset)
Console output:
...
1/27 - Killed
parallel: Starting no more jobs. Waiting for 6 jobs to finish. This job failed:
echo -n "1/27 - " && convert -format pgm "/home/agrouser/set3/reconstruction-with-image-size-4700/IMG_0525.jpg" "/home/agrouser/set3/reconstruction-with-image-size-4700/IMG_0525.pgm" && "/home/agrouser/set3/../odm/bin/vlsift" "/home/agrouser/set3/reconstruction-with-image-size-4700/IMG_0525.pgm" -o "/home/agrouser/set3/reconstruction-with-image-size-4700/IMG_0525.key.sift" > /dev/null && perl "/home/agrouser/set3/../odm/bin/../convert_vlsift_to_lowesift.pl" "/home/agrouser/set3/reconstruction-with-image-size-4700/IMG_0525" && gzip -f "/home/agrouser/set3/reconstruction-with-image-size-4700/IMG_0525.key" && rm -f "/home/agrouser/set3/reconstruction-with-image-size-4700/IMG_0525.pgm" && rm -f "/home/agrouser/set3/reconstruction-with-image-size-4700/IMG_0525.key.sift"
3/27 - Killed
parallel: Starting no more jobs. Waiting for 5 jobs to finish. This job failed:
echo -n "3/27 - " && convert -format pgm "/home/agrouser/set3/reconstruction-with-image-size-4700/IMG_0527.jpg" "/home/agrouser/set3/reconstruction-with-image-size-4700/IMG_0527.pgm" && "/home/agrouser/set3/../odm/bin/vlsift" "/home/agrouser/set3/reconstruction-with-image-size-4700/IMG_0527.pgm" -o "/home/agrouser/set3/reconstruction-with-image-size-4700/IMG_0527.key.sift" > /dev/null && perl "/home/agrouser/set3/../odm/bin/../convert_vlsift_to_lowesift.pl" "/home/agrouser/set3/reconstruction-with-image-size-4700/IMG_0527" && gzip -f "/home/agrouser/set3/reconstruction-with-image-size-4700/IMG_0527.key" && rm -f "/home/agrouser/set3/reconstruction-with-image-size-4700/IMG_0527.pgm" && rm -f "/home/agrouser/set3/reconstruction-with-image-size-4700/IMG_0527.key.sift"
6/27 - Killed
parallel: Starting no more jobs. Waiting for 4 jobs to finish. This job failed:
echo -n "6/27 - " && convert -format pgm "/home/agrouser/set3/reconstruction-with-image-size-4700/IMG_0530.jpg" "/home/agrouser/set3/reconstruction-with-image-size-4700/IMG_0530.pgm" && "/home/agrouser/set3/../odm/bin/vlsift" "/home/agrouser/set3/reconstruction-with-image-size-4700/IMG_0530.pgm" -o "/home/agrouser/set3/reconstruction-with-image-size-4700/IMG_0530.key.sift" > /dev/null && perl "/home/agrouser/set3/../odm/bin/../convert_vlsift_to_lowesift.pl" "/home/agrouser/set3/reconstruction-with-image-size-4700/IMG_0530" && gzip -f "/home/agrouser/set3/reconstruction-with-image-size-4700/IMG_0530.key" && rm -f "/home/agrouser/set3/reconstruction-with-image-size-4700/IMG_0530.pgm" && rm -f "/home/agrouser/set3/reconstruction-with-image-size-4700/IMG_0530.key.sift"
2/27 - Killed
parallel: Starting no more jobs. Waiting for 3 jobs to finish. This job failed:
echo -n "2/27 - " && convert -format pgm "/home/agrouser/set3/reconstruction-with-image-size-4700/IMG_0526.jpg" "/home/agrouser/set3/reconstruction-with-image-size-4700/IMG_0526.pgm" && "/home/agrouser/set3/../odm/bin/vlsift" "/home/agrouser/set3/reconstruction-with-image-size-4700/IMG_0526.pgm" -o "/home/agrouser/set3/reconstruction-with-image-size-4700/IMG_0526.key.sift" > /dev/null && perl "/home/agrouser/set3/../odm/bin/../convert_vlsift_to_lowesift.pl" "/home/agrouser/set3/reconstruction-with-image-size-4700/IMG_0526" && gzip -f "/home/agrouser/set3/reconstruction-with-image-size-4700/IMG_0526.key" && rm -f "/home/agrouser/set3/reconstruction-with-image-size-4700/IMG_0526.pgm" && rm -f "/home/agrouser/set3/reconstruction-with-image-size-4700/IMG_0526.key.sift"
5/27 - 2850374/27 - 280435
quitting cause:
"/home/agrouser/set3/../odm/bin/parallel" --halt-on-error 1 -j+0 < "/home/agrouser/set3/reconstruction-with-image-size-4700/_vlsift.templist.txt"
returned with code 35072
Hope it will help you fix this issue.
I can confirm that changing the "-j+0" param to "-j1" in my case got me past this error. (I'm running Ubuntu 14.04 on parallels VM on my Mac with 2 CPU's and 1 gig of ram.)
There is a proposal to create a page (potentially a wiki) specifying stats on what works well with respect to processors and RAM for ODM. I think through this process, we'll establish what the ratio of RAM to # of processors should be. In the meantime, the tip from @chriseyhorn is a good work-around.