KaihuaTang / Scene-Graph-Benchmark.pytorch

A new codebase for popular Scene Graph Generation methods (2020). Visualization & Scene Graph Extraction on custom images/datasets are provided. It's also a PyTorch implementation of paper “Unbiased Scene Graph Generation from Biased Training CVPR 2020”
MIT License
1.06k stars 229 forks source link

PredCls, SGCls for custom images #192

Open park-youngjae opened 1 year ago

park-youngjae commented 1 year ago

Thank you for your wonderful work for Scene Graph Generation tasks.

I would like to use your code as a baseline for my research.

In addition, could you provide PredCls and SGCls codes for custom images inference?

Thank you.

explorer-shy commented 1 year ago

Check the reademe.md first.

SGDet on Custom Images

Note that evaluation on custum images is only applicable for SGDet model, because PredCls and SGCls model requires additional ground-truth bounding boxes information. To detect scene graphs into a json file on your own images, you need to turn on the switch TEST.CUSTUM_EVAL and give a folder path (or a json file containing a list of image paths) that contains the custom images to TEST.CUSTUM_PATH. Only JPG files are allowed. The output will be saved as custom_prediction.json in the given DETECTED_SGG_DIR.