JuliaSmoothOptimizers / SolverTools.jl

Tools for developing nonlinear optimization solvers.
Other
26 stars 18 forks source link

Call finalize on bmark_solvers to handle CUTEst problems #34

Closed abelsiqueira closed 7 years ago

coveralls commented 7 years ago

Coverage Status

Coverage increased (+0.1%) to 68.707% when pulling 1038500fb9eabdea73ffa33cc0ef2d41bd7d9dbc on abelsiqueira:fix/bmark-solvers-finalize into 30dac885fc5f7096d45011758c3d52dbe2e7df68 on JuliaSmoothOptimizers:master.

abelsiqueira commented 7 years ago

This fails on 0.4 because I use the generator syntax. It's the only way to make it work with CUTEst because we can't open more than one problem at the same time.

dpo commented 7 years ago

The generator expression syntax (...) wasn't available in Julia 0.4, but we could still implement a generator as follows:

function cutest_problems(names :: Vector{ASCIIString})  # names must be an array but that's ok
  function my_iterator()
    for name in names
      produce(CUTEstModel(name))  # like yield in Python
    end
  end
  return Task(my_iterator)
end

# Example usage:
function work_through_stuff(stuff)
  for thing in stuff
    println(thing)
  end
end

work_through_stuff(cutest_problems(["rosenbrock", "hs13", "ncvxqp3"]))

The question is: should we continue to support Julia 0.4?

abelsiqueira commented 7 years ago

I see, wasn't aware of that way to do it. But I think we should drop 0.4. NLPModels already dropped, and CUTEst will follow.

dpo commented 7 years ago

Ok.

coveralls commented 7 years ago

Coverage Status

Coverage increased (+0.1%) to 68.707% when pulling e01c868bb05b24df97c3fc11b53ae053ecd48544 on abelsiqueira:fix/bmark-solvers-finalize into a9f33d555ee77aca1cf8d2fc40bcd8befa7eb789 on JuliaSmoothOptimizers:master.

coveralls commented 7 years ago

Coverage Status

Coverage increased (+0.1%) to 68.707% when pulling 7a7920eb54186597ea001fcb2113660d59d9b614 on abelsiqueira:fix/bmark-solvers-finalize into a9f33d555ee77aca1cf8d2fc40bcd8befa7eb789 on JuliaSmoothOptimizers:master.

abelsiqueira commented 7 years ago

MacroTools.jl 0.3.5 is breaking this (and everything inbetween).