Github user debasish83 commented on the pull request:

    https://github.com/apache/spark/pull/2705#issuecomment-61211629
  
    @Chanda you can see how to solve equality and bounds in 
QuadraticMinimizer.scala...
    
    Dual of Kernel SVM can be solved using this formulation as long as rank 
don't grow beyond 4000...For larger ranks I am working on a iterative 
version....
    
    Here are some example runs:
    
    ./bin/spark-class org.apache.spark.mllib.optimization.QuadraticMinimizer 
1000 1 1.0 0.99
    
    Inputs are as follows:
    
    rank: 1000 equality: 1 lambda: 1.0 elasticNet beta 0.99
    
    Randomly we generate 1000x1000 dense gram and 1 equality constraint of the 
form 
    alpha1*x1 + alpha2*x2 + ... = b2 (same as hyperplane constraint) with 
randomly generated upper and lower bounds...The problem is as follows:
    
    min x'Hx + c'tx
    s.t Ax = b, lb <= x <= ub
    
    You can also generate more interest equality constraints...
    
    lambda and beta is for elastic net so you should not concern with that...
    
    The output shows the runtime. You are more interested in the last one 
QpEquality...
    
    Generating randomized QPs with rank 1000 equalities 1
    Qp Equality 2875.355 ms iterations 2237 converged true
    
    For 1000x1000 it takes 3 seconds...Note that code is not well optimized yet 
but we tie with Mosek runtime (which is a IP solver)...More data on MOSEK 
comparisons I will add later tonight...
    
    You can partition your data and do a local kernel SVM on each worker 
followed by an averaging step on the master if you are focused on solving the 
dual kernel svm....


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to