#12973: Cannot copy() instances of GurobiBackend.
--------------------------------------------------------------------+-------
       Reporter:  e.vaughan                                         |         
Owner:  jason, jkantor
           Type:  defect                                            |        
Status:  new           
       Priority:  minor                                             |     
Milestone:  sage-5.0.1    
      Component:  numerical                                         |    
Resolution:                
       Keywords:  Gurobi, GurobiBackend, MixedIntegerLinearProgram  |   Work 
issues:                
Report Upstream:  N/A                                               |     
Reviewers:                
        Authors:                                                    |     
Merged in:                
   Dependencies:                                                    |      
Stopgaps:                
--------------------------------------------------------------------+-------

Comment (by ncohen):

 Wow !! Very good patch for a first ! `:-D`

 Well, it did not apply cleanly on version 5.1.beta0 but that was to be
 expected if you worked on 4.8 Actually, the replacement from GUROBI to
 Gurobi has been done since, and that was the whole reason why it did not
 apply. I just rebased your patch on 5.1.beta0 and updated it on the trac
 ticket.

 There is a problem though, for your patch does not *compile*. When I apply
 it and type "sage -b" I get this :
 {{{
 Error compiling Cython file:
 ------------------------------------------------------------
 ...
             sage: p.set_objective([2, 5])
 # optional - Gurobi
             sage: p.write_lp(SAGE_TMP+"/lp_problem.lp")
 # optional - Gurobi
         """
         check(self.env, GRBwrite(self.model[0], filename))

     cpdef GurobiBackend copy(self):
          ^
 ------------------------------------------------------------

 sage/numerical/backends/gurobi_backend.pyx:1079:10: C method 'copy' not
 previously declared in definition part of extension type
 Error running command, failed with status 256.
 Error installing modified sage library code.
 }}}

 This is because cdef methods should be added to gurobi_backend.pxd as it
 is added for glpk in glpk_backend.pxd. I will post another patch to do
 exactly that.

 Nathann

-- 
Ticket URL: <http://trac.sagemath.org/sage_trac/ticket/12973#comment:3>
Sage <http://www.sagemath.org>
Sage: Creating a Viable Open Source Alternative to Magma, Maple, Mathematica, 
and MATLAB

-- 
You received this message because you are subscribed to the Google Groups 
"sage-trac" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/sage-trac?hl=en.

Reply via email to