OpenDroneMap / NodeODM

A lightweight REST API to access aerial image processing engines such as ODM or MicMac
https://github.com/OpenDroneMap/NodeODM/blob/master/docs/index.adoc
GNU Affero General Public License v3.0
211 stars 152 forks source link

want to set options and changed 3d-tiles to true #207

Closed xueshuai0922 closed 1 year ago

xueshuai0922 commented 1 year ago

What is the problem?

I have used the /task/new/init API to set options and changed 3d-tiles to true. However, when I retrieve the result using /task/{uuid}/info, it still shows 3d-tiles as false. 【options 】 as follow:

[
  {
    "name": "end-with",
    "type": "enum",
    "value": "odm_postprocess",
    "domain": [
      "dataset",
      "split",
      "merge",
      "opensfm",
      "openmvs",
      "odm_filterpoints",
      "odm_meshing",
      "mvs_texturing",
      "odm_georeferencing",
      "odm_dem",
      "odm_orthophoto",
      "odm_report",
      "odm_postprocess"
    ],
    "help": "End processing at this stage. Can be one of: %(choices)s. Default: %(default)s"
  },
  {
    "name": "rerun-from",
    "type": "enum",
    "value": "",
    "domain": [
      "",
      "dataset",
      "split",
      "merge",
      "opensfm",
      "openmvs",
      "odm_filterpoints",
      "odm_meshing",
      "mvs_texturing",
      "odm_georeferencing",
      "odm_dem",
      "odm_orthophoto",
      "odm_report",
      "odm_postprocess"
    ],
    "help": "Rerun processing from this stage. Can be one of: %(choices)s. Default: %(default)s"
  },
  {
    "name": "min-num-features",
    "type": "int",
    "value": "10000",
    "domain": "integer",
    "help": "Minimum number of features to extract per image. More features can be useful for finding more matches between images, potentially allowing the reconstruction of areas with little overlap or insufficient features. More features also slow down processing. Default: %(default)s"
  },
  {
    "name": "feature-type",
    "type": "enum",
    "value": "sift",
    "domain": [
      "akaze",
      "hahog",
      "orb",
      "sift"
    ],
    "help": "Choose the algorithm for extracting keypoints and computing descriptors. Can be one of: %(choices)s. Default: %(default)s"
  },
  {
    "name": "feature-quality",
    "type": "enum",
    "value": "high",
    "domain": [
      "ultra",
      "high",
      "medium",
      "low",
      "lowest"
    ],
    "help": "Set feature extraction quality. Higher quality generates better features, but requires more memory and takes longer. Can be one of: %(choices)s. Default: %(default)s"
  },
  {
    "name": "matcher-type",
    "type": "enum",
    "value": "flann",
    "domain": [
      "bow",
      "bruteforce",
      "flann"
    ],
    "help": "Matcher algorithm, Fast Library for Approximate Nearest Neighbors or Bag of Words. FLANN is slower, but more stable. BOW is faster, but can sometimes miss valid matches. BRUTEFORCE is very slow but robust.Can be one of: %(choices)s. Default: %(default)s"
  },
  {
    "name": "matcher-neighbors",
    "type": "int",
    "value": "0",
    "domain": "positive integer",
    "help": "Perform image matching with the nearest images based on GPS exif data. Set to 0 to match by triangulation. Default: %(default)s"
  },
  {
    "name": "matcher-order",
    "type": "int",
    "value": "0",
    "domain": "positive integer",
    "help": "Perform image matching with the nearest N images based on image filename order. Can speed up processing of sequential images, such as those extracted from video. It is applied only on non-georeferenced datasets. Set to 0 to disable. Default: %(default)s"
  },
  {
    "name": "use-fixed-camera-params",
    "type": "bool",
    "value": "false",
    "domain": "",
    "help": "Turn off camera parameter optimization during bundle adjustment. This can be sometimes useful for improving results that exhibit doming/bowling or when images are taken with a rolling shutter camera. Default: %(default)s"
  },
  {
    "name": "cameras",
    "type": "string",
    "value": "",
    "domain": "json",
    "help": "Use the camera parameters computed from another dataset instead of calculating them. Can be specified either as path to a cameras.json file or as a JSON string representing the contents of a cameras.json file. Default: %(default)s"
  },
  {
    "name": "camera-lens",
    "type": "enum",
    "value": "auto",
    "domain": [
      "auto",
      "perspective",
      "brown",
      "fisheye",
      "fisheye_opencv",
      "spherical",
      "equirectangular",
      "dual"
    ],
    "help": "Set a camera projection type. Manually setting a value can help improve geometric undistortion. By default the application tries to determine a lens type from the images metadata. Can be one of: %(choices)s. Default: %(default)s"
  },
  {
    "name": "radiometric-calibration",
    "type": "enum",
    "value": "none",
    "domain": [
      "none",
      "camera",
      "camera+sun"
    ],
    "help": "Set the radiometric calibration to perform on images. When processing multispectral and thermal images you should set this option to obtain reflectance/temperature values (otherwise you will get digital number values). [camera] applies black level, vignetting, row gradient gain/exposure compensation (if appropriate EXIF tags are found) and computes absolute temperature values. [camera+sun] is experimental, applies all the corrections of [camera], plus compensates for spectral radiance registered via a downwelling light sensor (DLS) taking in consideration the angle of the sun. Can be one of: %(choices)s. Default: %(default)s"
  },
  {
    "name": "max-concurrency",
    "type": "int",
    "value": "16",
    "domain": "positive integer",
    "help": "The maximum number of processes to use in various processes. Peak memory requirement is ~1GB per thread and 2 megapixel image resolution. Default: %(default)s"
  },
  {
    "name": "use-hybrid-bundle-adjustment",
    "type": "bool",
    "value": "false",
    "domain": "",
    "help": "Run local bundle adjustment for every image added to the reconstruction and a global adjustment every 100 images. Speeds up reconstruction for very large datasets. Default: %(default)s"
  },
  {
    "name": "sfm-algorithm",
    "type": "enum",
    "value": "incremental",
    "domain": [
      "incremental",
      "triangulation",
      "planar"
    ],
    "help": "Choose the structure from motion algorithm. For aerial datasets, if camera GPS positions and angles are available, triangulation can generate better results. For planar scenes captured at fixed altitude with nadir-only images, planar can be much faster. Can be one of: %(choices)s. Default: %(default)s"
  },
  {
    "name": "sfm-no-partial",
    "type": "bool",
    "value": "false",
    "domain": "",
    "help": "Do not attempt to merge partial reconstructions. This can happen when images do not have sufficient overlap or are isolated. Default: %(default)s"
  },
  {
    "name": "sky-removal",
    "type": "bool",
    "value": "false",
    "domain": "",
    "help": "Automatically compute image masks using AI to remove the sky. Experimental. Default: %(default)s"
  },
  {
    "name": "bg-removal",
    "type": "bool",
    "value": "false",
    "domain": "",
    "help": "Automatically compute image masks using AI to remove the background. Experimental. Default: %(default)s"
  },
  {
    "name": "use-3dmesh",
    "type": "bool",
    "value": "false",
    "domain": "",
    "help": "Use a full 3D mesh to compute the orthophoto instead of a 2.5D mesh. This option is a bit faster and provides similar results in planar areas. Default: %(default)s"
  },
  {
    "name": "skip-3dmodel",
    "type": "bool",
    "value": "false",
    "domain": "",
    "help": "Skip generation of a full 3D model. This can save time if you only need 2D results such as orthophotos and DEMs. Default: %(default)s"
  },
  {
    "name": "skip-report",
    "type": "bool",
    "value": "false",
    "domain": "",
    "help": "Skip generation of PDF report. This can save time if you don't need a report. Default: %(default)s"
  },
  {
    "name": "skip-orthophoto",
    "type": "bool",
    "value": "false",
    "domain": "",
    "help": "Skip generation of the orthophoto. This can save time if you only need 3D results or DEMs. Default: %(default)s"
  },
  {
    "name": "ignore-gsd",
    "type": "bool",
    "value": "false",
    "domain": "",
    "help": "Ignore Ground Sampling Distance (GSD).A memory and processor hungry change relative to the default behavior if set to true. Ordinarily, GSD estimates are used to cap the maximum resolution of image outputs and resizes images when necessary, resulting in faster processing and lower memory usage. Since GSD is an estimate, sometimes ignoring it can result in slightly better image output quality. Never set --ignore-gsd to true unless you are positive you need it, and even then: do not use it. Default: %(default)s"
  },
  {
    "name": "no-gpu",
    "type": "bool",
    "value": "false",
    "domain": "",
    "help": "Do not use GPU acceleration, even if it's available. Default: %(default)s"
  },
  {
    "name": "mesh-size",
    "type": "int",
    "value": "200000",
    "domain": "positive integer",
    "help": "The maximum vertex count of the output mesh. Default: %(default)s"
  },
  {
    "name": "mesh-octree-depth",
    "type": "int",
    "value": "11",
    "domain": "integer: 1 <= x <= 14",
    "help": "Octree depth used in the mesh reconstruction, increase to get more vertices, recommended values are 8-12. Default: %(default)s"
  },
  {
    "name": "fast-orthophoto",
    "type": "bool",
    "value": "false",
    "domain": "",
    "help": "Skips dense reconstruction and 3D model generation. It generates an orthophoto directly from the sparse reconstruction. If you just need an orthophoto and do not need a full 3D model, turn on this option. Default: %(default)s"
  },
  {
    "name": "crop",
    "type": "float",
    "value": "3",
    "domain": "positive float",
    "help": "Automatically crop image outputs by creating a smooth buffer around the dataset boundaries, shrunk by N meters. Use 0 to disable cropping. Default: %(default)s"
  },
  {
    "name": "boundary",
    "type": "string",
    "value": "",
    "domain": "json",
    "help": "GeoJSON polygon limiting the area of the reconstruction. Can be specified either as path to a GeoJSON file or as a JSON string representing the contents of a GeoJSON file. Default: %(default)s"
  },
  {
    "name": "auto-boundary",
    "type": "bool",
    "value": "false",
    "domain": "",
    "help": "Automatically set a boundary using camera shot locations to limit the area of the reconstruction. This can help remove far away background artifacts (sky, background landscapes, etc.). See also --boundary. Default: %(default)s"
  },
  {
    "name": "auto-boundary-distance",
    "type": "float",
    "value": "0",
    "domain": "positive float",
    "help": "Specify the distance between camera shot locations and the outer edge of the boundary when computing the boundary with --auto-boundary. Set to 0 to automatically choose a value. Default: %(default)s"
  },
  {
    "name": "pc-quality",
    "type": "enum",
    "value": "medium",
    "domain": [
      "ultra",
      "high",
      "medium",
      "low",
      "lowest"
    ],
    "help": "Set point cloud quality. Higher quality generates better, denser point clouds, but requires more memory and takes longer. Each step up in quality increases processing time roughly by a factor of 4x.Can be one of: %(choices)s. Default: %(default)s"
  },
  {
    "name": "pc-classify",
    "type": "bool",
    "value": "false",
    "domain": "",
    "help": "Classify the point cloud outputs. You can control the behavior of this option by tweaking the --dem-* parameters. Default: %(default)s"
  },
  {
    "name": "pc-csv",
    "type": "bool",
    "value": "false",
    "domain": "",
    "help": "Export the georeferenced point cloud in CSV format. Default: %(default)s"
  },
  {
    "name": "pc-las",
    "type": "bool",
    "value": "false",
    "domain": "",
    "help": "Export the georeferenced point cloud in LAS format. Default: %(default)s"
  },
  {
    "name": "pc-ept",
    "type": "bool",
    "value": "false",
    "domain": "",
    "help": "Export the georeferenced point cloud in Entwine Point Tile (EPT) format. Default: %(default)s"
  },
  {
    "name": "pc-copc",
    "type": "bool",
    "value": "false",
    "domain": "",
    "help": "Save the georeferenced point cloud in Cloud Optimized Point Cloud (COPC) format. Default: %(default)s"
  },
  {
    "name": "pc-filter",
    "type": "float",
    "value": "2.5",
    "domain": "positive float",
    "help": "Filters the point cloud by removing points that deviate more than N standard deviations from the local mean. Set to 0 to disable filtering. Default: %(default)s"
  },
  {
    "name": "pc-sample",
    "type": "float",
    "value": "0",
    "domain": "positive float",
    "help": "Filters the point cloud by keeping only a single point around a radius N (in meters). This can be useful to limit the output resolution of the point cloud and remove duplicate points. Set to 0 to disable sampling. Default: %(default)s"
  },
  {
    "name": "pc-skip-geometric",
    "type": "bool",
    "value": "false",
    "domain": "",
    "help": "Geometric estimates improve the accuracy of the point cloud by computing geometrically consistent depthmaps but may not be usable in larger datasets. This flag disables geometric estimates. Default: %(default)s"
  },
  {
    "name": "smrf-scalar",
    "type": "float",
    "value": "1.25",
    "domain": "positive float",
    "help": "Simple Morphological Filter elevation scalar parameter. Default: %(default)s"
  },
  {
    "name": "smrf-slope",
    "type": "float",
    "value": "0.15",
    "domain": "positive float",
    "help": "Simple Morphological Filter slope parameter (rise over run). Default: %(default)s"
  },
  {
    "name": "smrf-threshold",
    "type": "float",
    "value": "0.5",
    "domain": "positive float",
    "help": "Simple Morphological Filter elevation threshold parameter (meters). Default: %(default)s"
  },
  {
    "name": "smrf-window",
    "type": "float",
    "value": "18",
    "domain": "positive float",
    "help": "Simple Morphological Filter window radius parameter (meters). Default: %(default)s"
  },
  {
    "name": "texturing-skip-global-seam-leveling",
    "type": "bool",
    "value": "false",
    "domain": "",
    "help": "Skip normalization of colors across all images. Useful when processing radiometric data. Default: %(default)s"
  },
  {
    "name": "texturing-skip-local-seam-leveling",
    "type": "bool",
    "value": "false",
    "domain": "",
    "help": "Skip the blending of colors near seams. Default: %(default)s"
  },
  {
    "name": "texturing-keep-unseen-faces",
    "type": "bool",
    "value": "false",
    "domain": "",
    "help": "Keep faces in the mesh that are not seen in any camera. Default:  %(default)s"
  },
  {
    "name": "texturing-single-material",
    "type": "bool",
    "value": "false",
    "domain": "",
    "help": "Generate OBJs that have a single material and a single texture file instead of multiple ones. Default:  %(default)s"
  },
  {
    "name": "gltf",
    "type": "bool",
    "value": "false",
    "domain": "",
    "help": "Generate single file Binary glTF (GLB) textured models. Default:  %(default)s"
  },
  {
    "name": "use-exif",
    "type": "bool",
    "value": "false",
    "domain": "",
    "help": "Use this tag if you have a GCP File but want to use the EXIF information for georeferencing instead. Default: %(default)s"
  },
  {
    "name": "dtm",
    "type": "bool",
    "value": "false",
    "domain": "",
    "help": "Use this tag to build a DTM (Digital Terrain Model, ground only) using a simple morphological filter. Check the --dem* and --smrf* parameters for finer tuning. Default: %(default)s"
  },
  {
    "name": "dsm",
    "type": "bool",
    "value": "false",
    "domain": "",
    "help": "Use this tag to build a DSM (Digital Surface Model, ground + objects) using a progressive morphological filter. Check the --dem* parameters for finer tuning. Default: %(default)s"
  },
  {
    "name": "dem-gapfill-steps",
    "type": "int",
    "value": "3",
    "domain": "positive integer",
    "help": "Number of steps used to fill areas with gaps. Set to 0 to disable gap filling. Starting with a radius equal to the output resolution, N different DEMs are generated with progressively bigger radius using the inverse distance weighted (IDW) algorithm and merged together. Remaining gaps are then merged using nearest neighbor interpolation. Default: %(default)s"
  },
  {
    "name": "dem-resolution",
    "type": "float",
    "value": "5",
    "domain": "float",
    "help": "DSM/DTM resolution in cm / pixel. Note that this value is capped by a ground sampling distance (GSD) estimate. Default: %(default)s"
  },
  {
    "name": "dem-decimation",
    "type": "int",
    "value": "1",
    "domain": "positive integer",
    "help": "Decimate the points before generating the DEM. 1 is no decimation (full quality). 100 decimates ~99%% of the points. Useful for speeding up generation of DEM results in very large datasets. Default: %(default)s"
  },
  {
    "name": "dem-euclidean-map",
    "type": "bool",
    "value": "false",
    "domain": "",
    "help": "Computes an euclidean raster map for each DEM. The map reports the distance from each cell to the nearest NODATA value (before any hole filling takes place). This can be useful to isolate the areas that have been filled. Default: %(default)s"
  },
  {
    "name": "orthophoto-resolution",
    "type": "float",
    "value": "5",
    "domain": "float > 0.0",
    "help": "Orthophoto resolution in cm / pixel. Note that this value is capped by a ground sampling distance (GSD) estimate.Default: %(default)s"
  },
  {
    "name": "orthophoto-no-tiled",
    "type": "bool",
    "value": "false",
    "domain": "",
    "help": "Set this parameter if you want a striped GeoTIFF. Default: %(default)s"
  },
  {
    "name": "orthophoto-png",
    "type": "bool",
    "value": "false",
    "domain": "",
    "help": "Set this parameter if you want to generate a PNG rendering of the orthophoto. Default: %(default)s"
  },
  {
    "name": "orthophoto-kmz",
    "type": "bool",
    "value": "false",
    "domain": "",
    "help": "Set this parameter if you want to generate a Google Earth (KMZ) rendering of the orthophoto. Default: %(default)s"
  },
  {
    "name": "orthophoto-compression",
    "type": "enum",
    "value": "DEFLATE",
    "domain": [
      "JPEG",
      "LZW",
      "PACKBITS",
      "DEFLATE",
      "LZMA",
      "NONE"
    ],
    "help": "Set the compression to use for orthophotos. Can be one of: %(choices)s. Default: %(default)s"
  },
  {
    "name": "orthophoto-cutline",
    "type": "bool",
    "value": "false",
    "domain": "",
    "help": "Generates a polygon around the cropping area that cuts the orthophoto around the edges of features. This polygon can be useful for stitching seamless mosaics with multiple overlapping orthophotos. Default: %(default)s"
  },
  {
    "name": "tiles",
    "type": "bool",
    "value": "false",
    "domain": "",
    "help": "Generate static tiles for orthophotos and DEMs that are suitable for viewers like Leaflet or OpenLayers. Default: %(default)s"
  },
  {
    "name": "3d-tiles",
    "type": "bool",
    "value": "true",
    "domain": "",
    "help": "Generate OGC 3D Tiles outputs. Default: %(default)s"
  },
  {
    "name": "rolling-shutter",
    "type": "bool",
    "value": "false",
    "domain": "",
    "help": "Turn on rolling shutter correction. If the camera has a rolling shutter and the images were taken in motion, you can turn on this option to improve the accuracy of the results. See also --rolling-shutter-readout. Default: %(default)s"
  },
  {
    "name": "rolling-shutter-readout",
    "type": "float",
    "value": "0",
    "domain": "positive integer",
    "help": "Override the rolling shutter readout time for your camera sensor (in milliseconds), instead of using the rolling shutter readout database. Note that not all cameras are present in the database. Set to 0 to use the database value. Default: %(default)s"
  },
  {
    "name": "build-overviews",
    "type": "bool",
    "value": "false",
    "domain": "",
    "help": "Build orthophoto overviews for faster display in programs such as QGIS. Default: %(default)s"
  },
  {
    "name": "cog",
    "type": "bool",
    "value": "false",
    "domain": "",
    "help": "Create Cloud-Optimized GeoTIFFs instead of normal GeoTIFFs. Default: %(default)s"
  },
  {
    "name": "video-limit",
    "type": "int",
    "value": "500",
    "domain": "positive integer",
    "help": "Maximum number of frames to extract from video files for processing. Set to 0 for no limit. Default: %(default)s"
  },
  {
    "name": "video-resolution",
    "type": "int",
    "value": "4000",
    "domain": "positive integer",
    "help": "The maximum output resolution of extracted video frames in pixels. Default: %(default)s"
  },
  {
    "name": "split",
    "type": "int",
    "value": "999999",
    "domain": "positive integer",
    "help": "Average number of images per submodel. When splitting a large dataset into smaller submodels, images are grouped into clusters. This value regulates the number of images that each cluster should have on average. Default: %(default)s"
  },
  {
    "name": "split-overlap",
    "type": "float",
    "value": "150",
    "domain": "positive integer",
    "help": "Radius of the overlap between submodels. After grouping images into clusters, images that are closer than this radius to a cluster are added to the cluster. This is done to ensure that neighboring submodels overlap. Default: %(default)s"
  },
  {
    "name": "sm-no-align",
    "type": "bool",
    "value": "false",
    "domain": "",
    "help": "Skip alignment of submodels in split-merge. Useful if GPS is good enough on very large datasets. Default: %(default)s"
  },
  {
    "name": "sm-cluster",
    "type": "string",
    "value": "None",
    "domain": "string",
    "help": "URL to a ClusterODM instance for distributing a split-merge workflow on multiple nodes in parallel. Default: %(default)s"
  },
  {
    "name": "merge",
    "type": "enum",
    "value": "all",
    "domain": [
      "all",
      "pointcloud",
      "orthophoto",
      "dem"
    ],
    "help": "Choose what to merge in the merge step in a split dataset. By default all available outputs are merged. Options: %(choices)s. Default: %(default)s"
  },
  {
    "name": "force-gps",
    "type": "bool",
    "value": "false",
    "domain": "",
    "help": "Use images' GPS exif data for reconstruction, even if there are GCPs present.This flag is useful if you have high precision GPS measurements. If there are no GCPs, this flag does nothing. Default: %(default)s"
  },
  {
    "name": "gps-accuracy",
    "type": "float",
    "value": "10",
    "domain": "positive float",
    "help": "Set a value in meters for the GPS Dilution of Precision (DOP) information for all images. If your images are tagged with high precision GPS information (RTK), this value will be automatically set accordingly. You can use this option to manually set it in case the reconstruction fails. Lowering this option can sometimes help control bowling-effects over large areas. Default: %(default)s"
  },
  {
    "name": "optimize-disk-space",
    "type": "bool",
    "value": "false",
    "domain": "",
    "help": "Delete heavy intermediate files to optimize disk space usage. This affects the ability to restart the pipeline from an intermediate stage, but allows datasets to be processed on machines that don't have sufficient disk space available. Default: %(default)s"
  },
  {
    "name": "pc-rectify",
    "type": "bool",
    "value": "false",
    "domain": "",
    "help": "Perform ground rectification on the point cloud. This means that wrongly classified ground points will be re-classified and gaps will be filled. Useful for generating DTMs. Default: %(default)s"
  },
  {
    "name": "primary-band",
    "type": "string",
    "value": "auto",
    "domain": "string",
    "help": "When processing multispectral datasets, you can specify the name of the primary band that will be used for reconstruction. It's recommended to choose a band which has sharp details and is in focus. Default: %(default)s"
  },
  {
    "name": "skip-band-alignment",
    "type": "bool",
    "value": "false",
    "domain": "",
    "help": "When processing multispectral datasets, ODM will automatically align the images for each band. If the images have been postprocessed and are already aligned, use this option. Default: %(default)s"
  }
]

