anchor.diff:           '     ll_ene,   data_ene,'//&
            '  prior_ene,   cpu_time,       pacc'
   
  -    if (niter_agd > 0) call map_all('adam',nvars,nclasses,seq,seqs_table,prm,fmodel,&
  +    if (niter_agd > 0) call map_all('ada',nvars,nclasses,seq,seqs_table,prm,fmodel,&
            fdata,data_format,ulog,beta,lambda,&
            niter_agd,mc_nsweeps,tot_iter,nupdate)
       
  
positive.code:           ! compute gradient  of the cost function
            call cost_compute_gradient(fdata,fmodel,lambda,prm,grd)
  
            if(.not. fixed_gamma) then
               gamma1 = real(iter)/real(iter+10)
               gamma2 = real(iter)/real(iter+10)
            end if
  
            select case(trim(algorithm))
            case('gd')
               prm = prm - eps_map * grd
  
negative.code:     real(kflt)                      :: facc
      real(kflt)                      :: grd_nrm ! grd_nrm to be minimized; magnitude of the gradient
      real(kflt)                      :: max_err
      real(kflt),parameter            :: gamma1=0.9_kflt,gamma2=0.999_kflt
      logical                         :: fixed_gamma = .true.
      real(kflt)                      :: g1,g2
      integer, parameter              :: nt0=10
  
  
      dim1 = nvars*nclasses
  