YANGYYYY commited on
Commit
a62524f
1 Parent(s): 3264d7c

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -6
app.py CHANGED
@@ -14,7 +14,7 @@ from inference import Predictor
14
 
15
  def parse_args():
16
  parser = argparse.ArgumentParser()
17
- parser.add_argument('--weight', type=str, default='cartoonize/GeneratorV2_train_photo_Hayao_init.pt')
18
  parser.add_argument('--device', type=str, default='cpu', help='Device, cuda or cpu')
19
 
20
  return parser.parse_args()
@@ -38,11 +38,6 @@ def clear_output(input_widget):
38
  input_widget = np.array([])
39
 
40
  with gr.Blocks() as demo:
41
- os.system("wget https://huggingface.co/YANGYYYY/cartoonize/tree/main/GeneratorV2_train_photo_Hayao_init.pt")
42
- if os.path.exists("GeneratorV2_train_photo_Hayao_init.pt"):
43
- print("下载成功!")
44
- else:
45
- print("下载失败!")
46
  gr.Markdown("Transfer image or video files using this demo.")
47
  with gr.Tabs():
48
  with gr.TabItem("Transfer Image"):
 
14
 
15
  def parse_args():
16
  parser = argparse.ArgumentParser()
17
+ parser.add_argument('--weight', type=str, default='GeneratorV2_train_photo_Hayao_init.pt')
18
  parser.add_argument('--device', type=str, default='cpu', help='Device, cuda or cpu')
19
 
20
  return parser.parse_args()
 
38
  input_widget = np.array([])
39
 
40
  with gr.Blocks() as demo:
 
 
 
 
 
41
  gr.Markdown("Transfer image or video files using this demo.")
42
  with gr.Tabs():
43
  with gr.TabItem("Transfer Image"):