Skip to main content
. 2016 Dec 10;16(12):2098. doi: 10.3390/s16122098
Algorithm 1. The pseudo code of the constructed classifier.
Input: Training samples set Data=(x1,x2,xN) and number of learning rounds T.
  • 1.

    D1(xi)=1/m % Initialize the weight distribution for all samples

  • 2.

    For t=1, 2, T


  ht(xi)=LCE(Data,Dt(xi)) % Train a learner ht(xi) from Data using Dt(xi) based on the LCE method
  • 3.

      εt=i=1NDt(xi) [yiht(xi)] % Calculate the error of ht(xi)

  • 4.

      If εt > 0.5 then break

  • 5.

      αt=12log[(1εt)εt] % Determine the weight of ht(xi)

  • 6.

      Dt+1=Dt(xi)Zt×{eαtif yi=ht(xi)eαtotherwise % Update the weight distribution for all samples

  • 7.

    End

Output: The proposed classifier H(xi)=sign(t=1Tαtht(xi))