edgarriba / OpenDroneMap

OpenDroneMap is a tool to postprocess small Unmanned Aerial Vehicle (sUAS), balloon, kite, and street view data to geographic data. With the current update, we are adding the ability to create orthophotos from drone, balloon, and kite imagery which has GPS ephemeris. Forked from qwesda/BundlerTools ( https://github.com/qwesda/BundlerTools )
GNU General Public License v3.0
0 stars 0 forks source link

run.py failure at meshing #13

Closed dakotabenjamin closed 8 years ago

dakotabenjamin commented 8 years ago

Here's the output:

[INFO] Running OMD PMVS Cell - Finished
[INFO] Running OMD Meshing Cell
[DEBUG] Writting ODM Mesh file in: /vagrant_data/Toledo/edg/odm_meshing/odm_mesh.ply
[DEBUG] running /home/vagrant/odm/build/bin/odm_meshing -inputFile /vagrant_data/Toledo/edg/pmvs/recon0/models/option-00
00.ply -outputFile /vagrant_data/Toledo/edg/odm_meshing/odm_mesh.ply -logFile /vagrant_data/Toledo/edg/odm_meshing/odm_m
eshing_log.txt -maxVertexCount 100000 -octreeDepth 9 -samplesPerNode 1 -solverDivide 9
sh: 1: /home/vagrant/odm/build/bin/odm_meshing: not found

quitting cause:
        /home/vagrant/odm/build/bin/odm_meshing -inputFile /vagrant_data/Toledo/edg/pmvs/recon0/models/option-0000.ply -
outputFile /vagrant_data/Toledo/edg/odm_meshing/odm_mesh.ply -logFile /vagrant_data/Toledo/edg/odm_meshing/odm_meshing_l
og.txt -maxVertexCount 100000 -octreeDepth 9 -samplesPerNode 1 -solverDivide 9
returned with code 32512.

The built-in modules are not being installed right now, it seems. In opendm/context.py, it shows that the modules are being built in odm_modules_path = os.path.join(root_path, "build/bin") which doesn't exist.

So do meshing, texturing, extract_utm, georef, and orthophoto get built in the SuperBuild or after (in the ./configure.sh script)?

edgarriba commented 8 years ago

configure.sh only builds third party libs. Odm modules must be built apart

dakotabenjamin commented 8 years ago

ah I see. So workflow here is

  1. run configure.sh
  2. compile modules
  3. ?
  4. run.py --project-path /path/to/project
edgarriba commented 8 years ago

right! Without step 3 should work

dakotabenjamin commented 8 years ago

Ok. I got it working!

odm_orthophoto_sm

We will want to wrap the compilation into a single build script. I've got a simple bash script I'll submit a PR for, unless you have a better way.

edgarriba commented 8 years ago

Nice! Let me think about that. I'll do some research to find the proper way to do it, but the point to have the SuperBuild is to separate the cross compilation of third party libs and the own framework modules. The SuperBuild it's not finished yet because it may happen that users have some third party libs already installed, which in this case the configure.sh will only setup the paths. This was my initial idea.

dakotabenjamin commented 8 years ago

For now I've got this- doesn't work completely.

#!/bin/bash

echo "released under Creative Commons/CC-BY"
echo "Attribution"

ODM_PATH=`pwd`
MODULES_PATH="$ODM_PATH/modules"
BIN_PATH="$ODM_PATH/build/bin"
EXT_DIR="$ODM_PATH/SuperBuild/install"

## Get system vars
ARCH=`uname -m`
CORES=`grep -c processor /proc/cpuinfo`

## Remove old stuff
sudo rm -Rf "$BIN_PATH"

## create build path
mkdir -p "$BIN_PATH"

## Build Meshing
echo " Build Meshing "
cd "$MODULES_PATH/odm_meshing"
cmake . -DPCL_DIR="/home/vagrant/odm/SuperBuild/install"
make -j$CORES
cp -f "odm_meshing" "$BIN_PATH"

## Build Texturing
echo " Build Texturing"
cd "$MODULES_PATH/odm_texturing"
cmake . -DPCL_DIR="$EXT_DIR" -DOPENCV_DIR="$EXT_DIR"
make -j$CORES
cp -f "odm_texturing" $BIN_DIR

## Build Extract UTM
echo " Build ExtractUTM"
cd "$MODULES_PATH/odm_extract_utm"
cmake .
make -j$CORES
cp -f "odm_extract_utm" "$BIN_PATH"

## Build Georef
echo " Build Georef"
cd "$MODULES_PATH/odm_georef"
cmake . -DPCL_DIR="$EXT_DIR" -DOPENCV_DIR="$EXT_DIR"
make -j$CORES
cp -f "odm_georef" "$BIN_PATH"

## Build Orthophoto
echo " Build Orthophoto"
cd "$MODULES_PATH/odm_orthophoto"
cmake . -DPCL_DIR="$EXT_DIR" -DOPENCV_DIR="$EXT_DIR"
make -j$CORES
cp -f "odm_orthophoto" "$BIN_PATH"

echo "DONE"
edgarriba commented 8 years ago

There's no need of this script, the cmake does this job already. In the root dir do this:

mkdir build && cd build && cmake .. && make
dakotabenjamin commented 8 years ago

I just noticed the CMakeLists.txt file... :disappointed: