{ "info": { "author": "Hannu Parviainen", "author_email": "hpparvi@gmail.com", "bugtrack_url": null, "classifiers": [ "Development Status :: 5 - Production/Stable", "Intended Audience :: Science/Research", "License :: OSI Approved :: GNU General Public License v2 (GPLv2)", "Topic :: Scientific/Engineering" ], "description": "PyDE\r\n====\r\n\r\nGlobal optimization using differential evolution in Python [Storn97]_.\r\n\r\n\r\nInstallation\r\n------------\r\n\r\n::\r\n\r\n git clone https://github.com/hpparvi/PyDE.git\r\n cd PyDE\r\n python setup.py install [--user]\r\n \r\nBasic usage\r\n-----------\r\n\r\nImport the class from the package\r\n\r\n::\r\n\r\n from pyde.de import DiffEvol\r\n \r\nCreate a DiffEvol instance\r\n\r\n::\r\n\r\n de = DiffEvol(minfun, bounds, npop)\r\n\r\nwhere ``minfun`` is the function to be optimized, ``bounds`` is an initialization array, \r\nand ``npop`` is the size of the parameter vector population.\r\n\r\nNow, you can run the optimizer ``ngen`` generations::\r\n\r\n res = de.optimize(ngen=100)\r\n \r\nor run the optimizer as a generator::\r\n\r\n for res in de(ngen=100):\r\n do something\r\n \r\nUsage with emcee\r\n----------------\r\n\r\nThe PyDE parameter vector population can be used to initialize the affine-invariant MCMC sampler \r\n`emcee `_ when a simple point estimate of the function minimum \r\n(or maximum) is not sufficient::\r\n\r\n de = DiffEvol(lnpost, bounds, npop, maximize=True)\r\n de.optimize(ngen)\r\n \r\n sampler = emcee.EnsembleSampler(npop, ndim, lnpost)\r\n sampler.run_mcmc(de.population, 1000)\r\n \r\nReferences\r\n----------\r\n.. [Storn97] Storn, R., Price, K., Journal of Global Optimization 11: 341--359, 1997\r\n\r\n \r\nAPI\r\n---\r\n\r\n*pyde.de.*\\ **DiffEvol** (``minfun``, ``bounds``, ``npop``, ``F=0.5``, ``C=0.5``,\r\n``seed=0``, ``maximize=False``)\r\n\r\n**Parameters**\r\n\r\n:``minfun``: Function to be minimized.\r\n:``bounds``: Parameter space bounds as ``[npar,2]`` array.\r\n:``npop``: Size of the parameter vector population.\r\n:``F``: Difference amplification factor. Values between 0.5-0.8 are good in most cases.\r\n:``C``: Cross-over probability. Use 0.9 to test for fast convergence, and smaller values (~0.1) for a more elaborate search.\r\n:``seed``: Random seed.\r\n:``maximize``: An *optional* switch telling whether we want maximize or minimize the function. Defaults to minimization.", "description_content_type": null, "docs_url": null, "download_url": "UNKNOWN", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/hpparvi/PyDE", "keywords": "", "license": "GPL2", "maintainer": "", "maintainer_email": "", "name": "PyDE", "package_url": "https://pypi.org/project/PyDE/", "platform": "UNKNOWN", "project_url": "https://pypi.org/project/PyDE/", "project_urls": { "Download": "UNKNOWN", "Homepage": "https://github.com/hpparvi/PyDE" }, "release_url": "https://pypi.org/project/PyDE/1.0.1/", "requires_dist": null, "requires_python": null, "summary": "Differential Evolution in Python", "version": "1.0.1" }, "last_serial": 932564, "releases": { "1.0.1": [ { "comment_text": "", "digests": { "md5": "753a2c51755406987a1ffd677eb4d29c", "sha256": "45a56ffa91fb3dcdf3df9cf26f9ec681e6e0401f1dcf137638b700b0822d7bfd" }, "downloads": -1, "filename": "PyDE-1.0.1.tar.gz", "has_sig": false, "md5_digest": "753a2c51755406987a1ffd677eb4d29c", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 2601, "upload_time": "2013-11-30T16:46:39", "url": "https://files.pythonhosted.org/packages/7f/e1/2d1467ad0dea7340fb4d3441e9b47c23f5860b2ceb57465239073e04ae19/PyDE-1.0.1.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "753a2c51755406987a1ffd677eb4d29c", "sha256": "45a56ffa91fb3dcdf3df9cf26f9ec681e6e0401f1dcf137638b700b0822d7bfd" }, "downloads": -1, "filename": "PyDE-1.0.1.tar.gz", "has_sig": false, "md5_digest": "753a2c51755406987a1ffd677eb4d29c", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 2601, "upload_time": "2013-11-30T16:46:39", "url": "https://files.pythonhosted.org/packages/7f/e1/2d1467ad0dea7340fb4d3441e9b47c23f5860b2ceb57465239073e04ae19/PyDE-1.0.1.tar.gz" } ] }