Skip to main content
. 2020 Jul 7;7:297. doi: 10.3389/fmed.2020.00297

Algorithm 1.

Fuzzy concept creation

input : grayscale image I
output: fuzzy set (concept)
1 For the fuzzy concepts Bright, Dark, and Median, specify the intervals of [Brightbegin, Brightend], [Darkbegin, Darkend], and [Medianbegin, Medianend], respectively.
2 Let Brightbegin=(Nf-1)[L-1Nf], Darkend=[L-1Nf], Medianbegin = Darkendleft_overlap, and Medianend = Brightbegin+right_overlap /* Nf is the number of fuzzy concepts, and left_overlap and right_overlap determine the overlapping range of the fuzzy concepts (the overlap range was set to 0 in this paper) */.
3 Set Darkbegin to be the first gk from 0 to Darkend.
4 Set Brightend to be the last gk from Brightbegin to L − 1.
5 In interval [Darkbegin, Darkend], find a pixel gk with the maximum value of p(gk).
6 For the fuzzy concept Dark, create its membership function fDark as follows: mDarkgk, αDarkmDarkDarkbegin, βDarkDarkendmDark.
7 In interval [Medianbegin, Medianend], find a pixel gk with the maximum value of p(gk).
8 For the fuzzy concept Median, create its membership function fMedian as follows: mMediangk, αMedianmMedianMedianbegin, βMedianMedianendmMedian.
9 In interval [Bright, beginBrightend], find a pixel gk with the maximum value of p(gk).
10 For the fuzzy concept Bright, create its membership function fBright as follows: mBrightgk, αBrightmBrightBrightbegin, βBrightBrightendmBright.