update app.py file path
Browse files35 unmodified lines363738394041424 unmodified lines474849505152535455565758596061626347 unmodified lines111112113114115116117152 unmodified lines27027127227335 unmodified lineswith open(filepath, "rb") as img_file:return base64.b64encode(img_file.read()).decode()logo_base64 = img_to_base64("../logo.png")html_content = f"""<div style='display: flex; align-items: center; justify-content: center; padding: 20px;'>4 unmodified lines# Examplesexamples = [["../dataset/examples/0011.png"],["../dataset/examples/0012.png"],["../dataset/examples/0003.png"],["../dataset/examples/0004.png"],["../dataset/examples/0005.png"],["../dataset/examples/0006.png"],["../dataset/examples/0007.png"],["../dataset/examples/0008.png"],["../dataset/examples/0009.png"],["../dataset/examples/0010.png"],["../dataset/examples/0002.png"],]default_example = examples[0]47 unmodified linesmodel = create_model_editguard(opt)if ckp_index == 0:model_pth = '../checkpoints/clean.pth'print(model_pth)model.load_test(model_pth)return model152 unmodified linesrevealing, inputs=[image_edited_1, bit_input, model_list, model], outputs=[edit_mask, bit_output, acc_output])demo.launch(server_name="0.0.0.0", server_port=2004, share=True, favicon_path='../logo.png')35 unmodified lines363738394041424 unmodified lines474849505152535455565758596061626347 unmodified lines111112113114115116117152 unmodified lines27027127227335 unmodified lineswith open(filepath, "rb") as img_file:return base64.b64encode(img_file.read()).decode()logo_base64 = img_to_base64("./logo.png")html_content = f"""<div style='display: flex; align-items: center; justify-content: center; padding: 20px;'>4 unmodified lines# Examplesexamples = [["./dataset/examples/0011.png"],["./dataset/examples/0012.png"],["./dataset/examples/0003.png"],["./dataset/examples/0004.png"],["./dataset/examples/0005.png"],["./dataset/examples/0006.png"],["./dataset/examples/0007.png"],["./dataset/examples/0008.png"],["./dataset/examples/0009.png"],["./dataset/examples/0010.png"],["./dataset/examples/0002.png"],]default_example = examples[0]47 unmodified linesmodel = create_model_editguard(opt)if ckp_index == 0:model_pth = './checkpoints/clean.pth'print(model_pth)model.load_test(model_pth)return model152 unmodified linesrevealing, inputs=[image_edited_1, bit_input, model_list, model], outputs=[edit_mask, bit_output, acc_output])demo.launch(server_name="0.0.0.0", server_port=2004, share=True, favicon_path='./logo.png')
app.py+14-14