R/max_lambda.R

max_lambda <- function(y, graph, delta, loss_weights, pos)
{
   ## X <- as(diag(loss_weights), 'CsparseMatrix')
   grad1  <- 1.0 - y/delta
   grad2 <-  loss_weights * grad1
   grad2  <-  -grad2
   regul <- 'graph-path-conv2'
   egp.res <- spams_flipflop.evalPathCoding(grad2, graph, regul=regul, 
                                   resetflow=TRUE, eval_dual=TRUE,
                                   pos=pos)
   return(egp.res)
}

Try the flipflop package in your browser

Any scripts or data that you put into this service are public.

flipflop documentation built on May 2, 2019, 1:02 a.m.