edisonlee55 commited on
Commit
f45b35d
1 Parent(s): 5f0f47d

build: cleanup

Browse files
Files changed (2) hide show
  1. app.py +1 -4
  2. requirements.txt +4 -1
app.py CHANGED
@@ -21,7 +21,6 @@ import gradio as gr
21
  import huggingface_hub
22
  import numpy as np
23
  import PIL.Image
24
- import torch
25
 
26
  import anime_face_detector
27
 
@@ -81,9 +80,7 @@ def main():
81
  parser.add_argument(
82
  "--detector", type=str, default="yolov3", choices=["yolov3", "faster-rcnn"]
83
  )
84
- parser.add_argument(
85
- "--device", type=str, default="cpu", choices=["cuda:0", "cpu"]
86
- )
87
  parser.add_argument("--face-score-threshold", type=float, default=0.5)
88
  parser.add_argument("--landmark-score-threshold", type=float, default=0.3)
89
  parser.add_argument("--score-slider-step", type=float, default=0.05)
 
21
  import huggingface_hub
22
  import numpy as np
23
  import PIL.Image
 
24
 
25
  import anime_face_detector
26
 
 
80
  parser.add_argument(
81
  "--detector", type=str, default="yolov3", choices=["yolov3", "faster-rcnn"]
82
  )
83
+ parser.add_argument("--device", type=str, default="cpu", choices=["cuda:0", "cpu"])
 
 
84
  parser.add_argument("--face-score-threshold", type=float, default=0.5)
85
  parser.add_argument("--landmark-score-threshold", type=float, default=0.3)
86
  parser.add_argument("--score-slider-step", type=float, default=0.05)
requirements.txt CHANGED
@@ -1,4 +1,4 @@
1
- # python=3.10
2
  openmim==0.3.7
3
  mmcv-full==1.6.2
4
  mmdet==2.28.2
@@ -9,6 +9,9 @@ scipy==1.10.1
9
 
10
  opencv-python-headless==4.7.0.72
11
 
 
 
 
12
  torch==2.0.1
13
  torchvision==0.15.2
14
 
 
1
+ # python=3.8
2
  openmim==0.3.7
3
  mmcv-full==1.6.2
4
  mmdet==2.28.2
 
9
 
10
  opencv-python-headless==4.7.0.72
11
 
12
+ # PyTorch with CUDA support (use pip with `--index-url https://download.pytorch.org/whl/cu118`)
13
+ # torch==2.0.1+cu118
14
+
15
  torch==2.0.1
16
  torchvision==0.15.2
17