add DiffusionInpaintModel
This commit is contained in:
@@ -123,32 +123,3 @@ def make_compare_gif(
|
||||
loop=0
|
||||
)
|
||||
return img_byte_arr.getvalue()
|
||||
|
||||
|
||||
if __name__ == '__main__':
|
||||
imgs = [
|
||||
(
|
||||
'/Users/qing/code/github/lama-cleaner/assets/unwant_person.jpg',
|
||||
'/Users/qing/code/github/lama-cleaner/assets/unwant_person_clean.jpg'
|
||||
),
|
||||
# (
|
||||
# '/Users/qing/code/github/lama-cleaner/assets/old_photo.jpg',
|
||||
# '/Users/qing/code/github/lama-cleaner/assets/old_photo_clean.jpg'
|
||||
# ),
|
||||
# (
|
||||
# '/Users/qing/code/github/lama-cleaner/assets/unwant_object.jpg',
|
||||
# '/Users/qing/code/github/lama-cleaner/assets/unwant_object_clean.jpg'
|
||||
# ),
|
||||
# (
|
||||
# '/Users/qing/code/github/lama-cleaner/assets/unwant_text.jpg',
|
||||
# '/Users/qing/code/github/lama-cleaner/assets/unwant_text_clean.jpg'
|
||||
# ),
|
||||
# (
|
||||
# '/Users/qing/code/github/lama-cleaner/assets/watermark.jpg',
|
||||
# '/Users/qing/code/github/lama-cleaner/assets/watermark_cleanup.jpg'
|
||||
# ),
|
||||
]
|
||||
for src_p, clean_p in imgs:
|
||||
img_bytes = make_compare_gif(Image.open(src_p), Image.open(clean_p), max_side_length=600)
|
||||
with open(Path(src_p).with_suffix('.gif'), 'wb') as f:
|
||||
f.write(img_bytes)
|
||||
|
||||
Reference in New Issue
Block a user