Giter Club home page Giter Club logo

l-bfgs-b-lua's Introduction

L-BFGS-B-Lua

I used the following to create the wrapper for Lua for L-BFGS-B algorithm.

L-BFGS-B, converted from Fortran to C with Matlab wrapper

This is a C version of the well-known L-BFGS-B code, version 3.0.

It was created with f2c, then hand-coded to remove dependences on the f2c library

There is a Matlab mex wrapper (mex files and .m files, with example). This was the main motivation for converting to C, since compiling C and Fortran from Matlab is a pain, especially since many standard users don't have a Fortran compiler (especially for Windows).

This is an update of my previous wrapper that was on the Mathworks file-exchange from 2012--2015. This code is completely re-done. I no longer post on the mathworks file-exchange since they have a restrictive license that, e.g., prevents one from using that code with a Matlab alternative such as Octave. This current code has not been tested under Octave but there is no reason why it should not be able to work without major modification.

More info on the algorithm is available at the L-BFGS-B wikipedia page. References for the algorithm:

  • R. H. Byrd, P. Lu and J. Nocedal. A Limited Memory Algorithm for Bound Constrained Optimization, (1995), SIAM Journal on Scientific and Statistical Computing , 16, 5, pp. 1190-1208.
  • C. Zhu, R. H. Byrd and J. Nocedal. L-BFGS-B: Algorithm 778: L-BFGS-B, FORTRAN routines for large scale bound constrained optimization (1997), ACM Transactions on Mathematical Software, Vol 23, Num. 4, pp. 550 - 560.
  • J.L. Morales and J. Nocedal. L-BFGS-B: Remark on Algorithm 778: L-BFGS-B, FORTRAN routines for large scale bound constrained optimization (2011), ACM Transactions on Mathematical Software, Vol 38, Num. 1.

There are wrappers for L-BFGS-B in other languages (most link to one of the 2.x versions, but some, like this R package, link to the current version 3.0).

Installation

To use in C, go to the src/ subdirectory and type make. This is unnecessary if you just want to use the Matlab wrapper. For an example of how to call the library from C, see the driver1.c file. The included Makefile includes a test of the installation using the problem defined in driver1.c.

To use in Matlab, you need to compile the mex files. You can either go to Matlab/ and type make from a shell (assumes you are using gcc, and using linux/Mac or Windows+cygwin), or from Matlab, go to the Matlab/ subdirectory and run compile_mex.m which will install the mex using whatever compiler you set up during mex -setup (should work for all linux/Mac/Windows). The Matlab install file also runs some basic test to verify the installation.

License

L-BFGS-B is released under the BSD 3-clause license, and I am releasing this software under the same license. See LICENSE for details

The L-BFGS-B website requests that you cite them. From their website: "Condition for Use: This software is freely available, but we expect that all publications describing work using this software , or all commercial products using it, quote at least one of the references given below. This software is released under the "New BSD License" (aka "Modified BSD License" or "3-clause license"). "

It would be nice to cite this website as well since it took a significant amount of work...

Authors

This Lua wrapper is written by Drew Wicke

This C version and Matlab wrapper are written by Stephen Becker, [email protected]

The L-BFGS-B algorithm was written in the 1990s (mainly 1994, some revisions 1996) by Ciyou Zhu (in collaboration with R.H. Byrd, P. Lu-Chen and J. Nocedal)

L-BFGS-B Version 3.0 is an algorithmic update from 2011, with coding changes by J. L. Morales.

l-bfgs-b-lua's People

Contributors

dwicke avatar stephenbeckr avatar

Stargazers

 avatar  avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.