Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
PaddlePaddle
VisualDL
提交
e4bade74
V
VisualDL
项目概览
PaddlePaddle
/
VisualDL
大约 1 年 前同步成功
通知
88
Star
4655
Fork
642
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
10
列表
看板
标记
里程碑
合并请求
2
Wiki
5
Wiki
分析
仓库
DevOps
项目成员
Pages
V
VisualDL
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
10
Issue
10
列表
看板
标记
里程碑
合并请求
2
合并请求
2
Pages
分析
分析
仓库分析
DevOps
Wiki
5
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
未验证
提交
e4bade74
编写于
1月 16, 2018
作者:
D
daminglu
提交者:
GitHub
1月 16, 2018
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
GitHub homepage readme (#163)
上级
888f56de
变更
3
隐藏空白更改
内联
并排
Showing
3 changed file
with
149 addition
and
129 deletion
+149
-129
README.cn.md
README.cn.md
+14
-4
README.md
README.md
+135
-1
docs/introduction_en.md
docs/introduction_en.md
+0
-124
未找到文件。
docs/introduction_
cn.md
→
README.
cn.md
浏览文件 @
e4bade74
<p
align=
"center"
>
<img
src=
"https://github.com/daming-lu/large_files/blob/master/visualdl-readme.png"
width=
"60%"
/>
</p>
# VisualDL (Visualize the Deep Learning)
## 介绍
...
...
@@ -21,21 +25,21 @@ VisualDL 目前支持4种组件:
兼容 ONNX(Open Neural Network Exchange)[https://github.com/onnx/onnx], 通过与 python SDK的结合,VisualDL可以兼容包括 PaddlePaddle, pytorch, mxnet在内的大部分主流DNN平台。
<p
align=
"center"
>
<img
src=
"
../demo/mxnet/mxnet_graph.gif"
width=
"600
"
/>
<img
src=
"
https://github.com/daming-lu/large_files/blob/master/graph_demo.gif"
width=
"60%
"
/>
</p>
### scalar
可以用于展示训练测试的误差趋势
<p
align=
"center"
>
<img
src=
"
./images/scalar_demo.png"
width=
"600
"
/>
<img
src=
"
https://github.com/daming-lu/large_files/blob/master/loss_scalar.gif"
width=
"60%
"
/>
</p>
### image
可以用于可视化任何tensor,或模型生成的图片
<p
align=
"center"
>
<img
src=
"
./images/image_demo.png"
width=
"600
"
/>
<img
src=
"
https://github.com/daming-lu/large_files/blob/master/loss_image.gif"
width=
"60%
"
/>
</p>
### histogram
...
...
@@ -43,7 +47,7 @@ VisualDL 目前支持4种组件:
用于可视化任何tensor中元素分布的变化趋势
<p
align=
"center"
>
<img
src=
"
./images/histogram_demo.png"
width=
"600
"
/>
<img
src=
"
https://github.com/daming-lu/large_files/blob/master/histogram.gif"
width=
"60%
"
/>
</p>
## SDK
...
...
@@ -110,3 +114,9 @@ board 还支持一下参数来实现远程的访问:
-
`--host`
设定IP
-
`--port`
设定端口
-
`--model_pb`
指定 ONNX 格式的模型文件
### 贡献
VisualDL 是由
[
PaddlePaddle
](
http://www.paddlepaddle.org/
)
和
[
ECharts
](
http://echarts.baidu.com/
)
合作推出的开源项目。我们欢迎所有人使用,提意见以及贡献代码。
README.md
浏览文件 @
e4bade74
# VisualDL
<p
align=
"center"
>
<img
src=
"https://github.com/daming-lu/large_files/blob/master/visualdl-readme.png"
width=
"60%"
/>
</p>
# VisualDL (Visualize the Deep Learning)
## Introduction
VisualDL is a deep learning visualization tool that can help design deep learning jobs.
It includes features such as scalar, parameter distribution, model structure and image visualization.
Currently it is being developed at a high pace.
New features will be continuously added.
At present, most DNN frameworks use Python as their primary language. VisualDL supports Python by nature.
Users can get plentiful visualization results by simply add a few lines of Python code into their model before training.
Besides Python SDK, VisualDL was writen in C++ on the low level. It also provides C++ SDK that
can be integrated into other platforms.
## Component
VisualDL now provides 4 components:
-
graph
-
scalar
-
image
-
histogram
### Graph
Graph is compatible with ONNX(Open Neural Network Exchange)[https://github.com/onnx/onnx],
Cooperated with Python SDK, VisualDL can be compatible with most major DNN frameworks, including
PaddlePaddle, PyTorch and MXNet.
<p
align=
"center"
>
<img
src=
"https://github.com/daming-lu/large_files/blob/master/graph_demo.gif"
width=
"60%"
/>
</p>
### Scalar
Scalar can be used to show the trends of error during training.
<p
align=
"center"
>
<img
src=
"https://github.com/daming-lu/large_files/blob/master/loss_scalar.gif"
width=
"60%"
/>
</p>
### Image
Image can be used to visualize any tensor or intermediate generated image.
<p
align=
"center"
>
<img
src=
"https://github.com/daming-lu/large_files/blob/master/loss_image.gif"
width=
"60%"
/>
</p>
### Histogram
Histogram can be used to visualize parameter distribution and trends for any tensor.
<p
align=
"center"
>
<img
src=
"https://github.com/daming-lu/large_files/blob/master/histogram.gif"
width=
"60%"
/>
</p>
## SDK
VisualDL provides both Python SDK and C++ SDK in order to fit more use cases.
### Python SDK
Below is an example of creating a simple Scalar component and inserting data from different timestamps:
```
python
import
random
from
visualdl
import
LogWriter
logdir
=
"./tmp"
logger
=
LogWriter
(
dir
,
sync_cycle
=
10
)
# mark the components with 'train' label.
with
logger
.
mode
(
"train"
):
# create a scalar component called 'scalars/scalar0'
scalar0
=
logger
.
scalar
(
"scalars/scalar0"
)
# add some records during DL model running, lets start from another block.
with
logger
.
mode
(
"train"
):
# add scalars
for
step
in
range
(
100
):
scalar0
.
add_record
(
step
,
random
.
random
())
```
### C++ SDK
Here is the C++ SDK identical to the Python SDK example above:
```
c++
#include <cstdlib>
#include <string>
#include "visualdl/sdk.h"
namespace
vs
=
visualdl
;
namepsace
cp
=
visualdl
::
components
;
int
main
()
{
const
std
::
string
dir
=
"./tmp"
;
vs
::
LogWriter
logger
(
dir
,
10
);
logger
.
SetMode
(
"train"
);
auto
tablet
=
logger
.
NewTablet
(
"scalars/scalar0"
);
cp
::
Scalar
<
float
>
scalar0
(
tablet
);
for
(
int
step
=
0
;
step
<
1000
;
step
++
)
{
float
v
=
(
float
)
std
::
rand
()
/
RAND_MAX
;
scalar0
.
AddRecord
(
step
,
v
);
}
return
0
;
}
```
## Launch Board
After some logs have been generated during training, users can launch board to see real-time data visualization.
```
visualDL --logdir <some log dir>
```
Board also supports the parameters below for remote access:
-
`--host`
set IP
-
`--port`
set port
-
`--model_pb`
specify ONNX format for model file
### How to install
...
...
@@ -13,3 +140,10 @@ vdl_scratch.py
visualDL --logdir=scratch_log
```
that will start a server locally.
### Contribute
VisualDL is initially created by
[
PaddlePaddle
](
http://www.paddlepaddle.org/
)
and
[
ECharts
](
http://echarts.baidu.com/
)
.
We welcome everyone to use, comment and contribute to Visual DL :)
docs/introduction_en.md
已删除
100644 → 0
浏览文件 @
888f56de
# VisualDL (Visualize the Deep Learning)
## Introduction
VisualDL is a deep learning visualization tool that can help design deep learning jobs.
It includes features such as scalar, parameter distribution, model structure and image visualization.
Currently it is being developed at a high pace.
New features will be continuously added.
At present, most DNN frameworks use Python as their primary language. VisualDL supports Python by nature.
Users can get plentiful visualization results by simply add a few lines of Python code into their model before training.
Besides Python SDK, VisualDL was writen in C++ on the low level. It also provides C++ SDK that
can be integrated into other platforms.
## Component
VisualDL now provides 4 components:
-
graph
-
scalar
-
image
-
histogram
### Graph
Graph is compatible with ONNX(Open Neural Network Exchange)[https://github.com/onnx/onnx],
Cooperated with Python SDK, VisualDL can be compatible with most major DNN frameworks, including
PaddlePaddle, PyTorch and MXNet.
<p
align=
"center"
>
<img
src=
"../demo/mxnet/mxnet_graph.gif"
width=
"600"
/>
</p>
### Scalar
Scalar can be used to show the trends of error during training.
<p
align=
"center"
>
<img
src=
"./images/scalar_demo.png"
width=
"600"
/>
</p>
### Image
Image can be used to visualize any tensor or intermediate generated image.
<p
align=
"center"
>
<img
src=
"./images/image_demo.png"
width=
"600"
/>
</p>
### Histogram
Histogram can be used to visualize parameter distribution and trends for any tensor.
<p
align=
"center"
>
<img
src=
"./images/histogram_demo.png"
width=
"600"
/>
</p>
## SDK
VisualDL provides both Python SDK and C++ SDK in order to fit more use cases.
### Python SDK
Below is an example of creating a simple Scalar component and inserting data from different timestamps:
```
python
import
random
from
visualdl
import
LogWriter
logdir
=
"./tmp"
logger
=
LogWriter
(
dir
,
sync_cycle
=
10
)
# mark the components with 'train' label.
with
logger
.
mode
(
"train"
):
# create a scalar component called 'scalars/scalar0'
scalar0
=
logger
.
scalar
(
"scalars/scalar0"
)
# add some records during DL model running, lets start from another block.
with
logger
.
mode
(
"train"
):
# add scalars
for
step
in
range
(
100
):
scalar0
.
add_record
(
step
,
random
.
random
())
```
### C++ SDK
Here is the C++ SDK identical to the Python SDK example above:
```
c++
#include <cstdlib>
#include <string>
#include "visualdl/sdk.h"
namespace
vs
=
visualdl
;
namepsace
cp
=
visualdl
::
components
;
int
main
()
{
const
std
::
string
dir
=
"./tmp"
;
vs
::
LogWriter
logger
(
dir
,
10
);
logger
.
SetMode
(
"train"
);
auto
tablet
=
logger
.
NewTablet
(
"scalars/scalar0"
);
cp
::
Scalar
<
float
>
scalar0
(
tablet
);
for
(
int
step
=
0
;
step
<
1000
;
step
++
)
{
float
v
=
(
float
)
std
::
rand
()
/
RAND_MAX
;
scalar0
.
AddRecord
(
step
,
v
);
}
return
0
;
}
```
## Launch Board
After some logs have been generated during training, users can launch board to see real-time data visualization.
```
visualDL --logdir <some log dir>
```
Board also supports the parameters below for remote access:
-
`--host`
set IP
-
`--port`
set port
-
`--model_pb`
specify ONNX format for model file
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录