h = fspecial(type)

h = fspecial(type,para)其中type指定算子的类型,para指定相应的参数;

type的类型有:

1、'average'

averaging filter为均值滤波,参数为hsize代表模板尺寸,默认值为【3,3】。

H = FSPECIAL('average',HSIZE) returns an averaging filter H of size

HSIZE. HSIZE can be a vector specifying the number of rows and columns in

H or a scalar, in which case H is a square matrix.

The default HSIZE is [3 3].

2、'disk'

circular averaging filter

为圆形区域均值滤波,参数为radius代表区域半径,默认值为5.

H = FSPECIAL('disk',RADIUS) returns a circular averaging filter

(pillbox) within the square matrix of side 2*RADIUS+1.

The default RADIUS is 5.

3、'gaussian'

Gaussian lowpass filter

为高斯低通滤波,有两个参数,hsize表示模板尺寸,默认值为【3 3】,sigma为滤波器的标准值,单位为像素,默认值为0.5.

H = FSPECIAL('gaussian',HSIZE,SIGMA) returns a rotationally

symmetric Gaussian lowpass filter

of size HSIZE with standard

deviation SIGMA (positive). HSIZE can be a vector specifying the

number of rows and columns in H or a scalar, in which case H is a

square matrix.

The default HSIZE is [3 3], the default SIGMA is 0.5.

4、'laplacian' filter approximating the 2-D Laplacian operator

为拉普拉斯算子,参数alpha用于控制算子形状,取值范围为【0,1】,默认值为0.2.

H = FSPECIAL('laplacian',ALPHA) returns a 3-by-3 filter

approximating the shape of the two-dimensional Laplacian

operator. The parameter ALPHA controls the shape of the

Laplacian and must be in the range 0.0 to 1.0.

The default ALPHA is 0.2.

5、'log'

Laplacian of Gaussian filter

为拉普拉斯高斯算子,有两个参数,hsize表示模板尺寸,默认值为【3 3】,sigma为滤波器的标准差,单位为像素,默认值为0.5.

H = FSPECIAL('log',HSIZE,SIGMA) returns a rotationally symmetric

Laplacian of Gaussian filter of size HSIZE with standard deviation

SIGMA (positive). HSIZE can be a vector specifying the number of rows

and columns in H or a scalar, in which case H is a square matrix.

The default HSIZE is [5 5], the default SIGMA is 0.5.

6、'motion'

motion filter

为运动模糊算子,有两个参数,表示摄像物体逆时针方向以theta角度运动了len个像素,len的默认值为9,theta的默认值为0;

H = FSPECIAL('motion',LEN,THETA) returns a filter to approximate, once

convolved with an image, the linear motion of a camera by LEN pixels,

with an angle of THETA degrees in a counter-clockwise direction. The

filter becomes a vector for horizontal and vertical motions.

The

default LEN is 9, the default THETA is 0, which corresponds to a

horizontal motion of 9 pixels.

7、'prewitt'

Prewitt horizontal edge-emphasizing filter

用于边缘增强,大小为【3 3】,无参数

H = FSPECIAL('prewitt') returns 3-by-3 filter that emphasizes

horizontal edges by approximating a vertical gradient. If you need to

emphasize vertical edges, transpose the filter H: H'.

[1 1 1;0 0 0;-1 -1 -1].

8、'sobel'

Sobel horizontal edge-emphasizing filter

用于边缘提取,无参数

H = FSPECIAL('sobel') returns 3-by-3 filter that emphasizes

horizontal edges utilizing the smoothing effect by approximating a

vertical gradient. If you need to emphasize vertical edges, transpose

the filter H: H'.

[1 2 1;0 0 0;-1 -2 -1].

9、'unsharp'

unsharp contrast enhancement filter

为对比度增强滤波器。参数alpha用于控制滤波器的形状,范围为【0,1】,默认值为0.2.

H = FSPECIAL('unsharp',ALPHA) returns a 3-by-3 unsharp contrast

enhancement filter. FSPECIAL creates the unsharp filter from the

negative of the Laplacian filter with parameter ALPHA. ALPHA controls

the shape of the Laplacian and must be in the range 0.0 to 1.0.

The default ALPHA is 0.2.

