| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
1 parent 530fe1c commit 8bfe91c
2 files changed
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -11,6 +11,11 @@ public static unsafe Tensor add(Tensor a, Tensor b) | |||
| 11 | 11 | return gen_math_ops.add(a, b); | |
| 12 | 12 | } | |
| 13 | 13 | ||
| 14 | + public static unsafe Tensor sub(Tensor a, Tensor b) | ||
| 15 | + { | ||
| 16 | + return gen_math_ops.sub(a, b); | ||
| 17 | + } | ||
| 18 | + | ||
| 14 | 19 | public static unsafe Tensor multiply(Tensor x, Tensor y) | |
| 15 | 20 | { | |
| 16 | 21 | return gen_math_ops.mul(x, y); | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -9,17 +9,28 @@ public static class gen_math_ops | |||
| 9 | 9 | { | |
| 10 | 10 | public static OpDefLibrary _op_def_lib = new OpDefLibrary(); | |
| 11 | 11 | ||
| 12 | - public static Tensor add(Tensor a, Tensor b) | ||
| 12 | + public static Tensor add(Tensor x, Tensor y) | ||
| 13 | 13 | { | |
| 14 | 14 | var keywords = new Dictionary<string, object>(); | |
| 15 | - keywords.Add("x", a); | ||
| 16 | - keywords.Add("y", b); | ||
| 15 | + keywords.Add("x", x); | ||
| 16 | + keywords.Add("y", y); | ||
| 17 | 17 | ||
| 18 | 18 | var _op = _op_def_lib._apply_op_helper("Add", name: "add", keywords: keywords); | |
| 19 | 19 | ||
| 20 | 20 | return new Tensor(_op, 0, _op.OutputType(0)); | |
| 21 | 21 | } | |
| 22 | 22 | ||
| 23 | + public static Tensor sub(Tensor x, Tensor y) | ||
| 24 | + { | ||
| 25 | + var keywords = new Dictionary<string, object>(); | ||
| 26 | + keywords.Add("x", x); | ||
| 27 | + keywords.Add("y", y); | ||
| 28 | + | ||
| 29 | + var _op = _op_def_lib._apply_op_helper("Sub", name: "sub", keywords: keywords); | ||
| 30 | + | ||
| 31 | + return new Tensor(_op, 0, _op.OutputType(0)); | ||
| 32 | + } | ||
| 33 | + | ||
| 23 | 34 | public static Tensor mul(Tensor x, Tensor y) | |
| 24 | 35 | { | |
| 25 | 36 | var keywords = new Dictionary<string, object>(); | |
| Back | FazBrowse Home | New Git URL |
0 commit comments