bknyaz / sgg

Train Scene Graph Generation for Visual Genome and GQA in PyTorch >= 1.2 with improved zero and few-shot generalization.
https://arxiv.org/abs/2007.05756
Other
130 stars 20 forks source link

How to create a scenegraph from a custom image? #6

Open donggu-kang opened 3 years ago

donggu-kang commented 3 years ago

Your research is very good, and it is very helpful to me. Thank you for always.

I would like to proceed with creating a scenegraph for my custom image.

Can you help me how I can do it?

I would like to modify the Jupiter notebook source code provided by you, if possible, to give a custom image as input.

bknyaz commented 3 years ago

Simply try loading and passing your custom image in the line det_res = detector.forward_parallel(b) of the notebook. Make sure the image is in the appropriate shape and range of values, which you can see by inspecting tensor b for GQA images.

donggu-kang commented 3 years ago

Simply try loading and passing your custom image in the line det_res = detector.forward_parallel(b) of the notebook. Make sure the image is in the appropriate shape and range of values, which you can see by inspecting tensor b for GQA images.

Sorry, can you tell me a little more?

donggu-kang commented 3 years ago

Hi.

I want to put more than 1000 png/jpg images in the folder I designated and proceed with the scene graph generation.

I want to save the generated scene graph and other results in a text file or json format.

Also I would like to batch this.

Is there a good way?

liuJP2 commented 1 year ago

Hi.

I want to put more than 1000 png/jpg images in the folder I designated and proceed with the scene graph generation.

I want to save the generated scene graph and other results in a text file or json format.

Also I would like to batch this.

Is there a good way?

hello~Have you found a way to solve it? I had the same problem