diff --git a/docs/contribute.md b/docs/contribute.md index f5c1add8d0..977b62f569 100644 --- a/docs/contribute.md +++ b/docs/contribute.md @@ -24,12 +24,6 @@ This guide is organized as follows: ## Setting up your development environment -### Prerequisite: minizinc (optional) - -If you plan to use wrapped [discrete-optimization](https://github.com/airbus/discrete-optimization) solvers based on [minizinc](https://www.minizinc.org/), -you need first to install minizinc binary (version greater than 2.8) and update the `PATH` environment variable -so that it can be found by Python. See [minizinc documentation](https://www.minizinc.org/doc-latest/en/installation.html) for more details. - ### Installing from source in developer mode > **Disclaimer**: The following process has only been tested on Linux/MacOS platforms. diff --git a/docs/install.md b/docs/install.md index 033f7e75e8..b7f705d8fb 100644 --- a/docs/install.md +++ b/docs/install.md @@ -2,66 +2,6 @@ ## Prerequisites -### Minizinc 2.8+ (Optional) - -If you plan to use the solver for scheduling domains `DOSolver` -that wraps [discrete-optimization](https://github.com/airbus/discrete-optimization) solvers, -keep in mind that some of them are based on [minizinc](https://www.minizinc.org/). -In that case, you may need to install minizinc binary (version greater than 2.8) and update the `PATH` environment variable -so that it can be found by Python. See [minizinc documentation](https://www.minizinc.org/doc-latest/en/installation.html) for more details. - -::: tip -You can easily install minizinc from the command line, which can be useful when on cloud. -In order to make life easier to cloud users, we reproduce below the necessary lines. Please be careful that this -is not an official documentation for minizinc and that the following lines can stop working without notice -as we do not test them automatically. -::: - -#### Linux command line -On a Linux distribution, you can use the bundled [minizinc AppImage](https://www.minizinc.org/doc-latest/en/installation.html#appimage). - -If [FUSE](https://en.wikipedia.org/wiki/Filesystem_in_Userspace) is available: -``` -mkdir minizinc_install -curl -o minizinc_install/minizinc -L https://github.com/MiniZinc/MiniZincIDE/releases/download/2.8.5/MiniZincIDE-2.8.5-x86_64.AppImage -chmod +x minizinc_install/minizinc -export PATH="$(pwd)/minizinc_install/":$PATH -minizinc --version -``` -Else, this is still possible by extracting the files: -``` -mkdir minizinc_install -cd minizinc_install -curl -o minizinc.AppImage -L https://github.com/MiniZinc/MiniZincIDE/releases/download/2.8.5/MiniZincIDE-2.8.5-x86_64.AppImage -chmod +x minizinc.AppImage -./minizinc.AppImage --appimage-extract -cd .. -export LD_LIBRARY_PATH="$(pwd)/minizinc_install/squashfs-root/usr/lib/":$LD_LIBRARY_PATH -export PATH="$(pwd)/minizinc_install/squashfs-root/usr/bin/":$PATH -minizinc --version -``` - -#### MacOs command line -``` -mkdir minizinc_install -curl -o minizinc.dmg -L https://github.com/MiniZinc/MiniZincIDE/releases/download/2.8.5/MiniZincIDE-2.8.5-bundled.dmg -hdiutil attach minizinc.dmg -cp -R /Volumes/MiniZinc*/MiniZincIDE.app minizinc_install/. -export PATH="$(pwd)/minizinc_install/MiniZincIDE.app/Contents/Resources":$PATH -minizinc --version -``` - -#### Windows command line -Works on Windows Server 2022 with bash shell: -``` -mkdir minizinc_install -curl -o minizinc_setup.exe -L https://github.com/MiniZinc/MiniZincIDE/releases/download/2.8.5/MiniZincIDE-2.8.5-bundled-setup-win64.exe -cmd //c "minizinc_setup.exe /verysilent /currentuser /norestart /suppressmsgboxes /sp" -export PATH="~/AppData/Local/Programs/MiniZinc":$PATH -minizinc --version -``` - - ### Python 3.9+ environment The use of a virtual environment for scikit-decide is recommended, and you will need to ensure that the environment use a Python version greater than 3.9. @@ -115,7 +55,7 @@ pip install -U scikit-decide ## Known issues -### pygrib +### Pygrib When installing [pygrib](https://jswhit.github.io/pygrib/index.html) on MacOS ARM (in dependencies of `scikit-decide[all]`), no wheel exists on PyPI and there is issues when pip tries to build it. @@ -129,3 +69,62 @@ If the issue persists, you can try to install the pygrib package available on co ```shell conda install -c conda-forge pygrib ``` + +### Minizinc + +If you plan to use the solver for scheduling domains `DOSolver` +that wraps [discrete-optimization](https://github.com/airbus/discrete-optimization) solvers, +keep in mind that some of them are based on [minizinc](https://www.minizinc.org/). +In that case, you may need to install minizinc binary (version greater than 2.8) and update the `PATH` environment variable +so that it can be found by Python. See [minizinc documentation](https://www.minizinc.org/doc-latest/en/installation.html) for more details. + +::: tip +You can easily install minizinc from the command line, which can be useful when on cloud. +In order to make life easier to cloud users, we reproduce below the necessary lines. Please be careful that this +is not an official documentation for minizinc and that the following lines can stop working without notice +as we do not test them automatically. +::: + +#### Linux command line +On a Linux distribution, you can use the bundled [minizinc AppImage](https://www.minizinc.org/doc-latest/en/installation.html#appimage). + +If [FUSE](https://en.wikipedia.org/wiki/Filesystem_in_Userspace) is available: +``` +mkdir minizinc_install +curl -o minizinc_install/minizinc -L https://github.com/MiniZinc/MiniZincIDE/releases/download/2.8.5/MiniZincIDE-2.8.5-x86_64.AppImage +chmod +x minizinc_install/minizinc +export PATH="$(pwd)/minizinc_install/":$PATH +minizinc --version +``` +Else, this is still possible by extracting the files: +``` +mkdir minizinc_install +cd minizinc_install +curl -o minizinc.AppImage -L https://github.com/MiniZinc/MiniZincIDE/releases/download/2.8.5/MiniZincIDE-2.8.5-x86_64.AppImage +chmod +x minizinc.AppImage +./minizinc.AppImage --appimage-extract +cd .. +export LD_LIBRARY_PATH="$(pwd)/minizinc_install/squashfs-root/usr/lib/":$LD_LIBRARY_PATH +export PATH="$(pwd)/minizinc_install/squashfs-root/usr/bin/":$PATH +minizinc --version +``` + +#### MacOs command line +``` +mkdir minizinc_install +curl -o minizinc.dmg -L https://github.com/MiniZinc/MiniZincIDE/releases/download/2.8.5/MiniZincIDE-2.8.5-bundled.dmg +hdiutil attach minizinc.dmg +cp -R /Volumes/MiniZinc*/MiniZincIDE.app minizinc_install/. +export PATH="$(pwd)/minizinc_install/MiniZincIDE.app/Contents/Resources":$PATH +minizinc --version +``` + +#### Windows command line +Works on Windows Server 2022 with bash shell: +``` +mkdir minizinc_install +curl -o minizinc_setup.exe -L https://github.com/MiniZinc/MiniZincIDE/releases/download/2.8.5/MiniZincIDE-2.8.5-bundled-setup-win64.exe +cmd //c "minizinc_setup.exe /verysilent /currentuser /norestart /suppressmsgboxes /sp" +export PATH="~/AppData/Local/Programs/MiniZinc":$PATH +minizinc --version +```