Contribute and logging#5181
Conversation
CONTRIBUTING.md
Outdated
| When we run a PaddlePaddle application or test, we can specify a verbose threshold. For example: | ||
|
|
||
| ```bash | ||
| GLOG_v=3 python ../python/paddle/v2/framework/tests/test_recurrent_op.py |
There was a problem hiding this comment.
add a module example GLOG_vmodule=buddy_allocator=2 GLOG_v=10 python ../python/paddle/v2/framework/tests/test_recurrent_op.py. This will set the vlog level of buddy_allocator to be 2 and the rest to be 10
CONTRIBUTING.md
Outdated
| | 1 | reserved | | ||
| | 2 | DL model compilation, including the building of backward pass and adding optimizer, feed, init operators | | ||
| | 3 | DL model execution. For example, in operators | | ||
| | 4 | More detailed information than above. | |
There was a problem hiding this comment.
Maybe the simplest way to define the max level of the vlog is corresponding with our namespace.
framework should use VLOG(1) as its highest VLOG level. Since the framework is our core code. VLOG(2) and VLOG(3) could be used in framework for unimportant logs.
operators should use VLOG(3) as its highest VLOG level, since it is the middle level of our framework. operators will invoke platform, memories, eigen, etc.
platform, memory should use VLOG(5) as their highest VLOG level, since they are usually invoked at the end our code.
| namespace | max vlog level |
|---|---|
| framework | 1 |
| operators | 3 |
| memory/platform | 5 |
There was a problem hiding this comment.
- removes doc/.../contribute_to_paddle_cn.md.
cn ->en ?
- After this PR, should we update the contribute_to_paddle_cn.md?
- In contribute_to_paddle_cn, 提交代码的一些约定 is not in contribute_to_paddle_en.md now. Should this PR add these?
CONTRIBUTING.md
Outdated
|
|
||
| 1. Build and test | ||
|
|
||
| Users can build PaddlePaddle natively on Linux and Mac OS X. But to unify the building environment and to make it easy for debugging, the recommended way is [using Docker](https://github.com/PaddlePaddle/Paddle/blob/develop/doc/howto/dev/contribute_to_paddle_en.md). |
There was a problem hiding this comment.
Is the URL of using Docker correct?
There was a problem hiding this comment.
Corrected it to be (https://github.com/PaddlePaddle/Paddle/blob/develop/doc/howto/dev/build_en.md).
There was a problem hiding this comment.
It is not. Thanks for pointing out. I am correcting it.
| clang-formater.......................................(no files to check)Skipped | ||
| [my-cool-stuff c703c041] add test file | ||
| 1 file changed, 0 insertions(+), 0 deletions(-) | ||
| create mode 100644 233 |
There was a problem hiding this comment.
Can we remain the result of git commit? Maybe this result is useful for new developers since they can confirm their pre-commit run successfully.
| - Make sure the compiler option `WITH_STYLE_CHECK` is on and the compiler | ||
| passes the code style check. | ||
| - All code must have unit test. | ||
| - Pass all unit tests. |
There was a problem hiding this comment.
Can we remain these Code Requirements?
There was a problem hiding this comment.
Good idea. I moving it after the Workflow section, as the Code Standard section.
wangkuiyi
left a comment
There was a problem hiding this comment.
I removed the Chinese version of this document because I noticed that we haven't been able to keep the Chinese and English version consistent with each other.
In contribute_to_paddle_cn, 提交代码的一些约定 is not in contribute_to_paddle_en.md now. Should this PR add these?
Actually, I translated this part but scattered the information around various parts of the new English version.
| - Make sure the compiler option `WITH_STYLE_CHECK` is on and the compiler | ||
| passes the code style check. | ||
| - All code must have unit test. | ||
| - Pass all unit tests. |
There was a problem hiding this comment.
Good idea. I moving it after the Workflow section, as the Code Standard section.
CONTRIBUTING.md
Outdated
|
|
||
| 1. Build and test | ||
|
|
||
| Users can build PaddlePaddle natively on Linux and Mac OS X. But to unify the building environment and to make it easy for debugging, the recommended way is [using Docker](https://github.com/PaddlePaddle/Paddle/blob/develop/doc/howto/dev/contribute_to_paddle_en.md). |
There was a problem hiding this comment.
It is not. Thanks for pointing out. I am correcting it.
| clang-formater.......................................(no files to check)Skipped | ||
| [my-cool-stuff c703c041] add test file | ||
| 1 file changed, 0 insertions(+), 0 deletions(-) | ||
| create mode 100644 233 |
… contribute_and_logging
|
This PR
/CONTRIBUTE.md,doc/.../contribute_to_paddle_en.mdinto/CONTRIBUTE.md, anddoc/.../contribute_to_paddle_cn.md.