Skip to content

Latest commit

 

History

History
40 lines (25 loc) · 819 Bytes

README.md

File metadata and controls

40 lines (25 loc) · 819 Bytes

CtrlHair

Controllable Hair Editing (ECCV 2022)

Install

Need python3.8 and GPU runtime environment

Clone this repo

Install python packages

  • bash script/install.sh

Download pretrained model and parameters

  • python script/download.py

Run API server

  • python app.py

can see PORT and IP here -> (

CtrlHair/app.py

Line 117 in b19ec1c

app.run(host='0.0.0.0',port=5555,debug=False)
)

Test API server

  • python test.py

    or

      curl --location --request POST 'http://0.0.0.0:5555/swaphair' \
      --header 'Content-Type: application/json' \
      --data-raw '{ \
        "srcimg": "data:image/png;base64,/9j/4AAQSkZJRgABAQEAYABgAAD....", \
        "dstimg": "data:image/png;base64,/9j/4AAQSkZJRgABAQEAYABgAAD....", \
      }