Skip to main content
. 2024 Jun 17;24(12):3917. doi: 10.3390/s24123917
Algorithm 1 Training of ETDiffIR
  • Input:

    LR image μ=ILR, HR image x0=IHR, text caption c, total step T.

  • 1: 

    Initialization: Random sample ϵtN(0,ρ2), t[0,T], T=100.

  • 2: 

    repeat

  • 3: 

       t˜=TIFB(μ,c,t);                              ▷Enhance

  • 4: 

       ϵ^t=f^ϕ(It,c,t˜);                           ▷Predict noise

  • 5: 

       dx=[αt(μx)βt2xlogqt(x)]dt+βtdw˜;    ▷Substitute score into Equation (6)

  • 6: 

       L(ϕ)=Σt=0TγtE[xt(dxt)f^ϕreversedxt1xt1];                    ▷Loss

  • 7: 

       ϕL;                               ▷Gradient descent

  • 8:

    until converged