Skip to content

Latest commit

 

History

History
14 lines (11 loc) · 1.14 KB

geo_edit.md

File metadata and controls

14 lines (11 loc) · 1.14 KB

Object geometry editing

We also edit object geometry attributes (size, position) by diffusion-based inpainting methods. We employ stable-diffusion-inpainting and controlnet.

Inference

Then, run the following command to apply editing on the source image.

python inference.py --config_path config.yaml

Then, the inpainted image, transformed object mask and transformed semseg label will be stored under data.image_save_path, data.mask_save_path, data.semseg_save_path.

In config file, inference.mode means the geometry editing types, "resize" means adjusting size of objects, "reposition" means moving objects. inference.scale is a hyperparameter that means amplitude of geometry editing, its value usually from 0.1-0.3.

Dataset editing

Above is the instruction of editing individual image. If generate synthetic evaluation dataset, you should write your own scripts. You may need object masks, source images, and semantic segmentation labels accquired from previous dataset preparation step.