-
Notifications
You must be signed in to change notification settings - Fork 179
Update bug report template, add env capture tools #1656
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
Open
kylesayrs
wants to merge
2
commits into
main
Choose a base branch
from
kylesayrs/collect-environment
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
2 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,31 +1,48 @@ | ||
--- | ||
name: Bug report | ||
about: Create a report to help us improve | ||
name: 🐛 Bug report | ||
about: Raise an issue here if you find a bug. | ||
labels: bug | ||
|
||
--- | ||
|
||
**Describe the bug** | ||
A clear and concise description of what the bug is. | ||
|
||
**Expected behavior** | ||
A clear and concise description of what you expected to happen. | ||
|
||
**Environment** | ||
Include all relevant environment information: | ||
1. OS [e.g. Ubuntu 20.04]: | ||
2. Python version [e.g. 3.7]: | ||
3. LLM Compressor version or commit hash [e.g. 0.1.0, `f7245c8`]: | ||
4. ML framework version(s) [e.g. torch 2.3.1]: | ||
5. Other Python package versions [e.g. vLLM, compressed-tensors, numpy, ONNX]: | ||
6. Other relevant environment information [e.g. hardware, CUDA version]: | ||
|
||
**To Reproduce** | ||
Exact steps to reproduce the behavior: | ||
|
||
|
||
**Errors** | ||
If applicable, add a full print-out of any errors or exceptions that are raised or include screenshots to help explain your problem. | ||
|
||
**Additional context** | ||
Add any other context about the problem here. Also include any relevant files. | ||
title: "[Bug]: " | ||
|
||
body: | ||
- type: markdown | ||
attributes: | ||
value: > | ||
#### Before submitting an issue, please make sure the issue hasn't been already addressed by searching through [the existing and past issues](https://github.com/vllm-project/llm-compressor/issues?q=is%3Aissue+sort%3Acreated-desc+). | ||
|
||
#### ⚠️ For any issues related vLLM which are not related to quantization or compressed models, please create an issue in [vllm-project/vllm](https://github.com/vllm-project/vllm/issues). | ||
- type: textarea | ||
attributes: | ||
label: ⚙️ Your current environment | ||
description: | | ||
Please run the following and paste the output below. | ||
```bash | ||
wget https://raw.githubusercontent.com/vllm-project/llm-compressor/main/tools/collect_env.py | ||
# For security purposes, please feel free to check the contents of collect_env.py before running it. | ||
python collect_env.py | ||
``` | ||
value: | | ||
<details> | ||
<summary>The output of <code>python collect_env.py</code></summary> | ||
|
||
```text | ||
Your output of `python collect_env.py` here | ||
``` | ||
|
||
</details> | ||
validations: | ||
required: true | ||
- type: textarea | ||
attributes: | ||
label: 🐛 Describe the bug | ||
description: | | ||
Please provide a clear and concise description of what the bug is. | ||
validations: | ||
required: true | ||
- type: textarea | ||
attributes: | ||
label: 🛠️ Steps to reproduce | ||
description: | | ||
If applicable, please describe any steps required to reproduce. If you can share an applicable huggingface model stub, please do so here. | ||
validations: | ||
required: false |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
""" | ||
Script used to generate environment information for the purpose of | ||
creating bug reports. See `.github/ISSUE_TEMPLATE/bug_report.md` | ||
""" | ||
|
||
import platform | ||
import sys | ||
import importlib | ||
|
||
def get_version(pkg_name): | ||
try: | ||
return importlib.metadata.version(pkg_name) | ||
except importlib.metadata.PackageNotFoundError: | ||
return "None" | ||
|
||
def get_torch_hardware_info(): | ||
try: | ||
import torch | ||
cuda_devices = [] | ||
amd_devices = [] | ||
if torch.cuda.is_available(): | ||
for i in range(torch.cuda.device_count()): | ||
name = torch.cuda.get_device_name(i) | ||
if "AMD" in name.upper(): | ||
amd_devices.append(name) | ||
else: | ||
cuda_devices.append(name) | ||
return cuda_devices, amd_devices | ||
except ImportError: | ||
return [], [] | ||
|
||
def collect_environment_info(): | ||
cuda_devices, amd_devices = get_torch_hardware_info() | ||
|
||
info = { | ||
"Operating System": platform.platform(), | ||
"Python Version": sys.version.replace("\n", " "), | ||
"llm-compressor Version": get_version("llmcompressor"), | ||
"compressed-tensors Version": get_version("compressed_tensors"), | ||
"transformers Version": get_version("transformers"), | ||
"torch Version": get_version("torch"), | ||
"CUDA Devices": cuda_devices if cuda_devices else "None", | ||
"AMD Devices": amd_devices if amd_devices else "None", | ||
} | ||
|
||
print("### Environment Information ###") | ||
for key, value in info.items(): | ||
print(f"{key}: `{value}`") | ||
|
||
if __name__ == "__main__": | ||
collect_environment_info() |
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.