Do not build MBTiles, timeout fixes

pull/95/head
Piero Toffanin 2019-10-01 22:59:00 -04:00
rodzic e206fc7dba
commit f539638cfa
4 zmienionych plików z 6 dodań i 19 usunięć

Wyświetl plik

@ -51,7 +51,7 @@ Options:
--s3_signature_version <version> S3 signature version. (default: 4)
--s3_upload_everything Upload all task results to S3. (default: upload only .zip archive and orthophoto)
--max_concurrency <number> Place a cap on the max-concurrency option to use for each task. (default: no limit)
--max_runtime <number> Number of minutes that a task is allowed to run before being forcibly canceled (timeout). (default: no limit)
--max_runtime <number> Number of minutes (approximate) that a task is allowed to run before being forcibly canceled (timeout). (default: no limit)
Log Levels:
error | debug | info | verbose | debug | silly
`);

Wyświetl plik

@ -338,7 +338,9 @@ module.exports = class Task{
};
// All paths are relative to the project directory (./data/<uuid>/)
let allPaths = ['odm_orthophoto/odm_orthophoto.tif', 'odm_orthophoto/odm_orthophoto.mbtiles',
let allPaths = ['odm_orthophoto/odm_orthophoto.tif',
'odm_orthophoto/odm_orthophoto.png',
'odm_orthophoto/odm_orthophoto.mbtiles',
'odm_georeferencing', 'odm_texturing',
'odm_dem/dsm.tif', 'odm_dem/dtm.tif', 'dsm_tiles', 'dtm_tiles',
'orthophoto_tiles', 'potree_pointcloud', 'entwine_pointcloud',

Wyświetl plik

@ -319,8 +319,8 @@ class TaskManager{
for (let uuid in this.tasks){
let task = this.tasks[uuid];
if (task.processingTime > config.maxRuntime * 60 * 1000){
task.output.push(`Task timed out after ${task.processingTime / 60 / 1000} seconds.\n`);
if (!task.isCanceled() && task.processingTime > config.maxRuntime * 60 * 1000){
task.output.push(`Task timed out after ${Math.ceil(task.processingTime / 60 / 1000)} minutes.\n`);
this.cancel(uuid, () => {
logger.warn(`Task ${uuid} timed out`);
});

Wyświetl plik

@ -55,21 +55,6 @@ for dem_product in ${dem_products[@]}; do
fi
done
# Generate MBTiles
if hash gdal_translate 2>/dev/null; then
orthophoto_path="odm_orthophoto/odm_orthophoto.tif"
orthophoto_mbtiles_path="odm_orthophoto/odm_orthophoto.mbtiles"
if [ -e "$orthophoto_path" ]; then
gdal_translate $orthophoto_path $orthophoto_mbtiles_path -of MBTILES
gdaladdo -r bilinear $orthophoto_mbtiles_path 2 4 8 16 32 64 128 256 512 1024 2048 4096 8192 16384
else
echo "No orthophoto found at $orthophoto_path: will skip MBTiles generation"
fi
else
echo "gdal_translate is not installed, will skip MBTiles generation"
fi
# Generate point cloud (if entwine or potreeconverter is available)
pointcloud_input_path=""
for path in "odm_georeferencing/odm_georeferenced_model.laz" \