cvtkit.metrics
Module including routines computing metrics.
This module includes the following functions:
MAE(estimate, target, reduction_dims, mask=None, relative=False)
Mean Absolute Error.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
estimate
|
. |
required | |
target
|
. |
required | |
reduction_dims
|
. |
required | |
mask
|
. |
None
|
|
relative
|
. |
False
|
Returns: .
RMSE(estimate, target, mask=None, relative=False)
Root Mean Squared Error.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
estimate
|
. |
required | |
target
|
. |
required | |
mask
|
. |
None
|
|
relative
|
. |
False
|
Returns: .
abs_error(est_depth, gt_depth)
Computes the absolute error between an estimated and groun-truth depth map.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
est_depth
|
ndarray
|
Estimated depth map. |
required |
gt_depth
|
ndarray
|
Ground-truth depth map. |
required |
Returns:
Type | Description |
---|---|
ndarray
|
The absolute error map for the estimated depth map. |
accuracy_eval(est_ply, gt_ply, mask_th, est_filt=None, gt_filt=None)
Computes the accuracy of an estimated point cloud against the provided ground-truth.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
est_ply
|
ndarray
|
Estimated point cloud to be evaluated. |
required |
gt_ply
|
ndarray
|
Ground-truth point cloud. |
required |
mask_th
|
float
|
Masking threshold used to remove points from the evaluation farther than a specified distance value. |
required |
est_filt
|
Optional[ndarray]
|
Optional filter to remove unwanted point from the estimated point cloud in the evaluation |
None
|
gt_filt
|
Optional[ndarray]
|
Optional filter to remove unwanted point from the ground-truth point cloud in the evaluation |
None
|
Returns:
Name | Type | Description |
---|---|---|
valid_est_ply |
PointCloud
|
Point cloud containing all the valid evaluation points after filtering. |
dists_est |
ndarray
|
Estimated distances of all valid points in the estimated point cloud to the closest point in the ground-truth point cloud. |
colors_est |
ndarray
|
Estimated colors for the points in the valid point cloud. |
completeness_eval(est_ply, gt_ply, mask_th=20.0, est_filt=None, gt_filt=None)
Computes the completeness of an estimated point cloud against the provided ground-truth.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
est_ply
|
PointCloud
|
Estimated point cloud to be evaluated. |
required |
gt_ply
|
PointCloud
|
Ground-truth point cloud. |
required |
mask_th
|
float
|
Masking threshold used to remove points from the evaluation farther than a specified distance value. |
20.0
|
est_filt
|
Optional[ndarray]
|
Optional filter to remove unwanted point from the estimated point cloud in the evaluation |
None
|
gt_filt
|
Optional[ndarray]
|
Optional filter to remove unwanted point from the ground-truth point cloud in the evaluation |
None
|
Returns:
Name | Type | Description |
---|---|---|
ply_points |
ndarray
|
Point cloud vertices containing all the valid evaluation points after filtering. |
dists |
ndarray
|
Distances of all valid points in the ground-truth point cloud to the closest point in the estimated point cloud. |
colors |
ndarray
|
Colors for the points in the valid point cloud. |
filter_outlier_points(est_ply, gt_ply, outlier_th)
Filters out points from an estimated point cloud that are farther than some threshold to the ground-truth point cloud.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
est_ply
|
PointCloud
|
Estimated point cloud to filter. |
required |
gt_ply
|
PointCloud
|
Ground-truth point cloud for reference. |
required |
outlier_th
|
float
|
Distance threshold used for filtering. |
required |
Returns:
Type | Description |
---|---|
PointCloud
|
The filtered point cloud. |