Skip to content

Commit

Permalink
Installation docs update (#350)
Browse files Browse the repository at this point in the history
Co-authored-by: Marco Mangano <[email protected]>
Co-authored-by: Eirikur Jonsson <[email protected]>
  • Loading branch information
3 people authored Jun 30, 2023
1 parent fe2a819 commit 7e01f2c
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 1 deletion.
12 changes: 11 additions & 1 deletion doc/install.rst
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,16 @@ Conda packages are available on ``conda-forge`` and can be installed via
conda install -c conda-forge pyoptsparse

This would install pyOptSparse with the built-in optimizers, as well as IPOPT.
If you wish to use optimizers not packaged by ``conda``, e.g. SNOPT, then you must build the package from source.
If you wish to use optimizers not packaged by ``conda``, e.g. SNOPT, then you must either build the package from source or use the installation script below.
If you have the SNOPT precompiled library available, it is possible to dynamically link it to pyOptSparse following the instructions on the :ref:`SNOPT installation page<snopt_by_conda>`.

Using an installation script
----------------------------
You can build and install pyOptsparse using a `Python script <https://github.com/OpenMDAO/build_pyoptsparse/>`_ developed by the OpenMDAO team.
For usage, see the instruction on the README of the repo.

This script is particularly useful for installing :ref:`IPOPT<ipopt>` and its dependencies.
It can also support SNOPT installation if you have access to the SNOPT source code.

Building from source
--------------------
Expand All @@ -37,6 +46,7 @@ The only exception is ``numpy``, which is required as part of the build process
* In Linux, the python header files (``python-dev``) are also required.
* **We do not support operating systems other than Linux.**
For macOS users, the conda package may work out of the box if you do not need any non-default optimizers.
Also, the installation script by OpenMDAO likely works on macOS.
For Windows users, a conda package is on the way, if it's not already in the repos.
This comes with the same disclaimer as the macOS conda package.
Alternatively, follow the :ref:`conda build instructions<conda build instruction>` below as this will work on any platform.
Expand Down
2 changes: 2 additions & 0 deletions doc/optimizers/IPOPT.rst
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
.. _ipopt:

IPOPT
=====
IPOPT (Interior Point OPTimizer) is an open source interior point optimizer, designed for large-scale nonlinear optimization.
Expand Down
3 changes: 3 additions & 0 deletions doc/optimizers/SNOPT.rst
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,9 @@ We currently test v7.7.7 and v7.7.1.

Installation by conda
*********************

.. _snopt_by_conda:

When installing via conda, all pyoptsparse binaries are pre-compiled and installed as part of the package.
However, the `snopt` binding module cannot be included as part of the package due to license restrictions.

Expand Down

0 comments on commit 7e01f2c

Please sign in to comment.