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

About the Operation of the Newly Added Visualize #3924

Closed
Zengyf-CVer opened this issue Jul 7, 2021 · 2 comments · Fixed by #3925
Closed

About the Operation of the Newly Added Visualize #3924

Zengyf-CVer opened this issue Jul 7, 2021 · 2 comments · Fixed by #3925
Labels
bug Something isn't working

Comments

@Zengyf-CVer
Copy link
Contributor

Zengyf-CVer commented Jul 7, 2021

@glenn-jocher

I just ran the newly added feature map visualization command:

python detect.py --visualize --weights ./weight/yolov5s.pt --source ./train2017/000000000081.jpg

Then this error was reported in the shell:

TypeError: can't convert cuda:0 device type tensor to numpy. Use Tensor.cpu() to copy the tensor to host memory first.

The following is a specific screenshot:
ksnip_20210707-221125

My configuration:

  • python 3.8
  • CUDA 11.1
  • PyTorch 1.9.0
@Zengyf-CVer Zengyf-CVer added the bug Something isn't working label Jul 7, 2021
@glenn-jocher
Copy link
Member

@Zengyf-CVer ah, thanks for the bug report.

@glenn-jocher glenn-jocher linked a pull request Jul 7, 2021 that will close this issue
@glenn-jocher
Copy link
Member

glenn-jocher commented Jul 7, 2021

@Zengyf-CVer good news 😃! Your original issue may now be fixed ✅ in PR #3925. To receive this update:

  • Gitgit pull from within your yolov5/ directory or git clone https://github.com/ultralytics/yolov5 again
  • PyTorch Hub – Force-reload with model = torch.hub.load('ultralytics/yolov5', 'yolov5s', force_reload=True)
  • Notebooks – View updated notebooks Open In Colab Open In Kaggle
  • Dockersudo docker pull ultralytics/yolov5:latest to update your image Docker Pulls

Thank you for spotting this issue and informing us of the problem. Please let us know if this update resolves the issue for you, and feel free to inform us of any other issues you discover or feature requests that come to mind. Happy trainings with YOLOv5 🚀!

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

Successfully merging a pull request may close this issue.

2 participants