Skip to content

Conversation

@amd-vlarakic
Copy link
Contributor

@amd-vlarakic amd-vlarakic commented Oct 30, 2025

Issue:
Running GPTQModel based inference workload with ROCm generated Triton results in ValueError when converting patch version from string to integer:

File "/home/taccuser/workspace/dart/tmp7kf9o3i3_pyt_rocm_deepseek-r1-distill-llama-8b-gptq_inf/environment/lib64/python3.12/site-packages/gptqmodel/utils/nogil_patcher.py", line 42, in <genexpr>
    if version is None or tuple(int(part) for part in version.split(".")[:3]) < (3, 5, 0):
                                ^^^^^^^^^
ValueError: invalid literal for int() with base 10: '0+rocm7'

Resolution:
Fix applies more robust version comparison using packaging.version.Version module extensively used across the GPTQModel code base.

@amd-vlarakic
Copy link
Contributor Author

Hi @Qubitium ,
Could you take a look?

@Qubitium
Copy link
Collaborator

@amd-vlarakic LGTM! Use Version is definitely better than the previous string split code. Thanks for the fix.

@Qubitium Qubitium merged commit 2f4785b into ModelCloud:main Oct 30, 2025
1 check failed
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

Successfully merging this pull request may close these issues.

2 participants