info_edges T_info_edges InfoEdges InfoEdges info_edges (算子)
名称
info_edges T_info_edges InfoEdges InfoEdges info_edges — 返回 edges_image edges_image EdgesImage EdgesImage EdgesImage edges_image 中滤波器的滤波系数。
签名
void InfoEdges (const HTuple& Filter , const HTuple& Mode , const HTuple& Alpha , HTuple* Size , HTuple* Coeffs )
static Hlong HMisc ::InfoEdges (const HString& Filter , const HString& Mode , double Alpha , HTuple* Coeffs )
static Hlong HMisc ::InfoEdges (const char* Filter , const char* Mode , double Alpha , HTuple* Coeffs )
static Hlong HMisc ::InfoEdges (const wchar_t* Filter , const wchar_t* Mode , double Alpha , HTuple* Coeffs )
(
Windows only)
def info_edges (filter : str, mode : str, alpha : float) -> Tuple[int, Sequence[int]]
描述
info_edges info_edges InfoEdges InfoEdges InfoEdges info_edges returns the coefficients Coeffs Coeffs Coeffs Coeffs coeffs coeffs and an estimate
of the width Size Size Size Size size size of any of the filters used in edges_image edges_image EdgesImage EdgesImage EdgesImage edges_image 。To do so, the corresponding continuous impulse responses of the filters are
sampled until the first filter coefficient is smaller than five
percent of the largest coefficient. Alpha Alpha Alpha Alpha alpha alpha is the filter
parameter (see edges_image edges_image EdgesImage EdgesImage EdgesImage edges_image ). Seven edge operators are
supported (parameter Filter Filter Filter Filter filter filter ):
'deriche1' "deriche1" "deriche1" "deriche1" "deriche1" "deriche1" , 'lanser1' "lanser1" "lanser1" "lanser1" "lanser1" "lanser1" , 'deriche2' "deriche2" "deriche2" "deriche2" "deriche2" "deriche2" ,
'lanser2' "lanser2" "lanser2" "lanser2" "lanser2" "lanser2" , 'shen' "shen" "shen" "shen" "shen" "shen" , 'mshen' "mshen" "mshen" "mshen" "mshen" "mshen" 和
'canny' "canny" "canny" "canny" "canny" "canny" .
The parameter Mode Mode Mode Mode mode mode ('edge' "edge" "edge" "edge" "edge" "edge" /'smooth' "smooth" "smooth" "smooth" "smooth" "smooth" ) is used to
determine whether the corresponding edge or smoothing operator is to be
sampled.
The Canny operator (which uses Gaussian smoothing)
is implemented using conventional filter masks. Therefore, for the Canny
filter, the coefficients Coeffs Coeffs Coeffs Coeffs coeffs coeffs of the one-dimensional impulse
responses are returned as
. All
other filters are implemented recursively; here, the Coeffs Coeffs Coeffs Coeffs coeffs coeffs are
coefficients of a corresponding non-recursive filter.
注意
请注意,若使用域缩减后的图像作为输入,滤波器算子可能会返回意外结果。请参阅 滤波器 一章
执行信息
多线程类型:可重入(与非独占算子并行运行)。
多线程作用域:全局(可从任何线程调用)。
未采用并行化处理。
参数
Filter Filter Filter Filter filter filter (输入控制) string → HTuple str HTuple Htuple (string) (string ) (HString ) (char* )
Name of the edge operator.
默认值:
'lanser2'
"lanser2"
"lanser2"
"lanser2"
"lanser2"
"lanser2"
值列表:
'canny' "canny" "canny" "canny" "canny" "canny" , 'deriche1' "deriche1" "deriche1" "deriche1" "deriche1" "deriche1" , 'deriche2' "deriche2" "deriche2" "deriche2" "deriche2" "deriche2" , 'lanser1' "lanser1" "lanser1" "lanser1" "lanser1" "lanser1" , 'lanser2' "lanser2" "lanser2" "lanser2" "lanser2" "lanser2" , 'mshen' "mshen" "mshen" "mshen" "mshen" "mshen" , 'shen' "shen" "shen" "shen" "shen" "shen"
Mode Mode Mode Mode mode mode (输入控制) string → HTuple str HTuple Htuple (string) (string ) (HString ) (char* )
1D edge filter ('edge') or 1D smoothing filter
('smooth').
默认值:
'edge'
"edge"
"edge"
"edge"
"edge"
"edge"
值列表:
'edge' "edge" "edge" "edge" "edge" "edge" , 'smooth' "smooth" "smooth" "smooth" "smooth" "smooth"
Alpha Alpha Alpha Alpha alpha alpha (输入控制) real → HTuple float HTuple Htuple (real) (double ) (double ) (double )
Filter parameter: small values result in strong
smoothing, and thus less detail (opposite for
'canny').
默认值:
0.5
最小增量:
0.01
建议增量:
0.1
限制:
Alpha > 0.0
Size Size Size Size size size (输出控制) integer → HTuple int HTuple Htuple (integer) (int / long) (Hlong ) (Hlong )
Filter width in pixels.
Coeffs Coeffs Coeffs Coeffs coeffs coeffs (输出控制) integer-array → HTuple Sequence[int] HTuple Htuple (integer) (int / long) (Hlong ) (Hlong )
For Canny filters: Coefficients of the “positive”
half of the 1D impulse response.
All others: Coefficients of a corresponding non-recursive
filter.
示例(HDevelop)
read_image(Image,'fabrik')
info_edges('lanser2','edge',0.5,Size,Coeffs)
edges_image(Image,Amp,Dir,'lanser2',0.5,'none',-1,-1)
hysteresis_threshold(Amp,Margin,20,30,30)
示例(C)
read_image(&Image,"fabrik");
info_edges("lanser2","edge",0.5,Size,Coeffs);
edges_image(Image,&Amp,&Dir,"lanser2",0.5,"none",-1,-1);
hysteresis_threshold(Amp,&Margin,20,30,30);
示例(HDevelop)
read_image(Image,'fabrik')
info_edges('lanser2','edge',0.5,Size,Coeffs)
edges_image(Image,Amp,Dir,'lanser2',0.5,'none',-1,-1)
hysteresis_threshold(Amp,Margin,20,30,30)
示例(HDevelop)
read_image(Image,'fabrik')
info_edges('lanser2','edge',0.5,Size,Coeffs)
edges_image(Image,Amp,Dir,'lanser2',0.5,'none',-1,-1)
hysteresis_threshold(Amp,Margin,20,30,30)
示例(HDevelop)
read_image(Image,'fabrik')
info_edges('lanser2','edge',0.5,Size,Coeffs)
edges_image(Image,Amp,Dir,'lanser2',0.5,'none',-1,-1)
hysteresis_threshold(Amp,Margin,20,30,30)
结果
info_edges info_edges InfoEdges InfoEdges InfoEdges info_edges 在所有参数正确时返回 2 (H_MSG_TRUE )。当输入为空时,可设置行为通过算子 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>) 。如有必要,则抛出异常。
可能的后继
edges_image edges_image EdgesImage EdgesImage EdgesImage edges_image ,
threshold threshold Threshold Threshold Threshold threshold ,
skeleton skeleton Skeleton Skeleton Skeleton skeleton
另见
edges_image edges_image EdgesImage EdgesImage EdgesImage edges_image
模块
基础