\(\newcommand{\B}[1]{ {\bf #1} }\) \(\newcommand{\R}[1]{ {\rm #1} }\)
cpp_fun_json#
View page sourceJson Representation of AD Computational Graph#
Syntax#
json = f
.to_json ()f
.from_json ()f#
This is a d_fun object.
json#
is a Json representation of the computation graph corresponding to f ; see the CppAD documentation for json_ad_graph.
to_json#
In this case, the function object f is const and
the return value json has prototype
std::string jsonfrom_json#
In this case, json has prototype
const std::string& jsonand the function f so it corresponds to json .
Examples#
fun_to_json_xam.cpp, fun_from_json_xam.cpp.