Comments (7)
Actually, it depends what kind of parallelism you have in mind. If you use a queuing system such as Sungrid Engine or LSF to dispatch problems on different, independent machines, and if a fresh CUTEst module is initialized independently on each machine, you should be ok.
from cutest.jl.
Interestingly, even with #97 this doesn't work:
julia> nlp1 = CUTEstModel("HS35")
Minimization problem HS35
nvar = 3, ncon = 1 (1 linear)
julia> nlp2 = CUTEstModel("BARD")
ERROR: CUTEst.CUTEstException(1,"memory allocation error")
in #CUTEstModel#13(::Bool, ::Bool, ::Type{T}, ::String) at /home/tim/.julia/v0.5/CUTEst/src/CUTEst.jl:138
in CUTEst.CUTEstModel(::String) at /home/tim/.julia/v0.5/CUTEst/src/CUTEst.jl:99
julia> finalize(nlp1)
julia> nlp2 = CUTEstModel("BARD")
Minimization problem BARD
nvar = 3, ncon = 0 (0 linear)
That line corresponds to the call to :fortran_open_
, so it's generated by the library rather than julia.
I think that's a strong argument against #97.
from cutest.jl.
Actually, I think the problem is in usetup
.
It seems the problem is the use of global variables inside fortran CUTEst
. I don't think there is any interest in changing that, so maybe this should be closed as wontfix
? @dpo, what do you think?
from cutest.jl.
I was hoping to run lots of CUTEst problems in parallel for some benchmarking. Is that possible currently / are there any hopes of enabling that?
from cutest.jl.
Currently not possible, and maybe impossible without changing the CUTEst source.
I have updated the branch with non-global cutest_lib
in case you want to try to work this out. The example above fails in the same way in the new branch.
from cutest.jl.
Actually, it depends what kind of parallelism you have in mind.
I only have access to four independent machines, so I wanted to use the 32 cores on a single machine rather than going parallel between machines.
This is basically what I had in mind originally:
addprocs(2)
@everywhere using CUTEst
@everywhere function opt(name)
nlp = CUTEstModel(name)
retval = obj(nlp,nlp.meta.x0)
finalize(nlp)
retval
end
pmap(opt, CUTEst.select(contype="unc"))
On both th-multi and master:
ld: cannot find ELFUN.o: No such file or directory
ld: cannot find EXTER.o: No such file or directory
ld: cannot find GROUP.o: No such file or directory
ld: cannot find RANGE.o: No such file or directory
ERROR: On worker 3:
failed process: Process(`ld -shared -o libHILBERTA.so ELFUN.o EXTER.o GROUP.o RANGE.o /scratch/riseth/julia-pkgs/CUTEst/deps/files/cutest/objects/pc64.lnx.gfo/double/libcutest_double.so /home/riseth/.julia/v0.6/CUTEst/src/../deps/usr/lib/libgfortran.so`, ProcessExited(1)) [1]
pipeline_error at ./process.jl:682
run at ./process.jl:651
#13 at /home/riseth/.julia/v0.6/CUTEst/src/CUTEst.jl:98
cd at ./file.jl:70
#sifdecoder#12 at /home/riseth/.julia/v0.6/CUTEst/src/CUTEst.jl:92
#sifdecoder at ./<missing>:0
#16 at /home/riseth/.julia/v0.6/CUTEst/src/CUTEst.jl:119
cd at ./file.jl:70
#CUTEstModel#15 at /home/riseth/.julia/v0.6/CUTEst/src/CUTEst.jl:111
opt at ./REPL[7]:2
#106 at ./distributed/process_messages.jl:268 [inlined]
run_work_thunk at ./distributed/process_messages.jl:56
macro expansion at ./distributed/process_messages.jl:268 [inlined]
#105 at ./event.jl:73
Stacktrace:
[1] #571 at ./asyncmap.jl:178 [inlined]
[2] foreach(::Base.##571#573, ::Array{Any,1}) at ./abstractarray.jl:1733
[3] maptwice(::Function, ::Channel{Any}, ::Array{Any,1}, ::Array{Any,1}, ::Vararg{Array{Any,1},N} where N) at ./asyncmap.jl:178
[4] wrap_n_exec_twice(::Channel{Any}, ::Array{Any,1}, ::Base.Distributed.##204#207{WorkerPool}, ::Function, ::Array{Any,1}, ::Vararg{Array{Any,1},N} where N) at ./asyncmap.jl:154
[5] #async_usemap#556(::Function, ::Void, ::Function, ::Base.Distributed.##188#190, ::Array{Any,1}, ::Vararg{Array{Any,1},N} where N) at ./asyncmap.jl:103
[6] (::Base.#kw##async_usemap)(::Array{Any,1}, ::Base.#async_usemap, ::Function, ::Array{Any,1}, ::Vararg{Array{Any,1},N} where N) at ./<missing>:0
[7] (::Base.#kw##asyncmap)(::Array{Any,1}, ::Base.#asyncmap, ::Function, ::Array{Any,1}) at ./<missing>:0
[8] #pmap#203(::Bool, ::Int64, ::Void, ::Array{Any,1}, ::Void, ::Function, ::WorkerPool, ::Function, ::Array{Any,1}) at ./distributed/pmap.jl:126
[9] pmap(::WorkerPool, ::Function, ::Array{Any,1}) at ./distributed/pmap.jl:101
[10] #pmap#213(::Array{Any,1}, ::Function, ::Function, ::Array{Any,1}) at ./distributed/pmap.jl:156
[11] pmap(::Function, ::Array{Any,1}) at ./distributed/pmap.jl:156
from cutest.jl.
Okay, so I can fix the issue with missing ELFUN.o etc. by using decode=false
. But then I seem to fall into the same problem as @timholy mentioned with :fortran_open_
.
UPDATE: The function data is stored in OUTSDIF.d
generated by sifdecoder
, which the Fortran libraries call. So we would need a way to tell the library to have separate OUTSDIF.d files for each problem.
OLD:
This means that the functionality with decode=false
does not work (as I expected it to):
julia> nlp = CUTEstModel("AKIVA")
Minimization problem AKIVA
nvar = 2, ncon = 0 (0 linear)
julia> finalize(nlp)
julia> nlp = CUTEstModel("BROWNDEN")
Minimization problem BROWNDEN
nvar = 4, ncon = 0 (0 linear)
julia> finalize(nlp)
julia> nlp = CUTEstModel("AKIVA";decode=false)
Minimization problem AKIVA
nvar = 4, ncon = 0 (0 linear)
As you can see, AKIVA should have nvar = 2
, however, it gets the values of BROWNDEN if decode=false
.
from cutest.jl.
Related Issues (20)
- ERROR: ArgumentError: NULL library handle HOT 15
- Issue with -lSystem HOT 3
- `jac_coord!` memory allocation HOT 2
- Try syntax `CUTEstModel("...") do nlp` to allow automatic closing of nlp
- Check eval counters against those from CUTEst
- Unit test fails for HS14
- Improve `lin_cons` computation
- Use `increment!` and `decrement!` functions HOT 3
- change license to MIT?
- Mislcassified problems HOT 4
- Remove allocations in CUTEst.jl
- Fix the documentation
- gfortran error HOT 10
- KeyError: key "MASTSIF" not found HOT 7
- How to specify the size of the test problem? HOT 2
- NLPModels computes gradient with elements out of order HOT 9
- jth_hess_coord! seems not implemented HOT 1
- CUTEst.jl and AutoDiff -- compute high-order derivatives HOT 10
- Function "NONCVXUN" HOT 5
- Make the package loadable in Windows even though it is not usable HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from cutest.jl.