Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix ipadapter #2708

Open
wants to merge 3 commits into
base: develop
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ export USE_PPXFORMERS=False
--scheduler "ddim" \
--backend paddle \
--device gpu \
--task_name text2img) 2>&1 | tee ${log_dir}/deploy_ipadapter_sd15_inference_text2img.log
--task_name text2img) 2>&1 | tee ${log_dir}/ipadapter_sd15_inference_text2img.log
tmp_exit_code=${PIPESTATUS[0]}
exit_code=$(($exit_code + ${tmp_exit_code}))
if [ ${tmp_exit_code} -eq 0 ]; then
Expand Down Expand Up @@ -47,7 +47,7 @@ echo "*******ppdiffusers/deploy/sd15 ipadapter_sd15_inference_img2img end*******
--scheduler "ddim" \
--backend paddle \
--device gpu \
--task_name inpaint) 2>&1 | tee ${log_dir}/sd15_inference_inpaint.log
--task_name inpaint_legacy) 2>&1 | tee ${log_dir}/ipadapter_sd15_inference_inpaint.log
tmp_exit_code=${PIPESTATUS[0]}
exit_code=$(($exit_code + ${tmp_exit_code}))
if [ ${tmp_exit_code} -eq 0 ]; then
Expand Down
24 changes: 24 additions & 0 deletions models/PaddleMIX/CE/ppdiffusers/deploy/ipadapter/sd15/start.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
#!/bin/bash

cur_path=$(pwd)
echo ${cur_path}

work_path1=${root_path}/PaddleMIX/ppdiffusers/deploy/ipadapter/sd15
echo ${work_path1}

log_dir=${root_path}/deploy_log

if [ ! -d "$log_dir" ]; then
mkdir -p "$log_dir"
fi

/bin/cp -rf ./* ${work_path1}/
exit_code=0

cd ${work_path1}

bash sd15_export.sh
exit_code=$(($exit_code + $?))

bash sd15_infer.sh
exit_code=$(($exit_code + $?))
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ echo "*******ppdiffusers/deploy/sdxl ipadapter_sdxl_inference_img2img end*******
--scheduler "ddim" \
--backend paddle \
--device gpu \
--task_name inpaint) 2>&1 | tee ${log_dir}/sdxl_inference_inpaint.log
--task_name inpaint) 2>&1 | tee ${log_dir}/ipadapter_sdxl_inference_inpaint.log
tmp_exit_code=${PIPESTATUS[0]}
exit_code=$(($exit_code + ${tmp_exit_code}))
if [ ${tmp_exit_code} -eq 0 ]; then
Expand Down Expand Up @@ -84,7 +84,7 @@ echo "*******ppdiffusers/deploy/sdxl ipadapter_sdxl_inference_tune end**********
--model_dir static_model/stable-diffusion-xl-base-1.0-ipadapter \
--scheduler "ddim" \
--backend paddle_tensorrt \
--device gpu --task_name text2img) 2>&1 | tee ${log_dir}/sdxl_inference_tensorrt_text2img.log
--device gpu --task_name text2img) 2>&1 | tee ${log_dir}/ipadapter_sdxl_inference_tensorrt_text2img.log
tmp_exit_code=${PIPESTATUS[0]}
exit_code=$(($exit_code + ${tmp_exit_code}))
if [ ${tmp_exit_code} -eq 0 ]; then
Expand All @@ -100,7 +100,7 @@ echo "*******ppdiffusers/deploy/sdxl ipadapter_sdxl_inference_tensorrt_text2img
--scheduler "ddim" \
--backend paddle_tensorrt \
--device gpu \
--task_name img2img) 2>&1 | tee ${log_dir}/sdxl_inference_tensorrt_img2img.log
--task_name img2img) 2>&1 | tee ${log_dir}/ipadapter_sdxl_inference_tensorrt_img2img.log
tmp_exit_code=${PIPESTATUS[0]}
exit_code=$(($exit_code + ${tmp_exit_code}))
if [ ${tmp_exit_code} -eq 0 ]; then
Expand All @@ -116,7 +116,7 @@ echo "*******ppdiffusers/deploy/sdxl ipadapter_sdxl_inference_tensorrt_img2img e
--scheduler "ddim" \
--backend paddle_tensorrt \
--device gpu \
--task_name inpaint) 2>&1 | tee ${log_dir}/sdxl_inference_tensorrt_inpaint.log
--task_name inpaint) 2>&1 | tee ${log_dir}/ipadapter_sdxl_inference_tensorrt_inpaint.log
tmp_exit_code=${PIPESTATUS[0]}
exit_code=$(($exit_code + ${tmp_exit_code}))
if [ ${tmp_exit_code} -eq 0 ]; then
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,25 +3,12 @@
cur_path=$(pwd)
echo ${cur_path}

work_path1=${root_path}/PaddleMIX/ppdiffusers/deploy/ipadapter/sd15
echo ${work_path1}

log_dir=${root_path}/deploy_log

if [ ! -d "$log_dir" ]; then
mkdir -p "$log_dir"
fi

/bin/cp -rf ./* ${work_path1}/
exit_code=0

cd ${work_path1}

bash sd15_export.sh
exit_code=$(($exit_code + $?))

bash sd15_infer.sh
exit_code=$(($exit_code + $?))


work_path2=${root_path}/PaddleMIX/ppdiffusers/deploy/ipadapter/sdxl
Expand Down