Skip to content

Conversation

@yebie
Copy link

@yebie yebie commented Dec 28, 2016

Add a paddle usage command to support collecting demo usage.

resolve #965

Add a `paddle usage` command to support collecting demo usage.
@yebie
Copy link
Author

yebie commented Dec 28, 2016

@reyoung 讨论后,没有完全的采用 #965 中设计的方案。区别在于:

  1. server端api没有增加,直接采用了原来的查version api,因为这个api可以存储数据,供后续统计使用;
  2. 没采用python,纯bash~
  3. 不会上传用户的log文件或config文件,现在仅在用户本地读取log文件,用于获得paddle train/predict的运行时长
  4. 百度公司内网环境的转发服务尚未建立,所以当前仅尝试直接发给官网。转发服务建立好之后再更新脚本配置。

除了原始的脚本 paddle/scripts/tools/usage_stat/feedback.sh 之外,另外:

  • 修改了paddle/scripts/CMakeLists.txt ,这样可以在make过程中拷贝该文件到输出目录;
  • 同时修改了 paddle/scripts/submit_local.sh.in ,可以采用 paddle usage的方式调用该脚本;
  • 在最简单的 demo/introduction/train.sh 中增加了调用示范,就一行~
python -m paddle.utils.make_model_diagram ${@:2}
;;
"usage")
$MYDIR/../opt/paddle/bin/paddle_feedback ${@:2}
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

是不是paddle_feedback 改名叫 paddle_usage,或者 paddle usage 这个命令改名叫 paddle feedback ?我自己感觉前者意思更明确一些?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

说得对,那我统一改成usage吧。这个是前后开发时间太长导致的命名不一致...

@@ -0,0 +1,172 @@
#!/bin/bash
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

feedback.sh ==> usage.sh ?

@yebie
Copy link
Author

yebie commented Dec 30, 2016

@wangkuiyi@reyoung 帮忙review一下,谢谢~

@reyoung reyoung merged commit 1dd972f into PaddlePaddle:develop Jan 12, 2017
wangxicoding pushed a commit to wangxicoding/Paddle that referenced this pull request Dec 9, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

3 participants