ONE - On-device Neural Engine
Loading...
Searching...
No Matches
FormattedGraph.h
Go to the documentation of this file.
1/*
2 * Copyright (c) 2020 Samsung Electronics Co., Ltd. All Rights Reserved
3 *
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
7 *
8 * http://www.apache.org/licenses/LICENSE-2.0
9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 */
16
17#ifndef __LUCI_FORMATTED_GRAPH_H__
18#define __LUCI_FORMATTED_GRAPH_H__
19
21
22#include <memory>
23
24namespace luci
25{
26
28{
29public:
30 NodeSummaryBuilder(const locop::SymbolTable *tbl) : _tbl{tbl}
31 {
32 // DO NOTHING
33 }
34
35public:
36 bool build(const loco::Node *node, locop::NodeSummary &s) const final;
37
38private:
39 const locop::SymbolTable *_tbl;
40};
41
43{
44public:
46
47public:
48 std::unique_ptr<locop::NodeSummaryBuilder> create(const locop::SymbolTable *tlb) const final
49 {
50 return std::make_unique<NodeSummaryBuilder>(tlb);
51 }
52};
53
54} // namespace luci
55
56#endif // __LUCI_FORMATTED_GRAPH_H__
Logical unit of computation.
Definition Node.h:54
std::unique_ptr< locop::NodeSummaryBuilder > create(const locop::SymbolTable *tlb) const final
NodeSummaryBuilder(const locop::SymbolTable *tbl)
bool build(const loco::Node *node, locop::NodeSummary &s) const final
Build a summary from loco Node.
Symbol Table Interface.
Definition SymbolTable.h:33