Skip to main content
. 2020 Oct 12;20(20):5770. doi: 10.3390/s20205770
Algorithm 1 pseudocode for the proposed algorithm
1. initialize network
2. reset : inputs = 0, Activations = 0
     forward propagation:
3. initialize the inputs do
4. roll over: Activations; cell states
5. loop over a cell, end for
6. do
  for t=0 to n do
    Calculates the gate values :
        inputs gates: itσwxixt+whihft1hft2+wcict1+bi
        forget gates: ftσwxfxt+whfhft1hft2+wcfct1+bf
        loop over the cells is block now
        output gates: otσwxoxt+whohft1hft2+wcoct1+bo
        update the cell:ctftct1+ittanhfwxcxt+whchft1hft2+bc
          final hidden state/ final output : hftottanhfct
   end for
7. Single activity detect
8.  do
  Update the weight
  end for
9. backward propagation do
     for t=0 to n
     inputs gates: δitσwyixt+whihbt+1hbt+2+wcict+1+bi
    forget gates: δftσwyfxt+whfhbt+1hbt+2+wcfct+1+bf
    output gates: δotσwyoxt+whohbt+1hbt+2+wcoct+1+bo
    cell output: δctftδct+1+δittanhbwycxt+whchbt+1hbt+2+bc
10. Hidden state / final output : hbtδottanhbδct
  end for
11. do
    z = hft tends to 1 and hbt tends to 1
    Concurrent activity detect
  end For
12. do for t=0 to n, k = 0 to n-1 do
Φ(zt,zt1,y,t)=expkλkfk(zt,zt1,y,t),Ψ(zu,zv,y,u,v)=expkλkfk(zu,zv,y,u,v)
                  Pz|yλk=Lλk=λkσ2
        end for
13. Interleaved activity detect
14. end for
15. end for
16. end