forked from lutzroeder/netron
-
Notifications
You must be signed in to change notification settings - Fork 0
/
uff.proto
127 lines (105 loc) · 2.31 KB
/
uff.proto
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
syntax = "proto3";
package uff;
message MetaGraph {
int64 version = 1;
int64 descriptor_core_version = 2;
repeated Descriptor descriptors = 3;
repeated Graph graphs = 4;
repeated ReferencedDataEntry referenced_data = 5;
repeated ExtraFieldsEntry extra_fields = 100;
message ReferencedDataEntry {
string key = 1;
Data value = 2;
}
message ExtraFieldsEntry {
string key = 1;
Data value = 2;
}
}
message Descriptor {
string id = 1;
int64 version = 2;
bool optional = 3;
}
message Graph {
string id = 1;
repeated Node nodes = 2;
repeated ExtraFieldsEntry extra_fields = 100;
message ExtraFieldsEntry {
string key = 1;
Data value = 2;
}
}
message Node {
string id = 1;
repeated string inputs = 2;
string operation = 3;
repeated FieldsEntry fields = 4;
repeated ExtraFieldsEntry extra_fields = 100;
message FieldsEntry {
string key = 1;
Data value = 2;
}
message ExtraFieldsEntry {
string key = 1;
Data value = 2;
}
}
message Data {
oneof type {
string s = 1;
ListString s_list = 2;
double d = 3;
ListDouble d_list = 4;
bool b = 5;
ListBool b_list = 6;
int64 i = 7;
ListInt64 i_list = 8;
bytes blob = 9;
string ref = 100;
DataType dtype = 101;
ListDataType dtype_list = 102;
DimensionOrders dim_orders = 103;
ListDimensionOrders dim_orders_list = 104;
}
}
enum DataType {
DT_INVALID = 0;
DT_INT8 = 0x10008;
DT_INT16 = 0x10010;
DT_INT32 = 0x10020;
DT_INT64 = 0x10040;
DT_FLOAT16 = 0x20010;
DT_FLOAT32 = 0x20020;
}
enum OrderEnum {
OE_ZERO = 0;
OE_SPECIAL = -1;
OE_INCREMENT = 0x7FFFFFFF;
OE_DECREMENT = -0x80000000;
}
message DimensionOrders {
repeated OrdersEntry orders = 1;
message OrdersEntry {
OrderEnum key = 1;
ListInt64 value = 2;
}
}
message ListString {
repeated string val = 1;
}
message ListDouble {
repeated double val = 1;
}
message ListBool {
repeated bool val = 1;
}
message ListInt64 {
repeated int64 val = 1;
}
message ListDataType {
repeated DataType val = 1;
}
message ListDimensionOrders {
repeated DimensionOrders val = 1;
}