Skip to main content
. 2021 Nov 2;21(21):7286. doi: 10.3390/s21217286
Algorithm 1. FA-Based Feature Optimization.
Start
Step 1: Define fitness function: hx, x=x1, x2, , xd
Step 2: Generate initial population of fireflies Pl, where l=1, 2, 3, , n
Step 3: Compute Brightness Ys=Y0eδs
Step 4: Define Absorption Coefficient δ
  - While(z<MaxGeneration)
    - for l=1:𝕟
      - for m=1:l
        - if (Ym>Yl)
        - Vary attractiveness with distance s via eδs
        - Move firefly l towards m using Plz+1=T0eδslm2PmzPlz+φRand0.5
        - Evaluate new solutions and update brightness
        - end if
      - end for m
    - end for l
    - Find the latest best Firefly
    - Entropy-based activation is applied HΦ
    - Best Optimal Features are Selected ΦNk˜
  - end While
  - Processing results and visualization
End