Skip to main content
. 2021 Jun 16;7(6):99. doi: 10.3390/jimaging7060099
Algorithm 1 Direction estimation.
  • 1:

    Use the Sobel operator to obtain the image e of the edges of the noisy and blurry image b.

  • 2:

    Apply a disk mask to cut out some diagonal edges in e, obtaining a new edge image e˜ (Figure 1b).

  • 3:

    Compute the Hough transform h(e˜) (Figure 1c).

  • 4:

    Set ηmax as the value of η corresponding to the column of h(e˜) with maximum 2-norm. (Figure 1d)

  • 5:

    Set θ={90ηmax180π,ηmax0,90ηmax180π,ηmax<0. (yellow line in Figure 1a)