MCPcopy Create free account
hub / github.com/TinyMPC/TinyMPC / tiny_codegen

Function tiny_codegen

src/tinympc/codegen.cpp:68–80  ·  view source on GitHub ↗

TODO: Make this fail if tiny_setup has not already been called

Source from the content-addressed store, hash-verified

66
67// TODO: Make this fail if tiny_setup has not already been called
68int tiny_codegen(TinySolver* solver, const char* output_dir, int verbose) {
69 if (!solver) {
70 std::cout << "Error in tiny_codegen: solver is nullptr" << std::endl;
71 return 1;
72 }
73 int status = 0;
74 status |= codegen_create_directories(output_dir, verbose);
75 status |= codegen_data_header(output_dir, verbose);
76 status |= codegen_data_source(solver, output_dir, verbose);
77 status |= codegen_example(output_dir, verbose);
78
79 return status;
80}
81
82int tiny_codegen_with_sensitivity(TinySolver* solver, const char* output_dir,
83 tinyMatrix* dK, tinyMatrix* dP,

Callers 3

mainFunction · 0.85
mainFunction · 0.85

Calls 4

codegen_data_headerFunction · 0.85
codegen_data_sourceFunction · 0.85
codegen_exampleFunction · 0.85

Tested by

no test coverage detected