You can not select more than 25 topics Topics must start with a chinese character,a letter or number, can include dashes ('-') and can be up to 35 characters long.

CppShapeInference.cs 29 kB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730
  1. // <auto-generated>
  2. // Generated by the protocol buffer compiler. DO NOT EDIT!
  3. // source: tensorflow/python/framework/cpp_shape_inference.proto
  4. // </auto-generated>
  5. #pragma warning disable 1591, 0612, 3021
  6. #region Designer generated code
  7. using pb = global::Google.Protobuf;
  8. using pbc = global::Google.Protobuf.Collections;
  9. using pbr = global::Google.Protobuf.Reflection;
  10. using scg = global::System.Collections.Generic;
  11. namespace Tensorflow {
  12. /// <summary>Holder for reflection information generated from tensorflow/python/framework/cpp_shape_inference.proto</summary>
  13. public static partial class CppShapeInferenceReflection {
  14. #region Descriptor
  15. /// <summary>File descriptor for tensorflow/python/framework/cpp_shape_inference.proto</summary>
  16. public static pbr::FileDescriptor Descriptor {
  17. get { return descriptor; }
  18. }
  19. private static pbr::FileDescriptor descriptor;
  20. static CppShapeInferenceReflection() {
  21. byte[] descriptorData = global::System.Convert.FromBase64String(
  22. string.Concat(
  23. "CjV0ZW5zb3JmbG93L3B5dGhvbi9mcmFtZXdvcmsvY3BwX3NoYXBlX2luZmVy",
  24. "ZW5jZS5wcm90bxIKdGVuc29yZmxvdxopdGVuc29yZmxvdy9jb3JlL2ZyYW1l",
  25. "d29yay9mdWxsX3R5cGUucHJvdG8aLHRlbnNvcmZsb3cvY29yZS9mcmFtZXdv",
  26. "cmsvdGVuc29yX3NoYXBlLnByb3RvGiV0ZW5zb3JmbG93L2NvcmUvZnJhbWV3",
  27. "b3JrL3R5cGVzLnByb3RvIpsDChdDcHBTaGFwZUluZmVyZW5jZVJlc3VsdBIr",
  28. "CgVzaGFwZRgBIAEoCzIcLnRlbnNvcmZsb3cuVGVuc29yU2hhcGVQcm90bxJD",
  29. "CgtoYW5kbGVfZGF0YRgEIAEoCzIuLnRlbnNvcmZsb3cuQ3BwU2hhcGVJbmZl",
  30. "cmVuY2VSZXN1bHQuSGFuZGxlRGF0YRqTAQoSSGFuZGxlU2hhcGVBbmRUeXBl",
  31. "EisKBXNoYXBlGAEgASgLMhwudGVuc29yZmxvdy5UZW5zb3JTaGFwZVByb3Rv",
  32. "EiMKBWR0eXBlGAIgASgOMhQudGVuc29yZmxvdy5EYXRhVHlwZRIlCgR0eXBl",
  33. "GAQgASgLMhcudGVuc29yZmxvdy5GdWxsVHlwZURlZkoECAMQBBpsCgpIYW5k",
  34. "bGVEYXRhEg4KBmlzX3NldBgBIAEoCBJOCg5zaGFwZV9hbmRfdHlwZRgCIAMo",
  35. "CzI2LnRlbnNvcmZsb3cuQ3BwU2hhcGVJbmZlcmVuY2VSZXN1bHQuSGFuZGxl",
  36. "U2hhcGVBbmRUeXBlSgQIAhADSgQIAxAEImUKHUNwcFNoYXBlSW5mZXJlbmNl",
  37. "SW5wdXRzTmVlZGVkEhwKFGlucHV0X3RlbnNvcnNfbmVlZGVkGAEgAygFEiYK",
  38. "HmlucHV0X3RlbnNvcnNfYXNfc2hhcGVzX25lZWRlZBgCIAMoBUJhWlxnaXRo",
  39. "dWIuY29tL3RlbnNvcmZsb3cvdGVuc29yZmxvdy90ZW5zb3JmbG93L2dvL3B5",
  40. "dGhvbi9mcmFtZXdvcmsvY3BwX3NoYXBlX2luZmVyZW5jZV9nb19wcm90b/gB",
  41. "AWIGcHJvdG8z"));
  42. descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData,
  43. new pbr::FileDescriptor[] { global::Tensorflow.FullTypeReflection.Descriptor, global::Tensorflow.TensorShapeReflection.Descriptor, global::Tensorflow.TypesReflection.Descriptor, },
  44. new pbr::GeneratedClrTypeInfo(null, null, new pbr::GeneratedClrTypeInfo[] {
  45. new pbr::GeneratedClrTypeInfo(typeof(global::Tensorflow.CppShapeInferenceResult), global::Tensorflow.CppShapeInferenceResult.Parser, new[]{ "Shape", "HandleData" }, null, null, null, new pbr::GeneratedClrTypeInfo[] { new pbr::GeneratedClrTypeInfo(typeof(global::Tensorflow.CppShapeInferenceResult.Types.HandleShapeAndType), global::Tensorflow.CppShapeInferenceResult.Types.HandleShapeAndType.Parser, new[]{ "Shape", "Dtype", "Type" }, null, null, null, null),
  46. new pbr::GeneratedClrTypeInfo(typeof(global::Tensorflow.CppShapeInferenceResult.Types.HandleData), global::Tensorflow.CppShapeInferenceResult.Types.HandleData.Parser, new[]{ "IsSet", "ShapeAndType" }, null, null, null, null)}),
  47. new pbr::GeneratedClrTypeInfo(typeof(global::Tensorflow.CppShapeInferenceInputsNeeded), global::Tensorflow.CppShapeInferenceInputsNeeded.Parser, new[]{ "InputTensorsNeeded", "InputTensorsAsShapesNeeded" }, null, null, null, null)
  48. }));
  49. }
  50. #endregion
  51. }
  52. #region Messages
  53. public sealed partial class CppShapeInferenceResult : pb::IMessage<CppShapeInferenceResult> {
  54. private static readonly pb::MessageParser<CppShapeInferenceResult> _parser = new pb::MessageParser<CppShapeInferenceResult>(() => new CppShapeInferenceResult());
  55. private pb::UnknownFieldSet _unknownFields;
  56. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  57. public static pb::MessageParser<CppShapeInferenceResult> Parser { get { return _parser; } }
  58. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  59. public static pbr::MessageDescriptor Descriptor {
  60. get { return global::Tensorflow.CppShapeInferenceReflection.Descriptor.MessageTypes[0]; }
  61. }
  62. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  63. pbr::MessageDescriptor pb::IMessage.Descriptor {
  64. get { return Descriptor; }
  65. }
  66. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  67. public CppShapeInferenceResult() {
  68. OnConstruction();
  69. }
  70. partial void OnConstruction();
  71. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  72. public CppShapeInferenceResult(CppShapeInferenceResult other) : this() {
  73. shape_ = other.shape_ != null ? other.shape_.Clone() : null;
  74. handleData_ = other.handleData_ != null ? other.handleData_.Clone() : null;
  75. _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields);
  76. }
  77. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  78. public CppShapeInferenceResult Clone() {
  79. return new CppShapeInferenceResult(this);
  80. }
  81. /// <summary>Field number for the "shape" field.</summary>
  82. public const int ShapeFieldNumber = 1;
  83. private global::Tensorflow.TensorShapeProto shape_;
  84. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  85. public global::Tensorflow.TensorShapeProto Shape {
  86. get { return shape_; }
  87. set {
  88. shape_ = value;
  89. }
  90. }
  91. /// <summary>Field number for the "handle_data" field.</summary>
  92. public const int HandleDataFieldNumber = 4;
  93. private global::Tensorflow.CppShapeInferenceResult.Types.HandleData handleData_;
  94. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  95. public global::Tensorflow.CppShapeInferenceResult.Types.HandleData HandleData {
  96. get { return handleData_; }
  97. set {
  98. handleData_ = value;
  99. }
  100. }
  101. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  102. public override bool Equals(object other) {
  103. return Equals(other as CppShapeInferenceResult);
  104. }
  105. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  106. public bool Equals(CppShapeInferenceResult other) {
  107. if (ReferenceEquals(other, null)) {
  108. return false;
  109. }
  110. if (ReferenceEquals(other, this)) {
  111. return true;
  112. }
  113. if (!object.Equals(Shape, other.Shape)) return false;
  114. if (!object.Equals(HandleData, other.HandleData)) return false;
  115. return Equals(_unknownFields, other._unknownFields);
  116. }
  117. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  118. public override int GetHashCode() {
  119. int hash = 1;
  120. if (shape_ != null) hash ^= Shape.GetHashCode();
  121. if (handleData_ != null) hash ^= HandleData.GetHashCode();
  122. if (_unknownFields != null) {
  123. hash ^= _unknownFields.GetHashCode();
  124. }
  125. return hash;
  126. }
  127. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  128. public override string ToString() {
  129. return pb::JsonFormatter.ToDiagnosticString(this);
  130. }
  131. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  132. public void WriteTo(pb::CodedOutputStream output) {
  133. if (shape_ != null) {
  134. output.WriteRawTag(10);
  135. output.WriteMessage(Shape);
  136. }
  137. if (handleData_ != null) {
  138. output.WriteRawTag(34);
  139. output.WriteMessage(HandleData);
  140. }
  141. if (_unknownFields != null) {
  142. _unknownFields.WriteTo(output);
  143. }
  144. }
  145. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  146. public int CalculateSize() {
  147. int size = 0;
  148. if (shape_ != null) {
  149. size += 1 + pb::CodedOutputStream.ComputeMessageSize(Shape);
  150. }
  151. if (handleData_ != null) {
  152. size += 1 + pb::CodedOutputStream.ComputeMessageSize(HandleData);
  153. }
  154. if (_unknownFields != null) {
  155. size += _unknownFields.CalculateSize();
  156. }
  157. return size;
  158. }
  159. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  160. public void MergeFrom(CppShapeInferenceResult other) {
  161. if (other == null) {
  162. return;
  163. }
  164. if (other.shape_ != null) {
  165. if (shape_ == null) {
  166. Shape = new global::Tensorflow.TensorShapeProto();
  167. }
  168. Shape.MergeFrom(other.Shape);
  169. }
  170. if (other.handleData_ != null) {
  171. if (handleData_ == null) {
  172. HandleData = new global::Tensorflow.CppShapeInferenceResult.Types.HandleData();
  173. }
  174. HandleData.MergeFrom(other.HandleData);
  175. }
  176. _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields);
  177. }
  178. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  179. public void MergeFrom(pb::CodedInputStream input) {
  180. uint tag;
  181. while ((tag = input.ReadTag()) != 0) {
  182. switch(tag) {
  183. default:
  184. _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input);
  185. break;
  186. case 10: {
  187. if (shape_ == null) {
  188. Shape = new global::Tensorflow.TensorShapeProto();
  189. }
  190. input.ReadMessage(Shape);
  191. break;
  192. }
  193. case 34: {
  194. if (handleData_ == null) {
  195. HandleData = new global::Tensorflow.CppShapeInferenceResult.Types.HandleData();
  196. }
  197. input.ReadMessage(HandleData);
  198. break;
  199. }
  200. }
  201. }
  202. }
  203. #region Nested types
  204. /// <summary>Container for nested types declared in the CppShapeInferenceResult message type.</summary>
  205. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  206. public static partial class Types {
  207. public sealed partial class HandleShapeAndType : pb::IMessage<HandleShapeAndType> {
  208. private static readonly pb::MessageParser<HandleShapeAndType> _parser = new pb::MessageParser<HandleShapeAndType>(() => new HandleShapeAndType());
  209. private pb::UnknownFieldSet _unknownFields;
  210. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  211. public static pb::MessageParser<HandleShapeAndType> Parser { get { return _parser; } }
  212. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  213. public static pbr::MessageDescriptor Descriptor {
  214. get { return global::Tensorflow.CppShapeInferenceResult.Descriptor.NestedTypes[0]; }
  215. }
  216. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  217. pbr::MessageDescriptor pb::IMessage.Descriptor {
  218. get { return Descriptor; }
  219. }
  220. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  221. public HandleShapeAndType() {
  222. OnConstruction();
  223. }
  224. partial void OnConstruction();
  225. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  226. public HandleShapeAndType(HandleShapeAndType other) : this() {
  227. shape_ = other.shape_ != null ? other.shape_.Clone() : null;
  228. dtype_ = other.dtype_;
  229. type_ = other.type_ != null ? other.type_.Clone() : null;
  230. _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields);
  231. }
  232. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  233. public HandleShapeAndType Clone() {
  234. return new HandleShapeAndType(this);
  235. }
  236. /// <summary>Field number for the "shape" field.</summary>
  237. public const int ShapeFieldNumber = 1;
  238. private global::Tensorflow.TensorShapeProto shape_;
  239. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  240. public global::Tensorflow.TensorShapeProto Shape {
  241. get { return shape_; }
  242. set {
  243. shape_ = value;
  244. }
  245. }
  246. /// <summary>Field number for the "dtype" field.</summary>
  247. public const int DtypeFieldNumber = 2;
  248. private global::Tensorflow.DataType dtype_ = global::Tensorflow.DataType.DtInvalid;
  249. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  250. public global::Tensorflow.DataType Dtype {
  251. get { return dtype_; }
  252. set {
  253. dtype_ = value;
  254. }
  255. }
  256. /// <summary>Field number for the "type" field.</summary>
  257. public const int TypeFieldNumber = 4;
  258. private global::Tensorflow.FullTypeDef type_;
  259. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  260. public global::Tensorflow.FullTypeDef Type {
  261. get { return type_; }
  262. set {
  263. type_ = value;
  264. }
  265. }
  266. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  267. public override bool Equals(object other) {
  268. return Equals(other as HandleShapeAndType);
  269. }
  270. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  271. public bool Equals(HandleShapeAndType other) {
  272. if (ReferenceEquals(other, null)) {
  273. return false;
  274. }
  275. if (ReferenceEquals(other, this)) {
  276. return true;
  277. }
  278. if (!object.Equals(Shape, other.Shape)) return false;
  279. if (Dtype != other.Dtype) return false;
  280. if (!object.Equals(Type, other.Type)) return false;
  281. return Equals(_unknownFields, other._unknownFields);
  282. }
  283. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  284. public override int GetHashCode() {
  285. int hash = 1;
  286. if (shape_ != null) hash ^= Shape.GetHashCode();
  287. if (Dtype != global::Tensorflow.DataType.DtInvalid) hash ^= Dtype.GetHashCode();
  288. if (type_ != null) hash ^= Type.GetHashCode();
  289. if (_unknownFields != null) {
  290. hash ^= _unknownFields.GetHashCode();
  291. }
  292. return hash;
  293. }
  294. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  295. public override string ToString() {
  296. return pb::JsonFormatter.ToDiagnosticString(this);
  297. }
  298. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  299. public void WriteTo(pb::CodedOutputStream output) {
  300. if (shape_ != null) {
  301. output.WriteRawTag(10);
  302. output.WriteMessage(Shape);
  303. }
  304. if (Dtype != global::Tensorflow.DataType.DtInvalid) {
  305. output.WriteRawTag(16);
  306. output.WriteEnum((int) Dtype);
  307. }
  308. if (type_ != null) {
  309. output.WriteRawTag(34);
  310. output.WriteMessage(Type);
  311. }
  312. if (_unknownFields != null) {
  313. _unknownFields.WriteTo(output);
  314. }
  315. }
  316. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  317. public int CalculateSize() {
  318. int size = 0;
  319. if (shape_ != null) {
  320. size += 1 + pb::CodedOutputStream.ComputeMessageSize(Shape);
  321. }
  322. if (Dtype != global::Tensorflow.DataType.DtInvalid) {
  323. size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Dtype);
  324. }
  325. if (type_ != null) {
  326. size += 1 + pb::CodedOutputStream.ComputeMessageSize(Type);
  327. }
  328. if (_unknownFields != null) {
  329. size += _unknownFields.CalculateSize();
  330. }
  331. return size;
  332. }
  333. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  334. public void MergeFrom(HandleShapeAndType other) {
  335. if (other == null) {
  336. return;
  337. }
  338. if (other.shape_ != null) {
  339. if (shape_ == null) {
  340. Shape = new global::Tensorflow.TensorShapeProto();
  341. }
  342. Shape.MergeFrom(other.Shape);
  343. }
  344. if (other.Dtype != global::Tensorflow.DataType.DtInvalid) {
  345. Dtype = other.Dtype;
  346. }
  347. if (other.type_ != null) {
  348. if (type_ == null) {
  349. Type = new global::Tensorflow.FullTypeDef();
  350. }
  351. Type.MergeFrom(other.Type);
  352. }
  353. _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields);
  354. }
  355. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  356. public void MergeFrom(pb::CodedInputStream input) {
  357. uint tag;
  358. while ((tag = input.ReadTag()) != 0) {
  359. switch(tag) {
  360. default:
  361. _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input);
  362. break;
  363. case 10: {
  364. if (shape_ == null) {
  365. Shape = new global::Tensorflow.TensorShapeProto();
  366. }
  367. input.ReadMessage(Shape);
  368. break;
  369. }
  370. case 16: {
  371. Dtype = (global::Tensorflow.DataType) input.ReadEnum();
  372. break;
  373. }
  374. case 34: {
  375. if (type_ == null) {
  376. Type = new global::Tensorflow.FullTypeDef();
  377. }
  378. input.ReadMessage(Type);
  379. break;
  380. }
  381. }
  382. }
  383. }
  384. }
  385. public sealed partial class HandleData : pb::IMessage<HandleData> {
  386. private static readonly pb::MessageParser<HandleData> _parser = new pb::MessageParser<HandleData>(() => new HandleData());
  387. private pb::UnknownFieldSet _unknownFields;
  388. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  389. public static pb::MessageParser<HandleData> Parser { get { return _parser; } }
  390. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  391. public static pbr::MessageDescriptor Descriptor {
  392. get { return global::Tensorflow.CppShapeInferenceResult.Descriptor.NestedTypes[1]; }
  393. }
  394. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  395. pbr::MessageDescriptor pb::IMessage.Descriptor {
  396. get { return Descriptor; }
  397. }
  398. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  399. public HandleData() {
  400. OnConstruction();
  401. }
  402. partial void OnConstruction();
  403. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  404. public HandleData(HandleData other) : this() {
  405. isSet_ = other.isSet_;
  406. shapeAndType_ = other.shapeAndType_.Clone();
  407. _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields);
  408. }
  409. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  410. public HandleData Clone() {
  411. return new HandleData(this);
  412. }
  413. /// <summary>Field number for the "is_set" field.</summary>
  414. public const int IsSetFieldNumber = 1;
  415. private bool isSet_;
  416. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  417. public bool IsSet {
  418. get { return isSet_; }
  419. set {
  420. isSet_ = value;
  421. }
  422. }
  423. /// <summary>Field number for the "shape_and_type" field.</summary>
  424. public const int ShapeAndTypeFieldNumber = 2;
  425. private static readonly pb::FieldCodec<global::Tensorflow.CppShapeInferenceResult.Types.HandleShapeAndType> _repeated_shapeAndType_codec
  426. = pb::FieldCodec.ForMessage(18, global::Tensorflow.CppShapeInferenceResult.Types.HandleShapeAndType.Parser);
  427. private readonly pbc::RepeatedField<global::Tensorflow.CppShapeInferenceResult.Types.HandleShapeAndType> shapeAndType_ = new pbc::RepeatedField<global::Tensorflow.CppShapeInferenceResult.Types.HandleShapeAndType>();
  428. /// <summary>
  429. /// Only valid if &lt;is_set>.
  430. /// </summary>
  431. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  432. public pbc::RepeatedField<global::Tensorflow.CppShapeInferenceResult.Types.HandleShapeAndType> ShapeAndType {
  433. get { return shapeAndType_; }
  434. }
  435. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  436. public override bool Equals(object other) {
  437. return Equals(other as HandleData);
  438. }
  439. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  440. public bool Equals(HandleData other) {
  441. if (ReferenceEquals(other, null)) {
  442. return false;
  443. }
  444. if (ReferenceEquals(other, this)) {
  445. return true;
  446. }
  447. if (IsSet != other.IsSet) return false;
  448. if(!shapeAndType_.Equals(other.shapeAndType_)) return false;
  449. return Equals(_unknownFields, other._unknownFields);
  450. }
  451. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  452. public override int GetHashCode() {
  453. int hash = 1;
  454. if (IsSet != false) hash ^= IsSet.GetHashCode();
  455. hash ^= shapeAndType_.GetHashCode();
  456. if (_unknownFields != null) {
  457. hash ^= _unknownFields.GetHashCode();
  458. }
  459. return hash;
  460. }
  461. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  462. public override string ToString() {
  463. return pb::JsonFormatter.ToDiagnosticString(this);
  464. }
  465. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  466. public void WriteTo(pb::CodedOutputStream output) {
  467. if (IsSet != false) {
  468. output.WriteRawTag(8);
  469. output.WriteBool(IsSet);
  470. }
  471. shapeAndType_.WriteTo(output, _repeated_shapeAndType_codec);
  472. if (_unknownFields != null) {
  473. _unknownFields.WriteTo(output);
  474. }
  475. }
  476. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  477. public int CalculateSize() {
  478. int size = 0;
  479. if (IsSet != false) {
  480. size += 1 + 1;
  481. }
  482. size += shapeAndType_.CalculateSize(_repeated_shapeAndType_codec);
  483. if (_unknownFields != null) {
  484. size += _unknownFields.CalculateSize();
  485. }
  486. return size;
  487. }
  488. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  489. public void MergeFrom(HandleData other) {
  490. if (other == null) {
  491. return;
  492. }
  493. if (other.IsSet != false) {
  494. IsSet = other.IsSet;
  495. }
  496. shapeAndType_.Add(other.shapeAndType_);
  497. _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields);
  498. }
  499. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  500. public void MergeFrom(pb::CodedInputStream input) {
  501. uint tag;
  502. while ((tag = input.ReadTag()) != 0) {
  503. switch(tag) {
  504. default:
  505. _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input);
  506. break;
  507. case 8: {
  508. IsSet = input.ReadBool();
  509. break;
  510. }
  511. case 18: {
  512. shapeAndType_.AddEntriesFrom(input, _repeated_shapeAndType_codec);
  513. break;
  514. }
  515. }
  516. }
  517. }
  518. }
  519. }
  520. #endregion
  521. }
  522. public sealed partial class CppShapeInferenceInputsNeeded : pb::IMessage<CppShapeInferenceInputsNeeded> {
  523. private static readonly pb::MessageParser<CppShapeInferenceInputsNeeded> _parser = new pb::MessageParser<CppShapeInferenceInputsNeeded>(() => new CppShapeInferenceInputsNeeded());
  524. private pb::UnknownFieldSet _unknownFields;
  525. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  526. public static pb::MessageParser<CppShapeInferenceInputsNeeded> Parser { get { return _parser; } }
  527. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  528. public static pbr::MessageDescriptor Descriptor {
  529. get { return global::Tensorflow.CppShapeInferenceReflection.Descriptor.MessageTypes[1]; }
  530. }
  531. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  532. pbr::MessageDescriptor pb::IMessage.Descriptor {
  533. get { return Descriptor; }
  534. }
  535. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  536. public CppShapeInferenceInputsNeeded() {
  537. OnConstruction();
  538. }
  539. partial void OnConstruction();
  540. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  541. public CppShapeInferenceInputsNeeded(CppShapeInferenceInputsNeeded other) : this() {
  542. inputTensorsNeeded_ = other.inputTensorsNeeded_.Clone();
  543. inputTensorsAsShapesNeeded_ = other.inputTensorsAsShapesNeeded_.Clone();
  544. _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields);
  545. }
  546. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  547. public CppShapeInferenceInputsNeeded Clone() {
  548. return new CppShapeInferenceInputsNeeded(this);
  549. }
  550. /// <summary>Field number for the "input_tensors_needed" field.</summary>
  551. public const int InputTensorsNeededFieldNumber = 1;
  552. private static readonly pb::FieldCodec<int> _repeated_inputTensorsNeeded_codec
  553. = pb::FieldCodec.ForInt32(10);
  554. private readonly pbc::RepeatedField<int> inputTensorsNeeded_ = new pbc::RepeatedField<int>();
  555. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  556. public pbc::RepeatedField<int> InputTensorsNeeded {
  557. get { return inputTensorsNeeded_; }
  558. }
  559. /// <summary>Field number for the "input_tensors_as_shapes_needed" field.</summary>
  560. public const int InputTensorsAsShapesNeededFieldNumber = 2;
  561. private static readonly pb::FieldCodec<int> _repeated_inputTensorsAsShapesNeeded_codec
  562. = pb::FieldCodec.ForInt32(18);
  563. private readonly pbc::RepeatedField<int> inputTensorsAsShapesNeeded_ = new pbc::RepeatedField<int>();
  564. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  565. public pbc::RepeatedField<int> InputTensorsAsShapesNeeded {
  566. get { return inputTensorsAsShapesNeeded_; }
  567. }
  568. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  569. public override bool Equals(object other) {
  570. return Equals(other as CppShapeInferenceInputsNeeded);
  571. }
  572. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  573. public bool Equals(CppShapeInferenceInputsNeeded other) {
  574. if (ReferenceEquals(other, null)) {
  575. return false;
  576. }
  577. if (ReferenceEquals(other, this)) {
  578. return true;
  579. }
  580. if(!inputTensorsNeeded_.Equals(other.inputTensorsNeeded_)) return false;
  581. if(!inputTensorsAsShapesNeeded_.Equals(other.inputTensorsAsShapesNeeded_)) return false;
  582. return Equals(_unknownFields, other._unknownFields);
  583. }
  584. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  585. public override int GetHashCode() {
  586. int hash = 1;
  587. hash ^= inputTensorsNeeded_.GetHashCode();
  588. hash ^= inputTensorsAsShapesNeeded_.GetHashCode();
  589. if (_unknownFields != null) {
  590. hash ^= _unknownFields.GetHashCode();
  591. }
  592. return hash;
  593. }
  594. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  595. public override string ToString() {
  596. return pb::JsonFormatter.ToDiagnosticString(this);
  597. }
  598. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  599. public void WriteTo(pb::CodedOutputStream output) {
  600. inputTensorsNeeded_.WriteTo(output, _repeated_inputTensorsNeeded_codec);
  601. inputTensorsAsShapesNeeded_.WriteTo(output, _repeated_inputTensorsAsShapesNeeded_codec);
  602. if (_unknownFields != null) {
  603. _unknownFields.WriteTo(output);
  604. }
  605. }
  606. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  607. public int CalculateSize() {
  608. int size = 0;
  609. size += inputTensorsNeeded_.CalculateSize(_repeated_inputTensorsNeeded_codec);
  610. size += inputTensorsAsShapesNeeded_.CalculateSize(_repeated_inputTensorsAsShapesNeeded_codec);
  611. if (_unknownFields != null) {
  612. size += _unknownFields.CalculateSize();
  613. }
  614. return size;
  615. }
  616. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  617. public void MergeFrom(CppShapeInferenceInputsNeeded other) {
  618. if (other == null) {
  619. return;
  620. }
  621. inputTensorsNeeded_.Add(other.inputTensorsNeeded_);
  622. inputTensorsAsShapesNeeded_.Add(other.inputTensorsAsShapesNeeded_);
  623. _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields);
  624. }
  625. [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
  626. public void MergeFrom(pb::CodedInputStream input) {
  627. uint tag;
  628. while ((tag = input.ReadTag()) != 0) {
  629. switch(tag) {
  630. default:
  631. _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input);
  632. break;
  633. case 10:
  634. case 8: {
  635. inputTensorsNeeded_.AddEntriesFrom(input, _repeated_inputTensorsNeeded_codec);
  636. break;
  637. }
  638. case 18:
  639. case 16: {
  640. inputTensorsAsShapesNeeded_.AddEntriesFrom(input, _repeated_inputTensorsAsShapesNeeded_codec);
  641. break;
  642. }
  643. }
  644. }
  645. }
  646. }
  647. #endregion
  648. }
  649. #endregion Designer generated code