videoNote / backend /app /utils /env_checker.py
zhoujiaangyao
deploy videomemo backend to HF Space
6cfe55f
Raw
History Blame Contribute Delete
278 Bytes
def is_cuda_available() -> bool:
try:
import torch
return torch.cuda.is_available()
except ImportError:
return False
def is_torch_installed() -> bool:
try:
import torch
return True
except ImportError:
return False