Gurobi/fr: Difference between revisions

no edit summary
No edit summary
No edit summary
Line 28: Line 28:
  [gra800:~] gurobi_cl --help
  [gra800:~] gurobi_cl --help


<div class="mw-translate-fuzzy">
===Interpréteur interactif ===
# Create environment file in current directory setting the number of threads:
echo "Threads ${SLURM_CPUS_ON_NODE:-1}" > gurobi.env
[gra-login2:~] salloc --time=1:00:0 --cpus-per-task=8 --mem=1G --account=def-xyz
</div>
[gra800:~] module load gurobi
[gra800:~] echo "Record 1" > gurobi.env   see *
[gra800:~] gurobi.sh
gurobi> m = read('/cvmfs/restricted.computecanada.ca/easybuild/software/2017/Core/gurobi/8.1.1/examples/data/glass4.mps')
gurobi> m.Params.Threads = 8              see **
gurobi> m.Params.Method = 2
gurobi> m.Params.ResultFile = "glass4.sol"
gurobi> m.Params.LogFile = "glass4.log"
gurobi> m.optimize()
gurobi> m.write('glass4.lp')
gurobi> m.status                          see ***
gurobi> m.runtime                          see ****
gurobi> help()


rsnt_translations
56,437

edits