Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add diagonal & isotropic sqrt_infos in geo factors #294

Open
wants to merge 2 commits into
base: bradley.solliday/revup/main/geo_factors_use_skip_directory_nesting
Choose a base branch
from

Commits on Feb 1, 2023

  1. Add diagonal & isotropic sqrt_infos in geo factors

    Often times the square root information matrix is a diagonal or
    isotropic matrix. However, in our generated geo factors we always assume
    they are full dense matrices leading to many more operations than
    needed.
    
    This commit modifies `geo_factors_codegen.py` to create 3 variants for
    each geo factor, one which assumes `sqrt_info` is a square matrix (the
    existing behavior), one which assumes it is a diagonal matrix, and one
    which assumes it is an isotropic matrix.
    
    These variants will have the same base name, with nothing appended to
    the square variant, `Diagonal` appended to the diaognal variant, and
    `Isotropic` appended to the isotropic covariant. They cannot have the
    same name, as even though we only generate the factors in C++ which has
    function overloading, disambiguating the overloads is a pain when
    constructing `sym::Factor`s. The square version takes a square
    eigen matrix, the diagonal version a eigen vector whose entries are
    those of the diagonal of `sqrt_info`, and a single scalar for the
    isotropic version.
    
    The header that the user imports remains the same, except now rather
    than containing the implementation directly, it re-imports the headers
    for the 3 different versions (which are stored in sub-directories).
    
    Topic: sqrt_info_variants
    Relative: geo_factors_use_skip_directory_nesting
    bradley-solliday-skydio committed Feb 1, 2023
    Configuration menu
    Copy the full SHA
    b14e4ef View commit details
    Browse the repository at this point in the history
  2. Regenerate geo factors with sqrt_info variants

    Topic: sqrt_info_variants
    bradley-solliday-skydio committed Feb 1, 2023
    Configuration menu
    Copy the full SHA
    8e775ee View commit details
    Browse the repository at this point in the history