aligator  0.10.0
A primal-dual augmented Lagrangian-type solver for nonlinear trajectory optimization.
Loading...
Searching...
No Matches
expose-fly-high.cpp
Go to the documentation of this file.
1
3#ifdef ALIGATOR_WITH_PINOCCHIO
5
10
11namespace aligator {
12namespace python {
13
16using context::Scalar;
20
21void exposeFlyHigh() {
22 using FlyHighResidual = FlyHighResidualTpl<Scalar>;
23 PolymorphicMultiBaseVisitor<UnaryFunction, StageFunction> unary_visitor;
24
25 bp::class_<FlyHighResidual, bp::bases<UnaryFunction>>(
26 "FlyHighResidual",
27 "A residual function :math:`r(x) = v_{j,xy} e^{-s z_j}` where :math:`j` "
28 "is a given frame index.",
29 bp::no_init)
30 .def(bp::init<const int, const PinModel &, pinocchio::FrameIndex, Scalar,
31 std::size_t>(
32 ("self"_a, "ndx", "model", "frame_id", "slope", "nu")))
33 .def(FrameAPIVisitor<FlyHighResidual>())
34 .def(unary_visitor)
35 .def_readwrite("slope", &FlyHighResidual::slope_,
36 "The slope parameter of the function.");
37
38 bp::class_<FlyHighResidual::Data, bp::bases<StageFunctionData>>(
39 "FlyHighResidualData", bp::no_init)
40 .def_readonly("ez", &FlyHighResidual::Data::ez)
41 .def_readonly("pin_data", &FlyHighResidual::Data::pdata_);
42}
43
44} // namespace python
45} // namespace aligator
46
47#endif
pinocchio::ModelTpl< Scalar, Options > PinModel
Definition context.hpp:9
StageFunctionTpl< Scalar > StageFunction
Definition context.hpp:16
proxsuite::nlp::MultibodyPhaseSpace< Scalar > MultibodyPhaseSpace
Definition context.hpp:16
UnaryFunctionTpl< Scalar > UnaryFunction
Definition context.hpp:17
StageFunctionDataTpl< Scalar > StageFunctionData
Definition context.hpp:18
const PolymorphicMultiBaseVisitor< UnaryFunction, StageFunction > unary_visitor
Main package namespace.