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

no box detected using code in the codelab demo #31

Closed
abril4416 opened this issue Jul 26, 2022 · 6 comments
Closed

no box detected using code in the codelab demo #31

abril4416 opened this issue Jul 26, 2022 · 6 comments

Comments

@abril4416
Copy link

Thanks for the great work! I'm trying the code provided in your codelab demo. However, there is no bounding box detected (No errors appear during the compiling and execution). I've also tried to re-install packages to ensure versions of packages on my server are the same as those in your code. Is there any possible reasons for the result?
image
image

@Haotian-Zhang
Copy link
Collaborator

Haotian-Zhang commented Jul 26, 2022

@abril4416 Hi, thank you for the support! Due to the recent update of the Colab env (CUDA and Pytorch version), our original code does not seem compatible. There are mainly two quick fixes that need to be added to the notebook and to the codes to make the demo work.

  1. In the Colab demo: 'cuda' needs to be changed with 'cuda-10.2'

image

After installing the cuda-10.2, it's always better to double-check the CUDA installation with '!nvcc -V'.
  1. In the codes (maskrcnn_benchmark/engine/predictor_glip.py)
    image, s, (int(x), int(y)-text_offset_original), cv2.FONT_HERSHEY_SIMPLEX, text_size, (self.color, self.color, self.color), text_pixel, cv2.LINE_AA
    , please change the self.color to 255.

image

Sorry I am currently busy with something else, so I don't have time to update the codes. We will make sure to fix the issues and release them with the updated GLIPv2 codes and models very soon. Thanks for the support and patience!

@abril4416
Copy link
Author

Hi haotian, thanks for the patient reply. I'll try the updated codes as you've mentioned first. A problem is that I re-use the code on my own server, but there is no bounding box detected (no errors appeared). Could you please offer some suggestions when you are free?

@abril4416 Hi, thank you for the support! Due to the recent update of the Colab env (CUDA and Pytorch version), our original code does not seem compatible. There are mainly two quick fixes that need to be added to the notebook and to the codes to make the demo work.

  1. In the Colab demo: 'cuda' needs to be changed with 'cuda-10.2'
image

After installing the cuda-10.2, it's always better to double-check the CUDA installation with '!nvcc -V'.
2. In the codes (maskrcnn_benchmark/engine/predictor_glip.py)

image, s, (int(x), int(y)-text_offset_original), cv2.FONT_HERSHEY_SIMPLEX, text_size, (self.color, self.color, self.color), text_pixel, cv2.LINE_AA

, please change the self.color to 255.

image

Sorry I am currently busy with something else, so I don't have time to update the codes. We will make sure to fix the issues and release them with the updated GLIPv2 codes and models very soon. Thanks for the support and patience!

@ktrapeznikov
Copy link

@abril4416 did you ever solve your problem?

@liunian-harold-li
Copy link
Collaborator

liunian-harold-li commented Aug 2, 2022 via email

@MrWaterZhou
Copy link

no need to change the code.
just add
glip_demo.color = 255
after initialize "GLIPDemo" class

@Space-Xun
Copy link

Hi haotian, thanks for the patient reply. I'll try the updated codes as you've mentioned first. A problem is that I re-use the code on my own server, but there is no bounding box detected (no errors appeared). Could you please offer some suggestions when you are free?

@abril4416 Hi, thank you for the support! Due to the recent update of the Colab env (CUDA and Pytorch version), our original code does not seem compatible. There are mainly two quick fixes that need to be added to the notebook and to the codes to make the demo work.

  1. In the Colab demo: 'cuda' needs to be changed with 'cuda-10.2'
image After installing the cuda-10.2, it's always better to double-check the CUDA installation with '!nvcc -V'. 2. In the codes (maskrcnn_benchmark/engine/predictor_glip.py) https://github.com/microsoft/GLIP/blob/fd52c6361f013e70ae7682d90b3ab3ca2bd5e6bc/maskrcnn_benchmark/engine/predictor_glip.py#L347

, please change the self.color to 255.
image
Sorry I am currently busy with something else, so I don't have time to update the codes. We will make sure to fix the issues and release them with the updated GLIPv2 codes and models very soon. Thanks for the support and patience!

hello, have you solved the bbox problem? I met the same problem, there is no bbox like the Demo.

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

No branches or pull requests

6 participants