tile_shape

giant.scripts.tile_shape:

Tile a shape model into SurfaceFeatures in a FeatureCatalogue.

This script tiles an existing shape model in a GIANT format (shapes, kdtree, surface_feature, etc) into a FeatureCatalgoue of SurfaceFeatures. The features are sampled uniformly from the existing shape as square grids with a specified size and ground sample distance. Multiple GSDs can be requested in a single run. The resulting features can also optionally be exported to OBJs or SPC Maplets/Landmarks.

Typically this script will be used in 2 ways. First, if there is a global high resolution of model of the target being observed (such as from LiDAR data) then this script can be used to tile the high resolution model into features with varying ground sample distances for direct use in sfn or SPC. Second, this script may be used when building a shape model using only optical data. After constructing an initial low resolution shape model using limbs, this script can then be used to tile the low reduction model into initial features that will subsequently be refined through SPC or other shape modelling techniques.

Warning

For large number of features or when starting with a high-resolution shape model this script can take a long time to run. Therefore we encourage you to use nohup to allow it to complete unhindered.

Warning

This script load/saves some results from/to python pickle files. Pickle files can be used to execute arbitrary code, so you should never open one from an untrusted source.

Usage

Generate a feature catalog for Surface Feature Navigation (SFN) containing by tiling a global shape model

usage: tile_shape [-h] [-f FEATURE_OUTPUT] [-c CATALOGUE_OUTPUT] [-m] [-p] [-o OBJS] [-g GSDS [GSDS ...]] [-s SIZE] [-r SHAPE_RADIUS] [-v OVERLAP] shape

Positional Arguments

shape

path to the shape file directory

Named Arguments

-f, --feature_output

The directory to save the feature results to

Default: “./features”

-c, --catalogue_output

The directory to save the feature results to

Default: “./feature_catalogue.pickle”

-m, --memory_efficient

use memory efficient triangles

Default: False

-p, --spc

Make spc stuff

Default: False

-o, --objs

directory to output objs for each feature to this location (leave none to not make objs)

-g, --gsds

The gsds to build features at in meters

Default: [1.5, 1, 0.75, 0.35, 0.15]

-s, --size

The size of each side of a feature

Default: 201

-r, --shape_radius

The average radius of the shape in meters. Used to determine the number of tiles to make.

Default: 250

-v, --overlap

The minimum overlap between each tile as a faction in [0, 1). 0 indicates no minimum overlap (default) and 1 would indicate full overlap though that is not possible

Default: 0

WARNING: This script loads/saves some results from/to python pickle files. Pickle files can be used to execute arbitrary code, so you should never open one from an untrusted source.