17#ifndef __TEST_HELPER_H__
18#define __TEST_HELPER_H__
26#include <tensorflow/core/framework/graph.pb.h>
28#define STRING_CONTENT(content) #content
37 T *first_node =
nullptr;
39 uint32_t count = nodes->
size();
41 for (uint32_t i = 0; i < count; ++i)
43 first_node =
dynamic_cast<T *
>(nodes->
at(i));
44 if (first_node !=
nullptr)
65 void inputs(
const std::vector<std::string> &names);
73 std::unique_ptr<moco::SymbolTable> _tensor_names;
74 std::unique_ptr<loco::Graph> _graph;
76 std::vector<moco::TFNode *> _inputs;
77 const char *_output{
nullptr};
T * at(uint32_t n) const
Access N-th object.
uint32_t size(void) const
Return the number of objects.
Interface of convert TF NodeDef to loco::Node (e.g., Conv2DGraphBuilder)
void inputs(const std::vector< std::string > &names)
void inputs(const std::vector< std::string > &names, const loco::DataType dtype)
void run(tensorflow::NodeDef &node_def, moco::GraphBuilder &graph_builder)
void output(const char *name)
moco::TFNode * output(void)
DataType
"scalar" value type
T * find_first_node_bytype(loco::Graph *g)