Skip to content

Commit 69dcbae

Browse files
committed
[doc] Add performance comparison
1 parent bee8ee9 commit 69dcbae

File tree

3 files changed

+8
-0
lines changed

3 files changed

+8
-0
lines changed
269 KB
Loading

docs/essentials/introduction.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,10 @@ SciSharp's philosophy allows a large number of machine learning code written in
1212

1313
> No surprise, .NET version (left window) is faster than python version (right window) binding. 10K iterates for linear regression in TensorFlow SGD. (CPU)
1414
15+
![python vs csharp on speed and memory](../_media/csharp_vs_python_speed_memory.jpg)
16+
17+
> It is 2x faster and 1/4 memory occupation of training time in eager mode than python binding. (TensorFlow.NET 0.20-preview2)
18+
1519
In comparison to other projects, like for instance [TensorFlowSharp](https://www.nuget.org/packages/TensorFlowSharp/) which only provide Tensorflow's low-level C++ API and can only run models that were built using Python, Tensorflow.NET also implements Tensorflow's high level API where all the magic happens. This computation graph building layer is still under active development. Once it is completely implemented you can build new Machine Learning models in C# or F#.
1620

1721
| TensorFlow | tf native1.14 | tf native 1.15 | tf native 2.3 |

docs/zh-cn/essentials/introduction.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,10 @@
1212

1313
> 毫无悬念, .NET 版本 (左边那个) 完爆 python 版本 (右边那个). 👆 用 TensorFlow SGD 跑 1 万次循环的线性回归. (CPU)
1414
15+
![python vs csharp on speed and memory](../../_media/csharp_vs_python_speed_memory.jpg)
16+
17+
> TensorFlow.NET 有 2x 速度和 1/4 空间占用相比较 python 版. (TensorFlow.NET 0.20-preview2)
18+
1519
举个例子, [TensorFlowSharp](https://www.nuget.org/packages/TensorFlowSharp/) 需要在 python 层之上跑 C# 代码,不够高效。但是 [TF.NET](https://github.com/SciSharp/TensorFlow.NET) 就直接跟 Tensorflow 的 C++ API 打交道,够快!
1620

1721
| TensorFlow | tf native1.14 | tf native 1.15 | tf native 2.3 |

0 commit comments

Comments
 (0)