{"id":15047998,"url":"https://github.com/kristersjakobsson/solnp","last_synced_at":"2025-04-10T01:11:46.477Z","repository":{"id":62583598,"uuid":"166631631","full_name":"KristerSJakobsson/solnp","owner":"KristerSJakobsson","description":"C++ implementation of the SQP algorithm SOLNP, utilizing Lagrangian Relaxation to handle both Inequality and Equality constraint functions. Good for solving constrained objective functions on convex surfaces.","archived":false,"fork":false,"pushed_at":"2024-09-03T21:32:03.000Z","size":15836,"stargazers_count":15,"open_issues_count":2,"forks_count":2,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-04-10T01:11:39.270Z","etag":null,"topics":["algorithm","cpp11","dlib","optimization-algorithms","python","python-wheels","solnp","solnp-algorithm","wheels"],"latest_commit_sha":null,"homepage":"https://solnp.readthedocs.io/en/latest/","language":"C++","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/KristerSJakobsson.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.md","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2019-01-20T06:42:41.000Z","updated_at":"2024-07-20T10:03:00.000Z","dependencies_parsed_at":"2025-02-16T06:32:45.477Z","dependency_job_id":"fe052c07-c65e-406c-bddc-6963e2f08d87","html_url":"https://github.com/KristerSJakobsson/solnp","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/KristerSJakobsson%2Fsolnp","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/KristerSJakobsson%2Fsolnp/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/KristerSJakobsson%2Fsolnp/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/KristerSJakobsson%2Fsolnp/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/KristerSJakobsson","download_url":"https://codeload.github.com/KristerSJakobsson/solnp/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248137888,"owners_count":21053775,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["algorithm","cpp11","dlib","optimization-algorithms","python","python-wheels","solnp","solnp-algorithm","wheels"],"created_at":"2024-09-24T21:06:43.972Z","updated_at":"2025-04-10T01:11:46.461Z","avatar_url":"https://github.com/KristerSJakobsson.png","language":"C++","funding_links":[],"categories":[],"sub_categories":[],"readme":"[![codecov](https://codecov.io/gh/KristerSJakobsson/solnp/branch/master/graph/badge.svg)](https://codecov.io/gh/KristerSJakobsson/solnp)\n[![Documentation Status](https://readthedocs.org/projects/solnp/badge/?version=latest)](https://solnp.readthedocs.io/en/latest/?badge=latest)\n\nSee full documentation on [http://solnp.readthedocs.io](https://solnp.readthedocs.io/en/latest/).\n\n# Python/C++ SOLNP\n\nThis is a C++ implementation of the SOLNP algorithm by Yinyu Ye (1989) with Python Wrappers.\nThe algorithm was originally implemented in Matlab, and have gained some fame through it's R implementation (RSOLNP).\nVarious implementations of the algorithm exists already, however, this version utilizes the power of DLIB and C++11.\n\nThis algorithm solves the general nonlinear optimization problem on the form:\n```\n    minimize f(x)\n      subject to\n       g(x) = 0\n   l_h \u003c= h(x) \u003c= u_h\n   l_x \u003c   x   \u003c u_X\n```\nwhere f(x), g(x) and h(x) are smooth functions.\n\n## Getting Started in Python\n\nSimply install the package:\n`pip install pysolnp`\n\u003cbr\u003e\nSee the `/python_examples` folder for examples.\n\n## Getting Started in C++\n\nThe files are header-only and only rely on dlib.\nImport `solnp.hpp` and call the solnp function.\n\u003cbr\u003e\nSee the `/test` folder for examples.\n\n### Prerequisites\n\nThe sources for all prerequisites are linked using github submodules.\nTo compile the tests, run the CMake script.\n\nPrerequisites for running the C++ SOLNP tests are:\n- dlib - A C++ mathematical library\n- catch2 (for tests) - A testing library\n\nAdditionally, when building the Python wheels you need:\n- pybind11 - Bindings for C++ to Python\n\n## Running the tests\n\nRun the tests in the `solnp_test` and export the results to xml by running below in the solnp root folder:\n```\n$ cmake .\n$ make solnp_tests\n$ ./solnp_tests -r junit \u003e solnp_tests_result.xml\n$ make utils_tests\n$ ./utils_tests -r junit \u003e utils_tests_result.xml\n```\n\n\n## CI and building Wheels\n\nThis project uses CI to automatically build wheels for a wide range of distributions.\nNotably currently only builds for CPython are available on PyPi, but one can also manually installing the package from source as explained above.\nApple Silicon (M1 etc) compiling is not currently available on Github Actions. \n\nGithub Actions:\n  - Windows with Visual Studio\n  - Mac OS with Clang\n  - `manylinux2014` Docker with GCC\n  - CodeCov\n\nReadTheDocs CI:\n  - Building and hosting the [docs](https://solnp.readthedocs.io/en/latest/)\n\n## Built With\n\nLibraries:\n* [dlib](http://dlib.net/) - C++ math library\n* [pybind11](https://github.com/pybind/pybind11) - Bindings for building Python Wheels with C++11\n* [manylinux](https://github.com/pypa/manylinux) - Docker images for building Linux wheels\n* [cibuildwheels](https://cibuildwheel.readthedocs.io/en/stable) - Library for building Python Wheels through CI\n\nTools:\n* [CMake](https://cmake.org/runningcmake/) - Build tools\n* [CLion](https://www.jetbrains.com/clion/) - IDE by JetBrains\n* [Github Actions](https://github.com/features/actions) - Building binary Wheels\n\n## Authors\n\n* **Krister S Jakobsson** - *Implementation* - krister.s.jakobsson@gmail.com\n\n## License\n\nThis project is licensed under the Boost License - see the [license](LICENSE.md) file for details\n\n## Acknowledgments\n\n* **Yinyu Ye** -  Publisher and mastermind behind the original SOLNP algorithm,\n[Original Sources](https://web.stanford.edu/~yyye/matlab/)\n* **Alexios Ghalanos and Stefan Theussl** - The people behind RSOLNP,\n[Github repository](https://github.com/cran/Rsolnp)\n* **Davis King** - The mastermind behind Dlib, check out his blog! [Blog](http://blog.dlib.net/) \n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkristersjakobsson%2Fsolnp","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fkristersjakobsson%2Fsolnp","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkristersjakobsson%2Fsolnp/lists"}