Skip to content
Discussion options

You must be logged in to vote

You can't generate a function with arbitrary size, but you can actually create dynamic size factors, for example if you wanted to call a generated function N times, there are examples of dynamic size factors in symforce_factor_test.cc. I don't think this is what you want though, since I'm assuming you want to e.g. sample the spline, and compute other symbolic functions of the sampled point, and whatnot.

One approach that might work for you is picking a maximum number of knots/coefficients, and setting any unused ones to zero? I'm not sure if what would cover what you need without knowing more about your setup. Otherwise the generated code is probably going to be specific to a fixed number…

Replies: 1 comment 9 replies

Comment options

You must be logged in to vote
9 replies
@aaron-skydio
Comment options

@umerikuh
Comment options

@aaron-skydio
Comment options

@umerikuh
Comment options

@aaron-skydio
Comment options

Answer selected by umerikuh
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants