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

"Segmentation fault" when importing torch #486

Closed
loicmagne opened this issue Oct 25, 2024 · 2 comments
Closed

"Segmentation fault" when importing torch #486

loicmagne opened this issue Oct 25, 2024 · 2 comments
Labels
bug Something isn't working

Comments

@loicmagne
Copy link

Ubuntu 24.04, Python 3.12.3, torch 2.4.0+cu124
Simply having import torch in a test.py file, and using viztracer test.py gives me: Segmentation fault (core dumped)

@gaogaotiantian gaogaotiantian added the bug Something isn't working label Oct 25, 2024
@gaogaotiantian
Copy link
Owner

Ah, I knew I saw this somewhere. This was a bug in CPython (python/cpython#122029) and was actually fixed by myself.. 3.12.5+ should work.

@gaogaotiantian gaogaotiantian closed this as not planned Won't fix, can't repro, duplicate, stale Oct 25, 2024
@gaogaotiantian
Copy link
Owner

I agree segfault is probably not the way to go even if this is a bug of CPython, but we do have some assumptions in VizTracer (for example, a c_return always corresponds to a c_call, not a call), and if those assumptions are broken by CPython, we can't really figure out what's going on. So at this time, maybe just upgrade CPython?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants