vt-vl-lab / iCAN

[BMVC 2018] iCAN: Instance-Centric Attention Network for Human-Object Interaction Detection
https://gaochen315.github.io/iCAN/
MIT License
258 stars 60 forks source link

Visualize the detection results on HICO_DET #16

Open vaesl opened 5 years ago

vaesl commented 5 years ago

Thanks for sharing your code with us! iCAN is really a fantastic job, I mean that~ May I ask is there any code or tool to visualize the detection results on HICO_DET? I see that there exists one tools/Visualization.ipynb to visualize the detection results on V-COCO. I have tried it and it works well. Hope to hearing from you~ thank you very much!

Carbord commented 5 years ago

Hello, I got some troubles while reading the "Demo/Test on your own images" in readme.md. In the third step and fourth step, there exists the pamameter like "demo/Object_Detection.pkl" and "demo/HOI_Detection.pkl", but I cannot find these two pkl files in demo folder. So I would like to know whether these pkl files need to be trained to attain them by myself. Hope to hearing from you, thanks a lot.

gaochen315 commented 5 years ago

Hi @Carbord,

Sorry for the confusion. The parameter "--Demo_RCNN demo/Object_Detection.pkl" is just for specifying the path to store the output result. You can simply run step3 and 4. These two lines of code will generate Object_Detection.pkl and HOI_Detection.pkl for you.

Let me know if you have any question.

zhaowuyao commented 5 years ago

I cannot find these two pkl files ("demo/Object_Detection.pkl" and "demo/HOI_Detection.pkl")in demo folder. So I would like to know whether these pkl files need to be trained to attain them by myself You said the step 3 and step 4 is what?Can you said more detail about step 3 and step 4?Hope to hearing from you, thanks

gaochen315 commented 5 years ago

@zhaowuyao, there are five steps listed in the Demo/Test on your own images section. Step 1 is for setting up the external object detector. Then please put your own images in the demo folder, as stated in step 2. Then you can simply run the commands showed in step 3 and step 4. These two commands will generate these two pkl files for you. Finally, following step 5, you can use the provided tools/Demo.ipynb to visualize the HOI results.

gaochen315 commented 5 years ago

Hi @vaesl, I am working on the iCAN v2. Once finished, I will update the visualization code which will support HICO-DET as well.

ZHUXUHAN commented 5 years ago

@gaochen315 hi, good jobs,I have a question, the visualization.py files is just for the vcoco datasets,i also use it for the hoi-det,i just train it 10 epochs, but the action results for one person is much, so the visualization image is chaotic and dense, I don't konw why, can you replay? thanks

gaochen315 commented 5 years ago

@ZHUXUHAN, I am not sure if I fully understand your question. Several comments:

  1. Do you mean by Visualization.ipynb? Visualization.py is for showing the bbox in tensorflow.
  2. You can adjust the threshold. By default, it will show all the detections.
  3. I also provided my HICO detection results. You can start from there.
zhaowuyao commented 5 years ago

step3 and step are where?What are the command contents of steps 3 and 4? I ran all the commands in your readme.md and didn't produce two pkl files ("demo/Object_Detection.pkl" and "demo/HOI_Detection.pkl")in demo folder.

gaochen315 commented 5 years ago

@zhaowuyao, they are under the Demo/Test on your own images section. Can't you find them? Or can you describe what you have done so I can help

zhaowuyao commented 5 years ago

Thanks .It is my fault.I have solved.

gaochen315 commented 5 years ago

@zhaowuyao, I don't understand what you mean by "run Visualization.ipynb". You have to execute all the sections in the provided notebook.

zhaowuyao commented 5 years ago

thanks!

ZHUXUHAN commented 5 years ago

@ZHUXUHAN, I am not sure if I fully understand your question. Several comments:

  1. Do you mean by Visualization.ipynb? Visualization.py is for showing the bbox in tensorflow.
  2. You can adjust the threshold. By default, it will show all the detections.
  3. I also provided my HICO detection results. You can start from there.

@ZHUXUHAN, I am not sure if I fully understand your question. Several comments:

  1. Do you mean by Visualization.ipynb? Visualization.py is for showing the bbox in tensorflow.
  2. You can adjust the threshold. By default, it will show all the detections.
  3. I also provided my HICO detection results. You can start from there.

yes,i run the visualization.ipynb,by default,the threshold is 0.01,if the visualization.ipynb can run for the hico detection, if the model for hico is in the Results/HICO_DET/1800000_iCAN_ResNet50_HICO.zip? I just don't find the model for hico

ZHUXUHAN commented 5 years ago

@gaochen315 I see the code in demo.ipynb the model is iCAN_ResNet50_VCOCO, what can I modify it for hico-det

CherryBear1314 commented 5 years ago

@zhaowuyao, there are five steps listed in the Demo/Test on your own images section. Step 1 is for setting up the external object detector. Then please put your own images in the demo folder, as stated in step 2. Then you can simply run the commands showed in step 3 and step 4. These two commands will generate these two pkl files for you. Finally, following step 5, you can use the provided tools/Demo.ipynb to visualize the HOI results.

hi, thanks for sharing your code. I have a problem when to run the commands 3, that is “ can't open file ../tf-faster-rcnn/tools/object.Detector.py' [Errno 2] No such file or directory”. And in the tf-faster-rcnn repository , I can't find the file of object.Detector.py. So I would like to know whether this files need to be download somewhere by myself. Hope to hear from you, thank you very much!

gaochen315 commented 5 years ago

Hi @CherryBear1314,

Did you do the first step, i.e.

chmod +x ./misc/setup_demo.sh 
./misc/setup_demo.sh

In line 21, it copy misc/Object_Detector.py to ../tf-faster-rcnn/tools/ and that's the file you are looking for.