britishgasra.blogg.se

Install cplex on linux
Install cplex on linux













Main(args) # running with predefined arguments Main() # running another instance without writing the solutionĪrgs = # defining arguments before Include("/CVRP/src/run.jl") # load CVRP demo To decrease recompilation time while creating/debugging the application, you can run the application in the interactive mode:ĭocker run -it -rm -v /ABSOLUTE_PATH_TO_VRPSOLVER_APP:/MyApp bapdockĭocker run -it -rm -v /ABSOLUTE_PATH_TO_CVRP_APP:/CVRP bapdockĪnd to run the application inside the Julia environment, type (one at a time)

#Install cplex on linux code

The reported solution time, counted only after the code is compiled, is not affected. When running from the local machine command line, Julia code will be compiled each time and thus building the model takes some time (like 30 seconds in a typical machine) even for small instances. All changes into /CVRP and subdirectories will be reflected at /ABSOLUTE_PATH_TO_CVRP_APP. Note that for the arguments after bapdock we need to consider the container filesystem ( /CVRP) to access the application and I/O arguments. Which solves the instance A-n37-k6.vrp using exactly 6 vehicles (-m and -M defines the minimum and maximum number of vehicles, respectively), an upper bound of 950 and writes the solution at /CVRP/sol/A-n37-k6.sol. The VRPSolver application folder is mounted as /MyApp in the Docker container filesystem.įor example, for the Capacitated Vehicle Routing Problem (CVRP) demo (available here), we can call:ĭocker run -rm -v /ABSOLUTE_PATH_TO_CVRP_APP:/CVRP bapdock /CVRP/src/run.jl /CVRP/data/A/A-n37-k6.vrp -m 6 -M 6 -u 950 -o /CVRP/sol/A-n37-k6.sol jl of the application, followed by the application arguments:ĭocker run -rm -v /ABSOLUTE_PATH_TO_VRPSOLVER_APP:/MyApp bapdock /MyApp/myapp.jl arg1 arg2. To run the application from your local machine command line, you must mount (-v) the user julia VRPSolver application folder under any name and the last arguments must be the main script. Running a Julia VRPSolver application through the docker Stop and remove the bapdock-init container: opt/ibm/ILOG/CPLEX_Studio1210/cplex/bin/x86-64_linux) and create a copy of libcplex12100.so with the name libcplex12x.soĬopy your cplex folder to inside the container:ĭocker cp /ABSOLUTE_PATH_TO_CPLEX_ROOT/cplex bapdock-cont:/cplexįor example, if your CPLEX 12.10 is installed at /opt/ibm/ILOG/CPLEX_Studio1210 this command should be:ĭocker cp /opt/ibm/ILOG/CPLEX_Studio1210/cplex bapdock-cont:/cplexĬommit the modified container as an image named bapdock

install cplex on linux

Run this command to get the container-ID:Įnter the subdirectory of your cplex installation which contains the shared libraries (e.g.

install cplex on linux install cplex on linux

First, follow the instructions to manage Docker as a non-root user (without sudo).ĭocker import -c "ENTRYPOINT " bapdock.img bapdock-initĭocker run -it -d -name bapdock-cont bapdock-init













Install cplex on linux