derivate_vector_fieldderivate_vector_fieldDerivateVectorFieldDerivateVectorFieldderivate_vector_field (Operator)

Name

derivate_vector_fieldderivate_vector_fieldDerivateVectorFieldDerivateVectorFieldderivate_vector_field — Convolve a vector field with derivatives of the Gaussian.

Signature

derivate_vector_field(VectorField : Result : Sigma, Component : )

Herror derivate_vector_field(const Hobject VectorField, Hobject* Result, double Sigma, const char* Component)

Herror T_derivate_vector_field(const Hobject VectorField, Hobject* Result, const Htuple Sigma, const Htuple Component)

void DerivateVectorField(const HObject& VectorField, HObject* Result, const HTuple& Sigma, const HTuple& Component)

HImage HImage::DerivateVectorField(const HTuple& Sigma, const HString& Component) const

HImage HImage::DerivateVectorField(double Sigma, const HString& Component) const

HImage HImage::DerivateVectorField(double Sigma, const char* Component) const

HImage HImage::DerivateVectorField(double Sigma, const wchar_t* Component) const   ( Windows only)

static void HOperatorSet.DerivateVectorField(HObject vectorField, out HObject result, HTuple sigma, HTuple component)

HImage HImage.DerivateVectorField(HTuple sigma, string component)

HImage HImage.DerivateVectorField(double sigma, string component)

def derivate_vector_field(vector_field: HObject, sigma: MaybeSequence[float], component: str) -> HObject

Description

derivate_vector_fieldderivate_vector_fieldDerivateVectorFieldDerivateVectorFieldDerivateVectorFieldderivate_vector_field convolves the components of a vector field with the derivatives of a Gaussian and calculates various features derived therefrom. derivate_vector_fieldderivate_vector_fieldDerivateVectorFieldDerivateVectorFieldDerivateVectorFieldderivate_vector_field only accepts vector fields of the semantic type vector_field_relative. The VectorFieldVectorFieldVectorFieldVectorFieldvectorFieldvector_field is defined as in optical_flow_mgoptical_flow_mgOpticalFlowMgOpticalFlowMgOpticalFlowMgoptical_flow_mg. SigmaSigmaSigmaSigmasigmasigma is the parameter of the Gaussian (i.e., the amount of smoothing). If a single value is passed in SigmaSigmaSigmaSigmasigmasigma, the amount of smoothing in the column and row direction is identical. If two values are passed in SigmaSigmaSigmaSigmasigmasigma, the first value specifies the amount of smoothing in the column direction, while the second value specifies the amount of smoothing in the row direction. The possible values for ComponentComponentComponentComponentcomponentcomponent are:

'curl'"curl""curl""curl""curl""curl":

The curl of the vector field. One application of using 'curl'"curl""curl""curl""curl""curl" is to analyse optical flow fields. Metaphorically speaking, the curl is how much a small boat would rotate if the vector field was a fluid.

'divergence'"divergence""divergence""divergence""divergence""divergence":

The divergence of the vector field. One application of using 'divergence'"divergence""divergence""divergence""divergence""divergence" is to analyze optical flow fields. Metaphorically speaking, the divergence is where the source and sink would be if the vector field was a fluid.

When used in context of photometric stereo, the operator derivate_vector_fieldderivate_vector_fieldDerivateVectorFieldDerivateVectorFieldDerivateVectorFieldderivate_vector_field offers two more parameters, which are especially designed to process the gradient field that is returned by photometric_stereophotometric_stereoPhotometricStereoPhotometricStereoPhotometricStereophotometric_stereo. In this case, we interpret the input vector field as gradient of the underlying surface.

In the following formulas, the input vector field is therefore noted as where the first and second component of the input is the gradient field of the surface . In the formulas below f_rc denotes the first derivative in column direction of the first component of the gradient field.

'mean_curvature'"mean_curvature""mean_curvature""mean_curvature""mean_curvature""mean_curvature":

Mean curvature of the underlying surface when the input vector field VectorFieldVectorFieldVectorFieldVectorFieldvectorFieldvector_field is interpreted as gradient field. One application of using 'mean_curvature'"mean_curvature""mean_curvature""mean_curvature""mean_curvature""mean_curvature" is to process the vector field that is returned by photometric_stereophotometric_stereoPhotometricStereoPhotometricStereoPhotometricStereophotometric_stereo. After filtering the vector field, even tiny scratches or bumps can be segmented.

'gauss_curvature'"gauss_curvature""gauss_curvature""gauss_curvature""gauss_curvature""gauss_curvature":

Gaussian curvature of the underlying surface when the input vector field VectorFieldVectorFieldVectorFieldVectorFieldvectorFieldvector_field is interpreted as gradient field. One application of using 'gauss_curvature'"gauss_curvature""gauss_curvature""gauss_curvature""gauss_curvature""gauss_curvature" is to process the vector field that is returned by photometric_stereophotometric_stereoPhotometricStereoPhotometricStereoPhotometricStereophotometric_stereo. After filtering the vector field, even tiny scratches or bumps can be segmented. If the underlying surface of the vector field is developable, the Gaussian curvature is zero.

Execution Information

Parameters

VectorFieldVectorFieldVectorFieldVectorFieldvectorFieldvector_field (input_object)  singlechannelimage(-array) objectHImageHObjectHImageHobject (vector_field)

Input vector field.

ResultResultResultResultresultresult (output_object)  singlechannelimage(-array) objectHImageHObjectHImageHobject * (real)

Filtered result images.

SigmaSigmaSigmaSigmasigmasigma (input_control)  real(-array) HTupleMaybeSequence[float]HTupleHtuple (real) (double) (double) (double)

Sigma of the Gaussian.

Default: 1.0

Suggested values: 0.7, 1.0, 1.5, 2.0, 3.0, 4.0, 5.0

Value range: 0.01 ≤ Sigma Sigma Sigma Sigma sigma sigma ≤ 50.0

ComponentComponentComponentComponentcomponentcomponent (input_control)  string HTuplestrHTupleHtuple (string) (string) (HString) (char*)

Component to be calculated.

Default: 'mean_curvature' "mean_curvature" "mean_curvature" "mean_curvature" "mean_curvature" "mean_curvature"

List of values: 'curl'"curl""curl""curl""curl""curl", 'divergence'"divergence""divergence""divergence""divergence""divergence", 'gauss_curvature'"gauss_curvature""gauss_curvature""gauss_curvature""gauss_curvature""gauss_curvature", 'mean_curvature'"mean_curvature""mean_curvature""mean_curvature""mean_curvature""mean_curvature"

Result

If the parameters are valid, the operator derivate_vector_fieldderivate_vector_fieldDerivateVectorFieldDerivateVectorFieldDerivateVectorFieldderivate_vector_field returns the value 2 ( H_MSG_TRUE) . The behavior in case of empty input (no input images available) is set via the operator set_system('no_object_result',<Result>)set_system("no_object_result",<Result>)SetSystem("no_object_result",<Result>)SetSystem("no_object_result",<Result>)SetSystem("no_object_result",<Result>)set_system("no_object_result",<Result>). If necessary, an exception is raised.

Possible Predecessors

optical_flow_mgoptical_flow_mgOpticalFlowMgOpticalFlowMgOpticalFlowMgoptical_flow_mg, photometric_stereophotometric_stereoPhotometricStereoPhotometricStereoPhotometricStereophotometric_stereo

Possible Successors

thresholdthresholdThresholdThresholdThresholdthreshold

Module

Foundation