matlab special,matlab的special函数用法相关推荐

  1. Matlab中repmat、permute函数用法

    repmat函数用法 复制和平铺矩阵 函数repmat 格式:  B = repmat(A, m, n) %将矩阵A复制m*n块,即B由m*n块A平铺而成 B = repmat(A, [m n])%与 ...

  2. matlab中find()函数用法

    一.基本用法 返回矩阵或向量中非零元素的索引 注意:matlab中下标从1开始 举例: (1)向量 返回非零元素下标 find(vector) x=[1 2 3 0 0 6 7 8 9]; find( ...

  3. matlab randomsample,randperm和randsample函数用法对比

    构建替代数据的时候,一种常见的思路是打乱原数据的排列次序,通过随机置换原数据的排列次序从而产生和原数据系列统计特征(如均值.方差.分布)一致的随机数据.具体到Matlab中,此思路的实现会涉及到两个命 ...

  4. matlab中libsvm的svmtrain函数用法

    这里的LIBSVM是一个由台湾大学林智仁(Lin Chih-Jen)教授等开发的SVM模式识别与回归的软件包,使用简单,功能强大,本文主要介绍其在Matlab中的使用. 注意不是matlab自带的sv ...

  5. matlab中短时傅里叶变换tfrstft函数用法

    [TFR,T,F]=TFRSTFT(X,T,N,H,TRACE) X : 信号. T : 时间序列 (默认值 :1:length(X)). N : 频率点数 (默认值: length(X)). H : ...

  6. matlab中find、sub2ind函数用法

    [i,j,v]=find(A); 解释:i是A中非零元素的行索引(按一列一列的看,第一个非零元素在第几行,看完第一列再看第二列,依次) j是A中非零元素的列索引 v是A中非零元素的值 b=sub2in ...

  7. matlab repmate,MATLAB中“repmat”与“cat”函数的用法

    MATLAB中"repmat"与"cat"函数的用法 1. repmat函数 >> z=repmat(5,2,3) z = 5 5 5 5 5 5 ...

  8. matlab mda,MATLAB中最基本函数plot()的用法

    1二维平面图形 1.1基本图形函数 画出一条正弦曲线和一条余弦曲线 1.1.1绘图参数表 y 黄- 实线. 点 m 紫: 点线o 圆s 正方形 c 青-. 点划线x 叉号d 菱形 r 红- - 虚线+ ...

  9. matlab中trapz,MATLAB中trapz和cumtrapz函数

    这两个函数都是MATLAB中的内置函数,是基于梯形法则的数值积分公式 例如我们有函数y=x^3-2x-3,为了计算在[0,1]上的积分,可以这么做: 其中x和y分别是自变量和对应的值,trapz其实就 ...

  10. 【MATLAB】MATLAB快速入门编程技巧

    目录 1.MATLAB的启动和退出 2.在MATLAB命令窗口中计算数学表达式 3.在MATLAB命令窗口中输入简单矩阵 4.MATLAB的语句和变量 5.MATLAB函数编程 1.MATLAB的启动 ...

最新文章

  1. linux权限管理详解,linux权限管理详解-Go语言中文社区
  2. Elixir: 开发和发布Elixir库
  3. chrome插件开发记录(1)——解决问题“清单文件缺失或不可读”
  4. 【图像处理】Qt+OpenCV自制mini软件——图像二值化器
  5. php 修改图像大小,PHP图像大小调整
  6. 组态王opc_组态王和西门子S7300、S7400系列PLC通讯的几种配置方案
  7. 【干货】2021年技术趋势:全球企业加速数字化转型-德勤.pdf(附下载链接)
  8. 【jQuery笔记Part2】02-jQuery展开收起动画帷幔效果案例下拉菜单案例显示隐藏更多案例折叠菜单案例
  9. EasyPR中文车牌识别系统开发
  10. 那些远去的人,那段伟大的历史【ZZ】
  11. 父与子编程之旅第十章pygame下载+安装+pip更新
  12. Python3.5学习之旅——day5
  13. IT服务管理的实施过程
  14. django官方文档3.0学习笔记 02
  15. 雷达模块感应技术,智能照明LED灯的应用,5.8G雷达感应模块
  16. svn多分支开发合并技巧(idea or tortoiseSVN)
  17. 如何从官网直接下载iTunes?
  18. 航天信息a3服务器怎么打开,航天信息-睿财A3-使用说明.doc
  19. win10进不了系统怎么强制进安全模式
  20. Linux查看全部进程的命令

热门文章

  1. java练习案例_Java版打字练习案例源码
  2. [线段树]打字练习记录
  3. jquery 绑定双击事件优化
  4. 微信隐藏功能系列:微信状态里如何加音乐?有2个小技巧
  5. python header函数_Header函数
  6. 现代企业管理的12法宝(zt)
  7. liunx 安装docker
  8. 886n虚拟服务器ip,tl-wr886n怎么配置ip带宽控制
  9. 域名投毒,DNS污染,域名欺骗,其实就是域名污染。
  10. 运动员等级查询系统C语言,中国运动员等级查询系统