image

task/{uuid}/inforesponse:

{
    "uuid": "6d6416bb-2067-4779-9491-069a82c1b7b6",
    "dateCreated": 1699262360700,
    "processingTime": 6013,
    "status": {
        "code": 20
    },
    "options": [
        {
            "name": "pc-ept",
            "value": true
        },
        {
            "name": "cog",
            "value": true
        },
        {
            "name": "gltf",
            "value": true
        }
    ],
    "imagesCount": 7,
    "progress": 4.5,
    "output": [
        "[INFO]    Initializing ODM 3.2.1 - Mon Nov 06 09:19:22  2023",
        "[INFO]    ==============",
        "[INFO]    3d_tiles: False",
        "[INFO]    align: None",
......................................

What should be the expected behavior?

i want to be set 3d-tiles true, output 3d-tiles

How can we reproduce this? (What steps did you do to trigger the problem? Be detailed)

i used swagger.json

[odm.openapi.json](https://github.com/OpenDroneMap/NodeODM/files/13265398/odm.openapi.json)

xueshuai0922 commented 1 year ago

docker run -p 3100:3000 -v /dev/drone/data-no-gpu:/var/wwww/data -d opendronemap/nodeodm --3d-tiles cant set true too

pierotofy commented 1 year ago

Could we move this conversation over to the forum at https://community.opendronemap.org? :pray: The forum is the right place to ask questions (we try to keep the GitHub issue tracker for feature requests and bugs only). Thank you! :+1: