Spaces:
Runtime error
Runtime error
Test
Browse files
musetalk/utils/preprocessing.py
CHANGED
|
@@ -19,7 +19,7 @@ checkpoint_file = './models/dwpose/dw-ll_ucoco_384.pth'
|
|
| 19 |
model = init_model(config_file, checkpoint_file, device=device)
|
| 20 |
|
| 21 |
# initialize the face detection model
|
| 22 |
-
device = "cuda"
|
| 23 |
fa = FaceAlignment(LandmarksType._2D, flip_input=False,device=device)
|
| 24 |
|
| 25 |
# maker if the bbox is not sufficient
|
|
|
|
| 19 |
model = init_model(config_file, checkpoint_file, device=device)
|
| 20 |
|
| 21 |
# initialize the face detection model
|
| 22 |
+
device = "cuda" if torch.cuda.is_available() else "cpu"
|
| 23 |
fa = FaceAlignment(LandmarksType._2D, flip_input=False,device=device)
|
| 24 |
|
| 25 |
# maker if the bbox is not sufficient
|