Spaces:
Runtime error
Runtime error
Commit ·
d1991e8
1
Parent(s): f766440
Fix: Remove manual model device placement
Browse files
app.py
CHANGED
|
@@ -33,8 +33,6 @@ print("Preloading Allosaurus model...")
|
|
| 33 |
device = 'cuda' if torch.cuda.is_available() else 'cpu'
|
| 34 |
print(f"Using device: {device}")
|
| 35 |
MODEL = read_recognizer(alt_model_path=Path("/tmp/allosaurus_models"))
|
| 36 |
-
if device == 'cuda':
|
| 37 |
-
MODEL.model.to(device)
|
| 38 |
|
| 39 |
# Create a phoneme to viseme mapping dictionary for faster lookups
|
| 40 |
PHONEME_MAP = {}
|
|
|
|
| 33 |
device = 'cuda' if torch.cuda.is_available() else 'cpu'
|
| 34 |
print(f"Using device: {device}")
|
| 35 |
MODEL = read_recognizer(alt_model_path=Path("/tmp/allosaurus_models"))
|
|
|
|
|
|
|
| 36 |
|
| 37 |
# Create a phoneme to viseme mapping dictionary for faster lookups
|
| 38 |
PHONEME_MAP = {}
|