Update app.py
Browse files
app.py
CHANGED
@@ -98,7 +98,8 @@ if __name__ == '__main__':
|
|
98 |
server_name = args.server_name or ('0.0.0.0' if args.local_network else '127.0.0.1')
|
99 |
weights_path = args.weights
|
100 |
|
101 |
-
args.device =
|
|
|
102 |
# Load the model
|
103 |
model = AsymmetricMASt3R.from_pretrained(weights_path).to(args.device)
|
104 |
chkpt_tag = hash_md5(weights_path)
|
|
|
98 |
server_name = args.server_name or ('0.0.0.0' if args.local_network else '127.0.0.1')
|
99 |
weights_path = args.weights
|
100 |
|
101 |
+
args.device = "cuda" if torch.cuda.is_availble() else "cpu"
|
102 |
+
|
103 |
# Load the model
|
104 |
model = AsymmetricMASt3R.from_pretrained(weights_path).to(args.device)
|
105 |
chkpt_tag = hash_md5(weights_path)
|