Skip to content

Commit e385826

Browse files
committed
Added documentation
1 parent c711dd3 commit e385826

File tree

138 files changed

+28486
-3
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

138 files changed

+28486
-3
lines changed

.gitignore

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
*.pyc
22
*/__pycache__
33
*.egg-info
4-
docs/_build
54
dist/
65
venv/
76
.eggs/

dfbgn/exit_information.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -118,7 +118,9 @@ def __str__(self):
118118
output += "Needed %g objective evaluations\n" % (self.nf)
119119
if self.nruns > 1:
120120
output += "Did a total of %g runs\n" % self.nruns
121-
if np.size(self.jacobian) < 200:
121+
if self.jacobian is None:
122+
output += "No approximate Jacobian available\n"
123+
elif np.size(self.jacobian) < 200:
122124
output += "Approximate Jacobian = %s\n" % str(self.jacobian)
123125
else:
124126
output += "Not showing approximate Jacobian because it is too long; check self.jacobian\n"

docs/Makefile

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
# Minimal makefile for Sphinx documentation
2+
#
3+
4+
# You can set these variables from the command line, and also
5+
# from the environment for the first two.
6+
SPHINXOPTS ?=
7+
SPHINXBUILD ?= sphinx-build
8+
SOURCEDIR = .
9+
BUILDDIR = _build
10+
11+
# Put it first so that "make" without argument is like "make help".
12+
help:
13+
@$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
14+
15+
.PHONY: help Makefile
16+
17+
# Catch-all target: route all unknown targets to Sphinx using the new
18+
# "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS).
19+
%: Makefile
20+
@$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
16.7 KB
Binary file not shown.

docs/_build/doctrees/index.doctree

10.9 KB
Binary file not shown.

docs/_build/doctrees/install.doctree

14.7 KB
Binary file not shown.
41.5 KB
Binary file not shown.

docs/_build/html/.buildinfo

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
# Sphinx build info version 1
2+
# This file hashes the configuration used when building these files. When it is not found, a full rebuild will be done.
3+
config: e7e4519aca41910b746d8b9cb3eee0db
4+
tags: 645f666f9bcd5a90fca523b33c5a78b7

docs/_build/html/.nojekyll

Whitespace-only changes.
Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
.. DFBGN documentation master file, created by
2+
sphinx-quickstart on Fri Oct 23 17:28:35 2020.
3+
You can adapt this file completely to your liking, but it should at least
4+
contain the root `toctree` directive.
5+
6+
DFBGN: Derivative-Free Block Gauss-Newton Optimizer for Least-Squares Minimization
7+
==================================================================================
8+
9+
**Release:** |version|
10+
11+
**Date:** |today|
12+
13+
**Author:** `Lindon Roberts <lindon.roberts@anu.edu.au>`_
14+
15+
DFBGN is a package for finding local solutions to large-scale nonlinear least-squares minimization problems, without requiring any derivatives of the objective. DFBGN stands for Derivative-Free Block Gauss-Newton.
16+
17+
That is, DFBGN solves
18+
19+
.. math::
20+
21+
\min_{x\in\mathbb{R}^n} \quad f(x) := \sum_{i=1}^{m}r_{i}(x)^2
22+
23+
If you wish to solve small-scale least-squares problems, you may wish to try `DFO-LS <https://github.com/numericalalgorithmsgroup/dfols>`_. If you are interested in solving general optimization problems (without a least-squares structure), you may wish to try `Py-BOBYQA <https://github.com/numericalalgorithmsgroup/pybobyqa>`_.
24+
25+
DFBGN is released under the GNU General Public License. Please `contact NAG <http://www.nag.com/content/worldwide-contact-information>`_ for alternative licensing.
26+
27+
.. toctree::
28+
:maxdepth: 2
29+
:caption: Contents:
30+
31+
install
32+
userguide
33+
34+
Acknowledgements
35+
----------------
36+
This software was developed under the supervision of `Coralia Cartis <https://www.maths.ox.ac.uk/people/coralia.cartis>`_, and was supported by the EPSRC Centre For Doctoral Training in `Industrially Focused Mathematical Modelling <https://www.maths.ox.ac.uk/study-here/postgraduate-study/industrially-focused-mathematical-modelling-epsrc-cdt>`_ (EP/L015803/1) in collaboration with the `Numerical Algorithms Group <http://www.nag.com/>`_.
37+
Lines changed: 94 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,94 @@
1+
Installing DFBGN
2+
================
3+
4+
Requirements
5+
------------
6+
DFBGN requires the following software to be installed:
7+
8+
* Python 2.7 or Python 3 (http://www.python.org/)
9+
10+
Additionally, the following python packages should be installed (these will be installed automatically if using *pip*, see `Installation using pip`_):
11+
12+
* NumPy 1.11 or higher (http://www.numpy.org/)
13+
* SciPy 0.18 or higher (http://www.scipy.org/)
14+
* Pandas 0.17 or higher (http://pandas.pydata.org/)
15+
16+
Installation using pip
17+
----------------------
18+
For easy installation, use `pip <http://www.pip-installer.org/>`_ as root:
19+
20+
.. code-block:: bash
21+
22+
$ [sudo] pip install dfbgn
23+
24+
or alternatively *easy_install*:
25+
26+
.. code-block:: bash
27+
28+
$ [sudo] easy_install dfbgn
29+
30+
If you do not have root privileges or you want to install DFBGN for your private use, you can use:
31+
32+
.. code-block:: bash
33+
34+
$ pip install --user dfbgn
35+
36+
which will install DFBGN in your home directory.
37+
38+
Note that if an older install of DFBGN is present on your system you can use:
39+
40+
.. code-block:: bash
41+
42+
$ [sudo] pip install --upgrade dfbgn
43+
44+
to upgrade DFBGN to the latest version.
45+
46+
Manual installation
47+
-------------------
48+
Alternatively, you can download the source code from `Github <https://github.com/numericalalgorithmsgroup/dfbgn>`_ and unpack as follows:
49+
50+
.. code-block:: bash
51+
52+
$ git clone https://github.com/numericalalgorithmsgroup/dfbgn
53+
$ cd dfbgn
54+
55+
DFBGN is written in pure Python and requires no compilation. It can be installed using:
56+
57+
.. code-block:: bash
58+
59+
$ [sudo] pip install .
60+
61+
If you do not have root privileges or you want to install DFBGN for your private use, you can use:
62+
63+
.. code-block:: bash
64+
65+
$ pip install --user .
66+
67+
instead.
68+
69+
To upgrade DFBGN to the latest version, navigate to the top-level directory (i.e. the one containing :code:`setup.py`) and rerun the installation using :code:`pip`, as above:
70+
71+
.. code-block:: bash
72+
73+
$ git pull
74+
$ [sudo] pip install . # with admin privileges
75+
76+
Testing
77+
-------
78+
If you installed DFBGN manually, you can test your installation by running:
79+
80+
.. code-block:: bash
81+
82+
$ python setup.py test
83+
84+
Alternatively, the HTML documentation provides some simple examples of how to run DFBGN.
85+
86+
Uninstallation
87+
--------------
88+
If DFBGN was installed using *pip* you can uninstall as follows:
89+
90+
.. code-block:: bash
91+
92+
$ [sudo] pip uninstall dfbgn
93+
94+
If DFBGN was installed manually you have to remove the installed files by hand (located in your python site-packages directory).

0 commit comments

Comments
 (0)