# A q-Extension of Sigmoid Functions and the Application for Enhancement of Ultrasound Images

^{1}

^{2}

^{*}

## Abstract

**:**

## 1. Introduction

## 2. The $\mathit{q}$-Exponential Distribution

## 3. Proposed $\mathit{q}$-Sigmoid Functions

- q-Sigmoid for $q<1$:$${\tilde{I}}_{1}(I;\beta ,\alpha ,\lambda ,q)=\frac{2}{1+{\left[1+\lambda (1-q)\left(\frac{|I-\beta |}{\alpha}\right)\right]}^{\frac{1}{1-q}}},$$
- q-Sigmoid for $q>1$:$$\begin{array}{c}\hfill {\tilde{I}}_{2}(I;\beta ,\alpha ,\lambda ,q)=\left\{\begin{array}{cc}\frac{1}{1+{\left[1+\lambda (1-q)F\left(I\right)\right]}^{\frac{1}{1-q}}},\hfill & \mathrm{if}\phantom{\rule{0.277778em}{0ex}}\phantom{\rule{1.em}{0ex}}I\ne \beta \hfill \\ 1\hfill & \mathrm{otherwise}\hfill \end{array}\begin{array}{c}\hfill \end{array}\right.,\end{array}$$$$F\left(I\right)=-\frac{1}{\left(\frac{|I-\beta |}{\alpha}\right)}.$$

- (i)
- Both sigmoid and q-sigmoid functions have global maximum at $I=\beta $.
- (ii)
- Equation (12) seems to have an asymptotic behavior for large values of I.
- (iii)
- The slope is given by$$\underset{I\to {\beta}_{\pm}}{lim}\frac{df}{dI},$$
- (iv)
- (v)
- We shall analyze Equation (15) to get the way in which the q value influences the decay for $f\in \left\{{\tilde{I}}_{1},{\tilde{I}}_{2}\right\}$ and analogously for expression ${I}_{2}$ with respect to $\lambda $.
- (vi)

## 4. Analysis of the Derivatives

- Derivative of sigmoid in Equation (9) for $I>\beta $:$$\frac{d{I}_{1}}{dI}=-2\left(\frac{\lambda}{\alpha}\right){\left(1+exp\left[\lambda \left(\frac{I-\beta}{\alpha}\right)\right]\right)}^{-2}\left(exp\left[\lambda \left(\frac{I-\beta}{\alpha}\right)\right]\right).$$
- Derivative of sigmoid in Equation (10) for $I>\beta $:$$\frac{d{I}_{2}}{dI}=-\frac{\lambda}{\alpha}{\left(\frac{I-\beta}{\alpha}\right)}^{-2}{\left(1+exp\left(-\frac{\lambda}{\left(\frac{I-\beta}{\alpha}\right)}\right)\right)}^{-1}exp\left(-\frac{\lambda}{\left(\frac{I-\beta}{\alpha}\right)}\right).$$
- Derivative of q-sigmoid (Equation (11)) if $q<1$ and $I>\beta $:$$\frac{d{\tilde{I}}_{1}}{dI}=-\lambda \frac{2}{\alpha}{\left(1+{\left[1+\lambda (1-q)\left(\frac{I-\beta}{\alpha}\right)\right]}^{\frac{1}{1-q}}\right)}^{-2}{\left[1+\lambda (1-q)\left(\frac{I-\beta}{\alpha}\right)\right]}^{\frac{q}{1-q}}.$$
- Derivative of q-sigmoid, given by Equation (12), if $q>1$ and $I>\beta $:$$\frac{d{\tilde{I}}_{2}}{dI}=-\frac{\lambda}{\alpha}{\left(1+{\left[1+\lambda (1-q)F\left(I\right)\right]}^{\frac{1}{1-q}}\right)}^{-2}{\left[1+\lambda (1-q)F\left(I\right)\right]}^{\frac{q}{1-q}}{\left(\frac{I-\beta}{\alpha}\right)}^{-2}.$$

## 5. Experimental Results

#### 5.1. Locally Linear Behavior

#### 5.2. Generalized Behavior

#### 5.3. Experiments with Ultrasound Images

#### 5.4. q-Sigmoid and CNN Segmentation

## 6. Discussion

## 7. Conclusions

## Author Contributions

## Funding

## Acknowledgments

## Conflicts of Interest

## References

- Imtiaz, M.S.; Wahid, K.A. Color Enhancement in Endoscopic Images Using Adaptive Sigmoid Function and Space Variant Color Reproduction. Comp. Math. Methods Med.
**2015**, 2015, 607407. [Google Scholar] [CrossRef] - Foruzan, A.H.; Chen, Y.W. Improved segmentation of low-contrast lesions using sigmoid edge model. Int. J. Comput. Assist. Radiol. Surg.
**2015**, 11, 1267–1283. [Google Scholar] [CrossRef] [PubMed] - Gupta, B.; Agarwal, T.K. New contrast enhancement approach for dark images with non-uniform illumination. Comput. Electr. Eng.
**2017**. [Google Scholar] [CrossRef] - Jebadurai, J.; Peter, J.D. SK-SVR: Sigmoid kernel support vector regression based in-scale single image super-resolution. Pattern Recognit. Lett.
**2017**, 94, 144–153. [Google Scholar] [CrossRef] - Lee, C.C.; Shih, C.Y. Classification of Liver Disease from CT Images Using Sigmoid Radial Basis Function Neural Network. In Proceedings of the 2009 WRI World Congress on Computer Science and Information Engineering, Los Angeles, CA, USA, 31 March–2 April 2009; Volume 5, pp. 656–660. [Google Scholar]
- Kondo, T.; Ueno, J.; Takao, S. Hybrid Multi-layered GMDH-type Neural Network Using Principal Component Regression Analysis and its Application to Medical Image Diagnosis of Liver Cancer. Procedia Comput. Sci.
**2013**, 22, 172–181. [Google Scholar] [CrossRef] - Gandhamal, A.; Talbar, S.; Gajre, S.; Hani, A.F.M.; Kumar, D. Local gray level S-curve transformation: A generalized contrast enhancement technique for medical images. Comput. Biol. Med.
**2017**, 83, 120–133. [Google Scholar] [CrossRef] [PubMed] - Huang, S.M.; Liu, H.L.; Li, M.L. Improved temperature imaging of focused ultrasound thermal therapy using a sigmoid model based cross-correlation algorithm. In Proceedings of the 2012 IEEE International Ultrasonics Symposium, Dresden, Germany, 7–10 October 2012; pp. 2766–2768. [Google Scholar]
- Shao, H.; Zhang, Y.; Xian, M.; Cheng, H.; Xu, F.; Ding, J. A saliency model for automated tumor detection in breast ultrasound images. In Proceedings of the 2015 IEEE International Conference on Image Processing—ICIP, Quebec City, QC, Canada, 27–30 September 2015; pp. 1424–1428. [Google Scholar]
- Almajalid, R.; Shan, J.; Du, Y.; Zhang, M. Development of a Deep-Learning-Based Method for Breast Ultrasound Image Segmentation. In Proceedings of the 2018 17th IEEE International Conference on Machine Learning and Applications (ICMLA), Orlando, FL, USA, 17–20 December 2018; pp. 1103–1108. [Google Scholar]
- Luo, X.; Zhang, Z.; Zhang, C.; Wu, X. Multi-focus image fusion using HOSVD and edge intensity. J. Vis. Commun. Image Represent.
**2017**, 45, 46–61. [Google Scholar] [CrossRef] - Zhang, X.; Li, X.; Feng, Y. A new multifocus image fusion based on spectrum comparison. Signal Process.
**2016**, 123, 127–142. [Google Scholar] [CrossRef] - Luo, X.; Zhang, Z.; Wu, X. Image Fusion Using Region Segmentation and Sigmoid Function. In Proceedings of the 2014 22nd International Conference on Pattern Recognition, Stockholm, Sweden, 24–28 August 2014; pp. 1049–1054. [Google Scholar]
- Jung, C.; Cao, L.; Liu, H.; Kim, J. Visual comfort enhancement in stereoscopic 3D images using saliency-adaptive nonlinear disparity mapping. Displays
**2015**, 40, 17–23. [Google Scholar] [CrossRef] - Tsallis, C.; Mendes, R.; Plastino, A. The role of constraints within generalized nonextensive statistics. Phys. A Stat. Mech. Its Appl.
**1998**, 261, 534–554. [Google Scholar] [CrossRef] - Tsallis, C. Nonextensive Statistics: Theoretical, Experimental and Computational Evidences and Connections. Braz. J. Phys.
**1999**, 29, 1–35. [Google Scholar] [CrossRef] - Borges, E.P. Irreversibilidade, Desordem e Incerteza: Tres Visoes da Generalizacao do Conceito de Entropia. Rev. Bras. De Ensino De Fis.
**1999**, 21, 453. [Google Scholar] - Anastasiadis, A. Special Issue: Tsallis Entropy. Entropy
**2012**, 14, 174–176. [Google Scholar] [CrossRef] - Zang, W.; Wang, Z.; Jiang, D.; Liu, X.; Jiang, Z. Classification of MRI Brain Images Using DNA Genetic Algorithms Optimized Tsallis Entropy and Support Vector Machine. Entropy
**2018**, 20, 964. [Google Scholar] [CrossRef] - Albuquerque, M.P.; Albuquerque, M.P.; Esquef, I.A.; Mello, A.R.G. Image thresholding using Tsallis entropy. Pattern Recognit. Lett.
**2004**, 25, 1059–1065. [Google Scholar] [CrossRef] - Rodrigues, P.S.; Wachs-Lopes, G.A.; Erdmann, H.R.; Ribeiro, M.P.; Giraldi, G.A. Improving a firefly meta-heuristic for multilevel image segmentation using Tsallis entropy. Pattern Anal. Appl.
**2015**, 20, 1–20. [Google Scholar] [CrossRef] - Rodrigues, P.S.; Chang, R.F.; Giraldi, G.A.; Suri, J.S. Non-extensive entropy for cad systems of breast cancer images. In Proceedings of the 19th Brazilian Symposium on Computer Graphics and Image Processing, Manaus, Brazil, 8–11 October 2006; pp. 121–128. [Google Scholar]
- Sparavigna, A.C. On the Role of Tsallis Entropy in Image Processing. Int. Sci. Res. J.
**2015**, 1, 16–24. [Google Scholar] [CrossRef] - Sezgin, M.; Sankur, B. Survey over image thresholding techniques and quantitative performance evaluation. J. Electron. Imaging
**2004**, 13, 146–168. [Google Scholar] - Ronneberger, O.; Fischer, P.; Brox, T. U-Net: Convolutional Networks for Biomedical Image Segmentation. In Medical Image Computing and Computer-Assisted Intervention (MICCAI); LNCS; Springer: Cham, Switzerland, 2015; Volume 9351, pp. 234–241. [Google Scholar]
- Tsallis, C. What are the numbers that experiments provide. Quim. Nova
**1994**, 17, 468–471. [Google Scholar] - Rodrigues, P.S.; Giraldi, G.A.; Provenzano, M.; Faria, M.D.; Chang, R.F.; Suri, J.S. A new methodology based on q-entropy for breast lesion classification in 3-D ultrasound images. In Proceedings of the 28th International Conference of the IEEE Engineering in Medicine and Biology Society—EMBS’06, New York, NY, USA, 30 August–3 September 2006; pp. 1048–1051. [Google Scholar]
- Rodrigues, P.S.; Giraldi, G.A. Computing the q-index for Tsallis Nonextensive Image Segmentation. In Proceedings of the SIBIGRAPI 2009, Rio de Janeiro, Brazil, 11–15 October 2009; pp. 232–237. [Google Scholar]
- Rodrigues, P.S.; Giraldi, G.A. Improving the non-extensive medical image segmentation based on Tsallis entropy. Pattern Anal. Appl.
**2011**, 14, 369–379. [Google Scholar] [CrossRef] - Gonzalez, R.; Woods, R. Processamento Digital de Imagens, 3rd ed.; Pearson Prentice Hall: Upper Saddle River, NJ, USA, 2010. [Google Scholar]
- Serra, J. (Ed.) Image Analysis and Mathematical Morphology; Academic: New York, NY, USA, 1982. [Google Scholar]
- Chen, Y. An allometric scaling relation based on logistic growth of cities. Chaos Solitons Fractals
**2014**, 65, 65–77. [Google Scholar] [CrossRef] - Chen, Y.G. Logistic Models of Fractal Dimension Growth of Urban Morphology. Fractals
**2018**, 26. [Google Scholar] [CrossRef] - Jain, A.K. Fundamentals of Digital Image Processing; Prentice-Hall, Inc.: Upper Saddle River, NJ, USA, 1989. [Google Scholar]
- Giraldi, G.A.; Rodrigues, P.S.S. Theoretical Elements in Fourier Analysis of q-Gaussian Functions. Theor. Appl. Inform.
**2016**, 27, 16–44. [Google Scholar] - Borges, E.P.; Tsallis, C.; Miranda, J.G.V.; Andrade, R.F.S. Mother wavelet functions generalized through q-exponentials. J. Phys. A Math. Gen.
**2004**, 37, 9125. [Google Scholar] [CrossRef] - Johal, R.S. q calculus and entropy in nonextensive statistical physics. Phys. Rev. E
**1998**, 58, 4147–4151. [Google Scholar] [CrossRef] - Wachs-Lopes, G.; Horvath, M.; Giraldi, G.; Rodrigues, P. A strategy based on non-extensive statistics to improve frame-matching algorithms under large viewpoint changes. Signal Process. Image Commun.
**2019**, 75, 44–54. [Google Scholar] [CrossRef]

**Figure 1.**An example of the luminance transformation obtained by Equation (9) with the domain $0\le I(x,y)\le L$ and parameters $\beta $ and $\alpha $ indicated. The upper row shows the input image while the bottom shows the obtained result with an enhancement of the region nearby ${I}_{1}(\beta ,\alpha ,\lambda )$.

**Figure 5.**(

**a**) The intensity profile of a normalized 2-D Gaussian distribution, with a mean $\mu =175$ and a variance $\delta =30$ in orthogonal view; (

**b**) the corresponding 3-D perspective; (

**c**) an example of filtering with sigmoid when $\alpha =0.02$; (

**d**) an example of filtering with sigmoid when $\alpha =0.01$.

**Figure 6.**(

**a**) The intensity profile of a 2-D Gaussian distribution in orthogonal view with the corresponding convex-hull points indicating the ground truth area; (

**b**) the corresponding convex-hull filled area; and (

**c**) the convex-hull-filled area achieved when $\alpha =0.03$, $\beta =1.0$, $\lambda =1.0$, and $q=1.0$.

**Figure 7.**(

**a**) The convex-hull area achieved when $q=0.95$; (

**b**) the convex-hull area achieved when $q=0.98$; (

**c**) the convex-hull area achieved when $q=0.99$; and (

**d**) the convex-hull area achieved when $q=1.0$.

**Figure 8.**The overview performance under increasing $\alpha $ values. Each curve corresponds to an $\alpha $ value used for an enhancement filtering of the artificial grayscale 3-D Gaussian profile. We also show $Err$ for $q>1.0$.

**Figure 9.**Four examples of breast ultrasound images with lesions in a darker gray scale nearby the center of the images.

**Figure 10.**The results of application of enhancing methods over the four images of Figure 9. (

**a**–

**d**) The results of histogram equalization. (

**e**–

**h**) The segmentation after histogram equalization. (

**i**–

**l**) The slicing map results. (

**m**–

**p**) The segmentation after slicing. (

**q**–

**t**) The results obtained with q-sigmoid when $\beta =0.15$, $\alpha =0.03$, $\lambda =1.0$, and $q=2.0$ in Equation (12). (

**u**–

**z**) The segmentation results after preprocessing with q-sigmoid.

**Figure 11.**An overview performance under histogram equalization (first left block), slicing (second block), and q-sigmoids (Equations (11) and (12)) with increasing q values (third to eighth block). Each block stands for a mean and standard deviation of absolute mean brightness error (AMBE) measure in the vertical axis.

**Figure 12.**(

**a**–

**c**) Original ultrasound images. (

**d**–

**f**) The segmentation ground-truth. (

**g**–

**i**) The segmentation obtained by $CNN$ after filtering by q-sigmoid when $\beta =0.15$, $\alpha =0.03$, $\lambda =1.0$, and $q=0.1$ in Equation (12).

**Figure 13.**(

**a**) A comparative performance of the $CN{N}_{A}$ output without filtering (black line) and with preprocessing by q-sigmoid ($q=0.1$, $\beta =1.0$, $\alpha =0.8$, $\gamma =1.0$ in Equation (11)), shown by the blue line. The vertical axis is the similarity calculated according to Equation (29), and the horizontal axis lists the synthetic images with different noise levels randomly chosen; (

**b**) The analogous result for $CN{N}_{U}$ with $q=0.1$, $\beta =0.6$, $\alpha =0.2$, and $\gamma =1.0$ in Equation (11).

**Figure 14.**(

**a**) The profile of fractional logistic function with ${D}_{max}=1$, $C=1$, $b=2$, $k=0.05$, and ${I}_{0}=128$; (

**b**) Negative of the fractional logistic function; (

**c**) The S-shaped logistic function obtained by setting $b=1$ and keeping the other parameters unchanged.

**Table 1.**$Err$ demonstration under a range of q values with $q<1.0$, $\alpha =0.03$, $\beta =1.0$, and $\lambda =1.0$.

q | 0.7 | 0.8 | 0.9 | 0.95 | 0.98 | 0.99 | 1.0 |

Err | 0.0 | 0.0 | 0.0 | 0.00 | 0.0 | 0.00 | 0.0001 |

q | 0.7 | 0.8 | 0.9 | 0.95 | 0.98 | 0.99 | 1.0 |

Err | 0.0 | 0.0 | 0.0 | 0.0052 | 0.8412 | 0.8992 | 0.9266 |

$\mathit{Err}\setminus \mathit{q}$ | 0.7 | 0.8 | 0.9 | 0.95 | 0.98 | 0.99 | 1.0 |
---|---|---|---|---|---|---|---|

$\alpha =0.01$ | 0.0 | 0.0 | 0.0 | 0.0052 | 0.8412 | 0.8992 | 0.9426 |

$\alpha =0.015$ | 0.0 | 0.0 | 0.0 | 0.0 | 0.3893 | 0.7298 | 0.8996 |

$\alpha =0.02$ | 0.0 | 0.0 | 0.0 | 0.0 | 0.0037 | 0.0182 | 0.8173 |

$\alpha =0.025$ | 0.0 | 0.0 | 0.0 | 0.0 | 0.0000 | 0.0027 | 0.5422 |

$\alpha =0.03$ | 0.0 | 0.0 | 0.0 | 0.0 | 0.0000 | 0.00 | 0.001 |

**Table 4.**$Err$ demonstration under a range of q values around $q=1.0$ and a range of $\alpha $ values.

$\mathit{Err}\setminus \mathit{q}$ | 1.0 | 1.001 | 1.1 | 1.2 |
---|---|---|---|---|

$\alpha =0.01$ | 0.0 | 0.00 | 0.00 | 0.0 |

$\alpha =0.015$ | 0.0 | 0.00 | 0.00 | 0.0 |

$\alpha =0.02$ | 0.0 | 0.00 | 0.00 | 0.0 |

$\alpha =0.025$ | 0.0 | 0.00 | 0.00 | 0.0 |

$\alpha =0.03$ | 0.0 | 0.00 | 0.00 | 0.0 |

© 2019 by the authors. Licensee MDPI, Basel, Switzerland. This article is an open access article distributed under the terms and conditions of the Creative Commons Attribution (CC BY) license (http://creativecommons.org/licenses/by/4.0/).

## Share and Cite

**MDPI and ACS Style**

Sergio Rodrigues, P.; Wachs-Lopes, G.; Morello Santos, R.; Coltri, E.; Antonio Giraldi, G.
A *q*-Extension of Sigmoid Functions and the Application for Enhancement of Ultrasound Images. *Entropy* **2019**, *21*, 430.
https://doi.org/10.3390/e21040430

**AMA Style**

Sergio Rodrigues P, Wachs-Lopes G, Morello Santos R, Coltri E, Antonio Giraldi G.
A *q*-Extension of Sigmoid Functions and the Application for Enhancement of Ultrasound Images. *Entropy*. 2019; 21(4):430.
https://doi.org/10.3390/e21040430

**Chicago/Turabian Style**

Sergio Rodrigues, Paulo, Guilherme Wachs-Lopes, Ricardo Morello Santos, Eduardo Coltri, and Gilson Antonio Giraldi.
2019. "A *q*-Extension of Sigmoid Functions and the Application for Enhancement of Ultrasound Images" *Entropy* 21, no. 4: 430.
https://doi.org/10.3390/e21040430