New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
How to get CPLEX in Julia 0.6.4 #214
Comments
Please read: https://github.com/JuliaOpt/CPLEX.jl#note-for-windows Make sure you have an environment variable called julia> ENV["CPLEX_STUDIO_BINARIES"] = "path/to/cplex/installation"
julia> Pkg.build("CPLEX") |
@general6r, please see #168 and #215. Your code needs to be |
@odow Thank you. I read all the previous issues and those two that you suggested, yet for some reason I'm still getting the same error. Help please :( |
What is in the directory of that folder? |
@odow I guess you mean the path to cplex installation. This is the directory: |
Close Julia, then open a new julia REPL and show the output of Pkg.status("CPLEX")
using Libdl
@show ENV["CPLEX_STUDIO_BINARIES128"]
@show Libdl.dlopen_e("C:/Program Files/IBM/ILOG/CPLEX_Studio_Community128/cplex/bin/x64_win64/cplex1280") |
@odow I got another error for Libdl! :( |
Oops, don't worry about the Libdl error. Julia behaves differently on 0.6. I'm not sure what the problem is. Everything looks correct, but you can't open CPLEX correctly (the last line should not end in The only other thing I can think of is that you are using the community edition. Do you have a valid license? Can you actually run CPLEX? |
@odow Yes I downloaded the free version of CPLEX from the link in CPLEX.jl file. Thank you so much for taking time for me. Is there anything else that I can do to fix it? |
Some things you could try
No worries. |
@odow I downloaded it on Feb 6 and it is valid for 30 days. I installed Julia 1.1 as well and the funny thing is I can't even add packages. For example Pkg.add("JuMP") results in an error saying "Pkg not defined"!!! |
Many things changed between Julia 0.6 and Julia 1.0. You now need to import Pkg. julia> import Pkg
julia> Pkg.add("JuMP") You will probably run into many other issues. However, if you search https://discourse.julialang.org/, you should be able to find lots of questions that others had when upgrading. In addition, JuMP recently updated. See https://discourse.julialang.org/t/jump-v0-19-has-been-released/20878 |
@odow Thank you so much. I finally managed to fix the issue by reinstalling Julia and defining the environment variable. |
Great! |
Hello everyone. I need to get CPLEX in my Julia 0.6.4. I've already done everything that was mentioned in the previous issues. I have CPLEX optimizer installed on my computer but when I use "using CPLEX" I get this error:
Does anyone know how I can resolve this issue? I'm using windows 10, Julia 0.6.4, CPLEX 12.8.0 and Jupyter Notebook.
Thank you.
The text was updated successfully, but these errors were encountered: