Closed marcemq closed 1 year ago
You can obtain the density map by 'output = model(input)[0]' in the test.py.
Morales Quispe, Marcela @.***> δΊ2023εΉ΄5ζ26ζ₯ε¨δΊ 02:07ειοΌ
Hello @LoraLinH https://github.com/LoraLinH :)
Thank you for sharing the code for the 'Boosting Crowd Counting via Multifaceted Attention' paper.
I'm intended to use it for initial step in a crowd forecasting project. I was able to execute test.py file and see the mae and mse results π
Now, I want to be able to given an input image get its density map. Checking the paper I think it's an output of the Regression Decoder, but I couldn't found it in the code, so would you please point me how to achieve this?
Big thank you in advance.
β Reply to this email directly, view it on GitHub https://github.com/LoraLinH/Boosting-Crowd-Counting-via-Multifaceted-Attention/issues/11, or unsubscribe https://github.com/notifications/unsubscribe-auth/AVYQMFWDPBXXSHOFFSUYICDXH6NVXANCNFSM6AAAAAAYPGCZ2U . You are receiving this because you were mentioned.Message ID: <LoraLinH/Boosting-Crowd-Counting-via-Multifaceted-Attention/issues/11@ github.com>
Hello @LoraLinH, thank you for your reply.
I've manage to write such output into an image for the very first iteration, this output is expected right?
Code to generate the image:
outputs = model(inputs)[0] # a tensor of [1,1,117,156] and values between 0-1
outImg = outputs[0][0].detach().cpu().numpy()
cv2.imwrite("test.png", outImg*255)
Hello @LoraLinH :)
Thank you for sharing the code for the 'Boosting Crowd Counting via Multifaceted Attention' paper.
I'm intended to use it for initial step in a crowd forecasting project. I was able to execute
test.py
file and see the mae and mse results πNow, I want to be able to given an input image get its density map. Checking the paper I think it's an output of the Regression Decoder, but I couldn't found it in the code, so would you please point me how to achieve this?
Big thank you in advance.