problem with MegadetectorV6
Search before asking
- [X] I have searched the Pytorch-Wildlife issues and found no similar bug report.
Bug
Hi, Thanks for the code and model weights.
I try to use MegadetectorV6 and I have a problem LooseVersion = distutils.version.LooseVersion AttributeError: module 'distutils' has no attribute 'version'
How can I fix it?
Environment
No response
Minimal Reproducible Example
No response
Additional
No response
Are you willing to submit a PR?
- [ ] Yes I'd like to help by submitting a PR!
Hello @Ladanovasv , thanks for reporting! This is something we have never seen before. Did you pip install . -e?
Hello @zhmiao, yes, I did
Hello @Ladanovasv, it might be caused my setuptool versions according to these issues: https://github.com/Lightning-AI/pytorch-lightning/issues/12324 and https://github.com/pytorch/pytorch/issues/69894 . Could you try pip install setuptools==59.5.0 and see if that works?
Hello @zhmiao It is fixed first problem, but I have a new problem. RuntimeError: CUDA error: no kernel image is available for execution on the device CUDA kernel errors might be asynchronously reported at some other API call,so the stacktrace below might be incorrect. For debugging consider passing CUDA_LAUNCH_BLOCKING=1.
Hello @zhmiao It is fixed first problem, but I have a new problem. RuntimeError: CUDA error: no kernel image is available for execution on the device CUDA kernel errors might be asynchronously reported at some other API call,so the stacktrace below might be incorrect. For debugging consider passing CUDA_LAUNCH_BLOCKING=1.
Hello @zhmiao It is fixed first problem, but I have a new problem. RuntimeError: CUDA error: no kernel image is available for execution on the device CUDA kernel errors might be asynchronously reported at some other API call,so the stacktrace below might be incorrect. For debugging consider passing CUDA_LAUNCH_BLOCKING=1.
This might be related to your cuda version. Do you know what cuda version are you using?
Hello @zhmiao, I am using cuda 12.3
Hello @zhmiao, I am using cuda 12.3
Do you have problem importing pytorch independently? I did some search and it might be an issue related the compatibility of pytorch and cuda. I assume you are using the pip install -r requirement.txt to install the packages right? That might be the issue because pip install cuda 12.1 version of pytorch by default. Could you try a clean environment and pip install torch torchvision torchaudio --index-url https://download.pytorch.org/whl/cu124, and see if it works?
Hello @Ladanovasv,
Due to inactivity, this issue will be closed. If you're still encountering the problem, please feel free to reopen it.
Thank you for your contributions!