30 using LocalMap = std::unordered_map<std::string, LocalType>;
33 using NonLocalMap = std::unordered_map<std::string, NonLocalType>;
46 template <
typename T,
int Adjust = 0,
typename... Args>
48 return py::class_<T>(std::forward<Args>(
args)...)
50 .def(
"get", [](
T &
i) {
return i.i + Adjust; });
59 const std::string &
name() {
return name_; }
py::class_< T > bind_local(Args &&...args)
PYBIND11_MAKE_OPAQUE(LocalVec)
std::unordered_map< std::string, uint8_t > NonLocalMap2
std::vector< LocalType > LocalVec
std::vector< NonLocal2 > LocalVec2
std::unordered_map< std::string, LocalType > LocalMap
std::vector< NonLocal2 > NonLocalVec2
Eigen::Triplet< double > T
std::vector< NonLocalType > NonLocalVec
Annotation for function names.
Simple class used to test py::local:
std::unordered_map< std::string, NonLocalType > NonLocalMap
const std::string & name()