Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How can I disable ROCm console outputs in jupyter notebook when using tensorflow? #2112

Open
witeko opened this issue May 27, 2023 · 2 comments

Comments

@witeko
Copy link

witeko commented May 27, 2023

Issue Type

Documentation Feature Request

Have you reproduced the bug with TF nightly?

Yes

Source

source

Tensorflow Version

any

Custom Code

No

OS Platform and Distribution

Ubuntu 22.04

Mobile device

No response

Python version

No response

Bazel version

No response

GCC/Compiler version

No response

CUDA/cuDNN version

No response

GPU model and memory

No response

Current Behaviour?

How can I disable ROCm console outputs such as:
"2023-05-27 12:28:47.983480: I tensorflow/core/common_runtime/gpu_fusion_pass.cc:507] ROCm Fusion is enabled.
2023-05-27 12:28:47.983910: I tensorflow/core/common_runtime/gpu_fusion_pass.cc:507] ROCm Fusion is enabled.
2023-05-27 12:28:47.984174: I tensorflow/core/common_runtime/gpu_fusion_pass.cc:507] ROCm Fusion is enabled.
2023-05-27 12:28:47.984671: I tensorflow/core/common_runtime/gpu_fusion_pass.cc:507] ROCm Fusion is enabled.
2023-05-27 12:28:47.984925: I tensorflow/core/common_runtime/gpu_fusion_pass.cc:507] ROCm Fusion is enabled.
2023-05-27 12:28:47.985701: I tensorflow/core/common_runtime/gpu_fusion_pass.cc:507] ROCm Fusion is enabled.
2023-05-27 12:28:47.985955: I tensorflow/core/common_runtime/gpu_fusion_pass.cc:507] ROCm Fusion is enabled."

Standalone code to reproduce the issue

Any model fitting.

Relevant log output

No response

@ZappaBoy
Copy link

ZappaBoy commented Jun 7, 2023

I use the following to disable the logs. Set the following based on your needs:

self.rocm_logging_level = -1  # -1 disables logs
os.environ['MIOPEN_ENABLE_LOGGING'] = f'{1 if self.rocm_logging_level > 0 else 0}'
os.environ['MIOPEN_ENABLE_LOGGING_CMD'] = f'{1 if self.rocm_logging_level > 0 else 0}'
os.environ['MIOPEN_LOG_LEVEL'] = f'{self.rocm_logging_level}'
os.environ['TF_CPP_MAX_VLOG_LEVEL'] = f'{self.rocm_logging_level}'

You can simply change rocm_logging_level based on Debug And Logging specifications.

However I have not yet been able to disable the SetTensor/CopyTensor logs, I'm going to open an issue about this.

@ppanchad-amd
Copy link

@witeko Has your issue been resolved? If so, please close the ticket. Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants