rlawjdghek commited on
Commit
6db35fc
β€’
1 Parent(s): 87d708c

detectron first

Browse files
Files changed (1) hide show
  1. app.py +4 -9
app.py CHANGED
@@ -1,3 +1,7 @@
 
 
 
 
1
  import os
2
  import sys
3
  import time
@@ -14,20 +18,11 @@ print("pip import done")
14
 
15
  from cldm.model import create_model
16
  from cldm.plms_hacked import PLMSSampler
17
- from detectron2.data.detection_utils import _apply_exif_orientation, convert_PIL_to_numpy
18
  from utils_stableviton import get_batch, get_mask_location, tensor2img
19
 
20
  PROJECT_ROOT = Path(__file__).absolute().parents[1].absolute()
21
  sys.path.insert(0, str(PROJECT_ROOT))
22
 
23
- from preprocess.detectron2.projects.DensePose.apply_net_gradio import DensePose4Gradio
24
- from preprocess.humanparsing.run_parsing import Parsing
25
- from preprocess.openpose.run_openpose import OpenPose
26
- # import apply_net
27
- print("app import done")
28
-
29
- # os.environ['GRADIO_TEMP_DIR'] = './tmp' # TODO: turn off when final upload
30
-
31
  IMG_H = 512
32
  IMG_W = 384
33
 
 
1
+ from preprocess.detectron2.projects.DensePose.apply_net_gradio import DensePose4Gradio
2
+ from preprocess.humanparsing.run_parsing import Parsing
3
+ from preprocess.openpose.run_openpose import OpenPose
4
+
5
  import os
6
  import sys
7
  import time
 
18
 
19
  from cldm.model import create_model
20
  from cldm.plms_hacked import PLMSSampler
 
21
  from utils_stableviton import get_batch, get_mask_location, tensor2img
22
 
23
  PROJECT_ROOT = Path(__file__).absolute().parents[1].absolute()
24
  sys.path.insert(0, str(PROJECT_ROOT))
25
 
 
 
 
 
 
 
 
 
26
  IMG_H = 512
27
  IMG_W = 384
28