Skip to main content

PDFO: Powell's Derivative-Free Optimization solvers

Introduction | Python | MATLAB | Citing PDFO | Acknowledgments

Dedicated to the late Professor M. J. D. Powell FRS (1936–2015).

GitHub Workflow Status GitHub GitHub release (latest SemVer) PyPI - Downloads View PDFO: Powell's Derivative-Free Optimization solvers on File Exchange

Introduction

PDFO (Powell's Derivative-Free Optimization solvers) is a cross-platform package providing interfaces for using the late Professor M. J. D. Powell's derivative-free optimization solvers, including UOBYQA, NEWUOA, BOBYQA, LINCOA, and COBYLA. See the PDFO homepage and the PDFO paper for more information.

This package makes use of a modified version of Powell's Fortran code. See the folder original under fsrc for Powell's original code.

Python version of PDFO

Installation

To use the Python version of PDFO on Linux, Mac, or Windows, you need Python (version 3.7 or above).

It is highly recommended to install PDFO via PyPI.

Install pip in your system if you Python version does not include it. Then execute

python3 -m pip install pdfo

in a command shell (e.g., the terminal for Linux and macOS, or the Command Shell for Windows). If your Python 3 launcher is not python3, adapt the command accordingly (it may be python on Windows for example). If this command runs successfully, PDFO is installed. You may verify the installation by

python3 -m unittest pdfo.testpdfo

If you are an Anaconda user, PDFO is also available through the conda installer ( https://anaconda.org/conda-forge/pdfo ). However, it is not managed by us.

Alternative installation (using source distribution)

Alternatively, although deeply discouraged, PDFO can be installed from the source code. It requires you to install additional Python headers, a Fortran compiler (e.g., gfortran), and F2PY (provided by NumPy). Download and decompress the source code package, or clone it from GitHub or Gitee. You will obtain a folder containing pyproject.toml; in a command shell, change your directory to this folder; then install PDFO by executing

python3 -m pip install .

Usage

PDFO provides the following Python functions: pdfo, uobyqa, newuoa, bobyqa, lincoa, cobyla.

The pdfo function can automatically identify the type of your problem and call one of Powell's solvers. The other five functions call the solver indicated by their names. It is highly recommended using pdfo instead of uobyqa, newuoa, etc.

The pdfo function is designed to be compatible with the minimize function available in scipy.optimize. You can call pdfo in exactly the same way as calling minimize, without the derivative arguments (PDFO does not use derivatives).

For the detailed syntax of these functions, use the standard help command of Python. For example,

from pdfo import pdfo
help(pdfo)

will tell you how to use pdfo.

Uninstall

PDFO can be uninstalled by executing the following command in a command shell:

python3 -m pip uninstall pdfo

MATLAB version of PDFO

Prerequisites

PDFO supports MATLAB R2014a and later releases. To use PDFO, you need first set up the MEX of your MATLAB so that it can compile Fortran. The setup of MEX is a pure MATLAB usage problem and it has nothing to do with PDFO.

To see whether your MEX is ready, run the following code in MATLAB:

mex('-setup', '-v', 'fortran'); mex('-v', fullfile(matlabroot, 'extern', 'examples', 'refbook', 'timestwo.F'));

If this completes successfully, then your MEX is ready. Otherwise, it is not, and you may try the setup_mex package at

https://github.com/equipez/setup_mex

It will help you to set MEX up on Windows or macOS (the setup of MEX is trivial on Linux). In case setup_mex does not work, you need to consult a local MATLAB expert or the technical support of MathWorks about "how to set up MEX", which is not part of PDFO.

Installation

Download and decompress the source code package, or clone it from GitHub or Gitee. You will obtain a folder containing setup.m. Place this folder at the location where you want PDFO to be installed. In MATLAB, change the directory to this folder, and execute the following command:

setup

If this command runs successfully, PDFO is installed. You may execute the following command in MATLAB to verify the installation:

testpdfo

Usage

PDFO provides the following MATLAB functions: pdfo, uobyqa, newuoa, bobyqa, lincoa, cobyla.

The pdfo function can automatically identify the type of your problem and then call one of Powell's solvers. The other five functions call the solver indicated by their names. It is highly recommended using pdfo instead of uobyqa, newuoa, etc.

The pdfo function is designed to be compatible with the fmincon function available in the Optimization Toolbox of MATLAB. You can call pdfo in exactly the same way as calling fmincon. In addition, pdfo can be called in some flexible ways that are not supported by fmincon.

For detailed syntax of these functions, use the standard help command of MATLAB. For example,

help pdfo

will tell you how to use pdfo.

Uninstall

PDFO can be uninstalled using the setup.m script by executing the following command in MATLAB:

setup uninstall

Citing PDFO

@misc{Ragonneau_Zhang_2023,
    title        = {{PDFO}: a cross-platform package for {Powell}'s derivative-free optimization solvers},
    author       = {Ragonneau, T. M. and Zhang, Z.},
    howpublished = {arXiv:2302.13246},
    year         = 2023
}

In addition, Powell’s methods can be cited as follows.

  • M. J. D. Powell. A direct search optimization method that models the objective and constraint functions by linear interpolation. In S. Gomez and J. P. Hennart, editors, Advances in Optimization and Numerical Analysis, pages 51–67, Dordrecht, NL, 1994. Springer.

  • M. J. D. Powell. UOBYQA: unconstrained optimization by quadratic approximation. Math. Program., 92:555–582, 2002.

  • M. J. D. Powell. The NEWUOA software for unconstrained optimization without derivatives. In G. Di Pillo and M. Roma, editors, Large-Scale Nonlinear Optimization, volume 83 of Nonconvex Optimization and Its Applications, pages 255–297, Boston, MA, USA, 2006. Springer.

  • M. J. D. Powell. The BOBYQA algorithm for bound constrained optimization without derivatives. Technical Report DAMTP 2009/NA06, Department of Applied Mathematics and Theoretical Physics, University of Cambridge, Cambridge, UK, 2009.

Remark: LINCOA seeks the least value of a nonlinear function subject to linear inequality constraints without using derivatives of the objective function. Powell did not publish a paper to introduce the algorithm.

Acknowledgments

PDFO is dedicated to the memory of the late Professor Powell with gratitude for his inspiration and for the treasures he left to us.

We are grateful to Professor Ya-xiang Yuan for his everlasting encouragement and support.

The development of PDFO is a long-term project, which would not be sustainable without the continued funds from the Hong Kong Research Grants Council (ref. PolyU 253012/17P, PolyU 153054/20P, and PolyU 153066/21P), the Hong Kong Ph.D. Fellowship Scheme (ref. PF18-24698), and the Hong Kong Polytechnic University (PolyU), in particular the Department of Applied Mathematics (AMA).

Metadata

Release files for pdfo 1.3.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for pdfo 1.3.1
File Size Uploaded
pdfo-1.3.1.tar.gz 454.8 kB Details

Built distributions (wheels)

Table of built distributions (wheels) for pdfo 1.3.1
File
pdfo-1.3.1-cp311-cp311-win_amd64.whl CPython 3.11 CPython 3.11 Windows x86-64 Details
pdfo-1.3.1-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl CPython 3.11 CPython 3.11 Linux glibc 2.17+ x86-64 Details
pdfo-1.3.1-cp311-cp311-macosx_10_9_x86_64.whl CPython 3.11 CPython 3.11 macOS 10.9+ x86-64 Details
pdfo-1.3.1-cp310-cp310-win_amd64.whl CPython 3.10 CPython 3.10 Windows x86-64 Details
pdfo-1.3.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl CPython 3.10 CPython 3.10 Linux glibc 2.17+ x86-64 Details
pdfo-1.3.1-cp310-cp310-macosx_10_9_x86_64.whl CPython 3.10 CPython 3.10 macOS 10.9+ x86-64 Details
pdfo-1.3.1-cp39-cp39-win_amd64.whl CPython 3.9 CPython 3.9 Windows x86-64 Details
pdfo-1.3.1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl CPython 3.9 CPython 3.9 Linux glibc 2.17+ x86-64 Details
pdfo-1.3.1-cp39-cp39-macosx_10_9_x86_64.whl CPython 3.9 CPython 3.9 macOS 10.9+ x86-64 Details
pdfo-1.3.1-cp38-cp38-win_amd64.whl CPython 3.8 CPython 3.8 Windows x86-64 Details
pdfo-1.3.1-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl CPython 3.8 CPython 3.8 Linux glibc 2.17+ x86-64 Details
pdfo-1.3.1-cp38-cp38-macosx_10_9_x86_64.whl CPython 3.8 CPython 3.8 macOS 10.9+ x86-64 Details
pdfo-1.3.1-cp37-cp37m-win_amd64.whl CPython 3.7 CPython 3.7 pymalloc Windows x86-64 Details
pdfo-1.3.1-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl CPython 3.7 CPython 3.7 pymalloc Linux glibc 2.17+ x86-64 Details
pdfo-1.3.1-cp37-cp37m-manylinux_2_17_i686.manylinux2014_i686.whl CPython 3.7 CPython 3.7 pymalloc Linux glibc 2.17+ x86-32 Details
pdfo-1.3.1-cp37-cp37m-macosx_10_9_x86_64.whl CPython 3.7 CPython 3.7 pymalloc macOS 10.9+ x86-64 Details

Total release size: 30.5 MB

Release files / pdfo-1.3.1.tar.gz

Download URL pdfo-1.3.1.tar.gz
Size 454.8 kB
Tags Source
SHA-256 checksum
How to use checksums
443e0ea8580ef7f788f871148902ca306488109dae590a4218f5dfaee939f3db
BLAKE2b-256 checksum
How to use checksums
a55463b981150a492c362d3883ee441ae460af54f4b5bd46c4190cbe0a1fe05d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.1 CPython/3.11.3

Release files / pdfo-1.3.1-cp311-cp311-win_amd64.whl

Download URL pdfo-1.3.1-cp311-cp311-win_amd64.whl
Size 2.4 MB
Tags CPython 3.11 Windows x86-64
SHA-256 checksum
How to use checksums
ffb6dbe49a8aa02c632a464f66235d7fef239f3a884f15d64ae859fde3573426
BLAKE2b-256 checksum
How to use checksums
3078ae8180b46415d4f92b6f133f92caeb2702e118f0aad10ed15c0abe566e6c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.1 CPython/3.11.3

Release files / pdfo-1.3.1-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl

Download URL pdfo-1.3.1-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Size 1.5 MB
Tags CPython 3.11 Linux glibc 2.17+ x86-64
SHA-256 checksum
How to use checksums
d05b32fe0da20e6a2d75f898227131db0284c90adf25ee9fbf54236a275d579e
BLAKE2b-256 checksum
How to use checksums
0426e14cb548255b10a8bfb96561e6e2e28fe96e321b3c4f3cddb03e940703bd
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.1 CPython/3.11.3

Release files / pdfo-1.3.1-cp311-cp311-macosx_10_9_x86_64.whl

Download URL pdfo-1.3.1-cp311-cp311-macosx_10_9_x86_64.whl
Size 1.8 MB
Tags CPython 3.11 macOS 10.9+ x86-64
SHA-256 checksum
How to use checksums
92378075b6976af349e06ec66765630fdc6ef77180625303bfda17632bdd777d
BLAKE2b-256 checksum
How to use checksums
a71dd2bffadebe4f34e853c29c0661fe454ed75f307a9bdbc9c8a741fa80cb2a
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.1 CPython/3.11.3

Release files / pdfo-1.3.1-cp310-cp310-win_amd64.whl

Download URL pdfo-1.3.1-cp310-cp310-win_amd64.whl
Size 2.4 MB
Tags CPython 3.10 Windows x86-64
SHA-256 checksum
How to use checksums
d5e48db68702b18c40a92e729427ee8dca8abf35c5c3077cced71443d42d19fe
BLAKE2b-256 checksum
How to use checksums
cc01e284734f62e3bed38d7dea6694d737871f5938eae6042606167a3dbf6a7b
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.1 CPython/3.11.3

Release files / pdfo-1.3.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl

Download URL pdfo-1.3.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Size 1.5 MB
Tags CPython 3.10 Linux glibc 2.17+ x86-64
SHA-256 checksum
How to use checksums
7ce283e8b178ed4f5687ba8fbcec05041b58bb5b0cf0851800998ef8af8e7725
BLAKE2b-256 checksum
How to use checksums
7789b509b565575e802f7065b71fd76f2b210b909efd5582b622d667db148bee
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.1 CPython/3.11.3

Release files / pdfo-1.3.1-cp310-cp310-macosx_10_9_x86_64.whl

Download URL pdfo-1.3.1-cp310-cp310-macosx_10_9_x86_64.whl
Size 1.8 MB
Tags CPython 3.10 macOS 10.9+ x86-64
SHA-256 checksum
How to use checksums
60a367eefa31e2ffa3882da2d77cded8cf8dc6129896ee6312d512f0f57479c1
BLAKE2b-256 checksum
How to use checksums
8fb40b866d9b39e7e6dde9672956444e0b9ed8e219bfa7ed57c4875d9cc5965b
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.1 CPython/3.11.3

Release files / pdfo-1.3.1-cp39-cp39-win_amd64.whl

Download URL pdfo-1.3.1-cp39-cp39-win_amd64.whl
Size 2.4 MB
Tags CPython 3.9 Windows x86-64
SHA-256 checksum
How to use checksums
ed57c8081c393e01c5c041ba3ba3bf6a4286cd2cd4cd0f9374c317032ab8faa3
BLAKE2b-256 checksum
How to use checksums
5a9b043f9436d08e83807831217f5026c0838ada6043b0f023546d25da9c4d69
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.1 CPython/3.11.3

Release files / pdfo-1.3.1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl

Download URL pdfo-1.3.1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Size 1.5 MB
Tags CPython 3.9 Linux glibc 2.17+ x86-64
SHA-256 checksum
How to use checksums
cf215d56de8e980e4e6b059c5e550797b0a7af9effbe54104229649cc8414c93
BLAKE2b-256 checksum
How to use checksums
cc17fccaad6483d27a0a5c1d21c34e1b268403baf9a926a64b6622842d1b3ede
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.1 CPython/3.11.3

Release files / pdfo-1.3.1-cp39-cp39-macosx_10_9_x86_64.whl

Download URL pdfo-1.3.1-cp39-cp39-macosx_10_9_x86_64.whl
Size 1.8 MB
Tags CPython 3.9 macOS 10.9+ x86-64
SHA-256 checksum
How to use checksums
2325d235d85b54890676a23550e17b056f84a6210f7fb9b91a877e99d24f7f0b
BLAKE2b-256 checksum
How to use checksums
550067558067a125dc37abb39e2f68fa1f739c7ff2bca92cd9dde0be7e45c24d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.1 CPython/3.11.3

Release files / pdfo-1.3.1-cp38-cp38-win_amd64.whl

Download URL pdfo-1.3.1-cp38-cp38-win_amd64.whl
Size 2.4 MB
Tags CPython 3.8 Windows x86-64
SHA-256 checksum
How to use checksums
92d836057ff0924abce8c4e9ae80ce0dabfa36ef6dbec7169507c1deea67aaed
BLAKE2b-256 checksum
How to use checksums
7d4210c8b930d30c4dc9701841fc60f7a1be187ddc976e0bda3b7c2f67050a67
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.1 CPython/3.11.3

Release files / pdfo-1.3.1-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl

Download URL pdfo-1.3.1-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Size 1.5 MB
Tags CPython 3.8 Linux glibc 2.17+ x86-64
SHA-256 checksum
How to use checksums
de0acf038d467191dd41971848bc33ba5ee9bb9b0477e6c64f8af8c7835dcfa3
BLAKE2b-256 checksum
How to use checksums
92ff93d2985cf6c0e1eeb0f2c2c870b3f3f679b229d3ac513cc30379230f4ea4
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.1 CPython/3.11.3

Release files / pdfo-1.3.1-cp38-cp38-macosx_10_9_x86_64.whl

Download URL pdfo-1.3.1-cp38-cp38-macosx_10_9_x86_64.whl
Size 1.8 MB
Tags CPython 3.8 macOS 10.9+ x86-64
SHA-256 checksum
How to use checksums
0fdc0203cff30379b235c918e5570babd0f32fbc15eada11a95053a0a15d466b
BLAKE2b-256 checksum
How to use checksums
ccd6849bdcc4dbaf810e776c3ba2718a5b143bc370bd12c51a65333d56027277
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.1 CPython/3.11.3

Release files / pdfo-1.3.1-cp37-cp37m-win_amd64.whl

Download URL pdfo-1.3.1-cp37-cp37m-win_amd64.whl
Size 2.4 MB
Tags CPython 3.7 CPython 3.7 pymalloc Windows x86-64
SHA-256 checksum
How to use checksums
adc23f8cd4aaaff8b05cc53c4c7c960a2d8a309fb8c412a7e7c2651797dc465a
BLAKE2b-256 checksum
How to use checksums
3738fb79201d96d2cb7afa15f4c74934c538eb4606172a5385bb4214677db5c0
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.1 CPython/3.11.3

Release files / pdfo-1.3.1-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl

Download URL pdfo-1.3.1-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Size 1.5 MB
Tags CPython 3.7 CPython 3.7 pymalloc Linux glibc 2.17+ x86-64
SHA-256 checksum
How to use checksums
679e42b2faa832553e7f206f1a8c07e167d310c8aeda3e9d3e041d382aee3f32
BLAKE2b-256 checksum
How to use checksums
3b3761b389b0927dd97fe5067ebaaa8e06a801a9a28ff610a84a83b4f70fc7b3
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.1 CPython/3.11.3

Release files / pdfo-1.3.1-cp37-cp37m-manylinux_2_17_i686.manylinux2014_i686.whl

Download URL pdfo-1.3.1-cp37-cp37m-manylinux_2_17_i686.manylinux2014_i686.whl
Size 1.5 MB
Tags CPython 3.7 CPython 3.7 pymalloc Linux glibc 2.17+ x86-32
SHA-256 checksum
How to use checksums
404524ed2ba9313185a49826df8c07fd0bfd7036c0e72eb829021805d00459a8
BLAKE2b-256 checksum
How to use checksums
9536caf2483bb023bd354da6427d118d75b00e999835ea0462f01f6bcd14f34b
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.1 CPython/3.11.3

Release files / pdfo-1.3.1-cp37-cp37m-macosx_10_9_x86_64.whl

Download URL pdfo-1.3.1-cp37-cp37m-macosx_10_9_x86_64.whl
Size 1.8 MB
Tags CPython 3.7 CPython 3.7 pymalloc macOS 10.9+ x86-64
SHA-256 checksum
How to use checksums
92af161f08cc91cf523854f0bed96b7f9330baa120955b1aad8930c020006598
BLAKE2b-256 checksum
How to use checksums
f635e3f2146efc0e73a42d5714575ab1f05ddba718a9ae91907689b45f6455b7
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.1 CPython/3.11.3

Release history Release notifications | RSS feed

2.0.0

16 release files

This release

1.3.1 This release

17 release files

1.3

17 release files

1.2

41 release files

1.1

61 release files

1.0

47 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page