Giter VIP home page Giter VIP logo

Comments (1)

giaf avatar giaf commented on July 29, 2024

Hi there,

I don't have direct experience with that but in principle BLASFEO and HPIPM have been designed to be as much as possible self contained and with low requirements regarding the supported C version.

The first question would be: does the ARM Cortex M7 in these microcontrollers have a double precision floating point unit? I see that this is optional.
If this is the case, I would compile BLASFEO with the following options (from Makefile.rule, CMake should be similar but it is possible that some are still missing there):

  • TARGET: GENERIC
  • LA: REFERENCE (you can also try out HIGH_PERFORMANCE but this requires more available registers to perform well, and in some routines it internally uses malloc - even though likely not the routine you would employ in HPIPM).
  • MF: COLMAJ if you went for REFERENCE LA, PANELMAJ if you went for HIGH_PERFORMANCE LA
  • BLAS_API to LAPACKE_API: 0
  • EXTERNAL_BLAS_API: 0
  • OS: this affects the assembly language conventions (that is not used for the GENERIC TARGET that is pure C), and the choice of the compilation flags (that you may have to customize yourself)
  • USE_C99_MATH: here you can give a try, if 1 gives you problems you can try to turn this off at the cost of a little performance deficit in some special cases.
  • EXT_DEP: setting to 0 you avoid the compilation of functions with external dependencies for printing and memory allocation.
  • afterwards you will need to customize C compiler, CFLAGS and the like.

For HPIPM:

  • TARGET: GENERIC
  • USE_C99_MATH: same story as BLASFEO's one
  • OS: only affects compilation flags and the like as there is no assembly here
  • again afterwards you will need to customize C compiler, CFLAGS and the like.

If you don't have double precision floating point unit, then its software emulation is going to be very slow, while the single precision version of HPIPM is often cases not reliable as typically computations in interior point methods get quite ill conditioned close to the solution (clearly it also depends on the conditioning of the problem to be solved, difficult problems make it even harder).

As of now I don't recall other stuff.
It would be very appreciated if you can share your findings about what works and what doesn't.

from blasfeo.

Related Issues (20)

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.