Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/image-processing/2.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Image processing 空间滤波的填充矩阵_Image Processing - Fatal编程技术网

Image processing 空间滤波的填充矩阵

Image processing 空间滤波的填充矩阵,image-processing,Image Processing,例如,我有一个2x2矩阵 1 2 3 4 然后我用2填充它,它变成 x x x x x x x x x x x x x x 1 2 x x x x 3 4 x x x x x x x x x x x x x x 然后我使用border_replicate将值填充到x x x 1 2 x x x x 1 2 x x 1 1 1 2 2 2 3 3 3 4 4 4 x x 3 4 x x x x 3 4 x x 问题是对于位于新矩阵顶点的x,如果我使用border_replicate,它们的

例如,我有一个2x2矩阵

1 2
3 4
然后我用2填充它,它变成

x x x x x x 
x x x x x x
x x 1 2 x x
x x 3 4 x x
x x x x x x
x x x x x x
然后我使用border_replicate将值填充到x

x x 1 2 x x
x x 1 2 x x
1 1 1 2 2 2
3 3 3 4 4 4
x x 3 4 x x
x x 3 4 x x
问题是对于位于新矩阵顶点的x,如果我使用border_replicate,它们的值是多少



非常感谢您

根据您的示例,看起来拐角(从左上角顺时针方向)应该是1、2、4和3。

hmmh,当您投票否决时,请在评论中简要说明