Neuron®
The Neuron® is the basis for the creation of open and secure federated networks for smart societies.
Loading...
Searching...
No Matches
Close.cs
2
4{
8 public static partial class MorphologicalOperations
9 {
14 public static Matrix<float> Close(this Matrix<float> M)
15 {
16 return M.Close(3, 3, 0f, 1f);
17 }
18
24 public static Matrix<float> Close(this Matrix<float> M, int NeighborhoodWidth)
25 {
26 return M.Close(NeighborhoodWidth, NeighborhoodWidth, 0f, 1f);
27 }
28
35 public static Matrix<float> Close(this Matrix<float> M, int NeighborhoodWidth,
36 int NeighborhoodHeight)
37 {
38 return M.Close(NeighborhoodWidth, NeighborhoodHeight, 0f, 1f);
39 }
40
49 public static Matrix<float> Close(this Matrix<float> M, int NeighborhoodWidth,
50 int NeighborhoodHeight, float MinThreshold, float MaxThreshold)
51 {
52 return M.
53 Dilate(NeighborhoodWidth, NeighborhoodHeight, MaxThreshold).
54 Erode(NeighborhoodWidth, NeighborhoodHeight, MinThreshold);
55 }
56
62 public static Matrix<float> Close(this Matrix<float> M, Shape Kernel)
63 {
64 return M.Close(Kernel, 0f, 1f);
65 }
66
74 public static Matrix<float> Close(this Matrix<float> M, Shape Kernel, float MinThreshold,
75 float MaxThreshold)
76 {
77 return M.
78 Dilate(Kernel, MaxThreshold).
79 Erode(Kernel, MinThreshold);
80 }
81
86 public static Matrix<int> Close(this Matrix<int> M)
87 {
88 return M.Close(3, 3, 0, 0x01000000);
89 }
90
96 public static Matrix<int> Close(this Matrix<int> M, int NeighborhoodWidth)
97 {
98 return M.Close(NeighborhoodWidth, NeighborhoodWidth, 0, 0x01000000);
99 }
100
107 public static Matrix<int> Close(this Matrix<int> M, int NeighborhoodWidth,
108 int NeighborhoodHeight)
109 {
110 return M.Close(NeighborhoodWidth, NeighborhoodHeight, 0, 0x01000000);
111 }
112
121 public static Matrix<int> Close(this Matrix<int> M, int NeighborhoodWidth,
122 int NeighborhoodHeight, int MinThreshold, int MaxThreshold)
123 {
124 return M.
125 Dilate(NeighborhoodWidth, NeighborhoodHeight, MaxThreshold).
126 Erode(NeighborhoodWidth, NeighborhoodHeight, MinThreshold);
127 }
128
134 public static Matrix<int> Close(this Matrix<int> M, Shape Kernel)
135 {
136 return M.Close(Kernel, 0, 0x01000000);
137 }
138
146 public static Matrix<int> Close(this Matrix<int> M, Shape Kernel, int MinThreshold,
147 int MaxThreshold)
148 {
149 return M.
150 Dilate(Kernel, MaxThreshold).
151 Erode(Kernel, MinThreshold);
152 }
153
154 }
155}
Shape for morphological operations.
Definition: Shape.cs:9
Implements a Matrix, basic component for computations in Image Processing and Computer Vision.
Definition: Matrix.cs:12
static Matrix< float > Close(this Matrix< float > M, int NeighborhoodWidth, int NeighborhoodHeight, float MinThreshold, float MaxThreshold)
Closes an image by first dilating it, and then eroding it.
Definition: Close.cs:49
static Matrix< float > Close(this Matrix< float > M, int NeighborhoodWidth, int NeighborhoodHeight)
Closes an image by first dilating it, and then eroding it.
Definition: Close.cs:35
static Matrix< float > Close(this Matrix< float > M, int NeighborhoodWidth)
Closes an image by first dilating it, and then eroding it.
Definition: Close.cs:24
static Matrix< float > Erode(this Matrix< float > M)
Erodes an image by replacing a pixel with the minimum value of a square neighborhood of the pixel.
Definition: Erode.cs:17
static Matrix< int > Close(this Matrix< int > M, int NeighborhoodWidth, int NeighborhoodHeight)
Closes an image by first dilating it, and then eroding it.
Definition: Close.cs:107
static Matrix< int > Close(this Matrix< int > M)
Closes an image by first dilating it, and then eroding it.
Definition: Close.cs:86
static Matrix< int > Close(this Matrix< int > M, int NeighborhoodWidth)
Closes an image by first dilating it, and then eroding it.
Definition: Close.cs:96
static Matrix< float > Close(this Matrix< float > M, Shape Kernel, float MinThreshold, float MaxThreshold)
Closes an image by first dilating it, and then eroding it.
Definition: Close.cs:74
static Matrix< int > Close(this Matrix< int > M, Shape Kernel, int MinThreshold, int MaxThreshold)
Closes an image by first dilating it, and then eroding it.
Definition: Close.cs:146
static Matrix< float > Close(this Matrix< float > M, Shape Kernel)
Closes an image by first dilating it, and then eroding it.
Definition: Close.cs:62
static Matrix< int > Close(this Matrix< int > M, int NeighborhoodWidth, int NeighborhoodHeight, int MinThreshold, int MaxThreshold)
Closes an image by first dilating it, and then eroding it.
Definition: Close.cs:121
static Matrix< float > Close(this Matrix< float > M)
Closes an image by first dilating it, and then eroding it.
Definition: Close.cs:14
static Matrix< float > Dilate(this Matrix< float > M)
Dilates an image by replacing a pixel with the maximum value of a square neighborhood of the pixel.
Definition: Dilate.cs:17
static Matrix< int > Close(this Matrix< int > M, Shape Kernel)
Closes an image by first dilating it, and then eroding it.
Definition: Close.cs:134