Module estimate.py¶
-
estimate.
estimate
(configparams)[source]¶ Estimate and store depthmaps from a picture sequence.
The picture sequence directory, and a configuration parameters is obtained by reading the configuration file configfile. The estimated depth-maps are subsequently stored in an output directory specified in the aforementioned file. To read a more in-depth explanation of the parameters in configfile see Configuration File.
Parameters: - configparams : dict
Configuration parameters. This dictionary contains information about necessary files directories, as well as the values for various parameters used by the system.
See also
Notes
If the configuration parameter
depthmaps_directory
is not null then bundle optimization is performed during estimation.
-
estimate.
compute_frame
(frame, sequence, configparams)[source]¶ Estimate the (per-pixel) depth labels for a single frame in the sequence.
This function executes the depth-map estimation for the frame frame, given the input sequence sequence. If
sequence.use_bundle()==True
then bundle optimization is performed using the depth-maps in sequence.Parameters: - frame : int
Frame whose depth-map is estimated.
- sequence : utils.Sequence
Object containing parameters necessary to the depth-maps estimation. It contains the camera matrices, picture arrays, length of the sequence, etc. If the sequence instance contains also previously estimated depth-maps, then the bundle optimization phase is also executed.
- configparams : dict
Configuration parameters. It contains information about necessary files directories, as well as the values for various parameters used by the system.
Returns: - numpy array, type uint16
An array representing the per-pixel depth labels. The shape of such array is [h, w] (with h and w heigth and width of the input frame).