Nicous commited on
Commit
e91d552
·
verified ·
1 Parent(s): e619882

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -58,8 +58,8 @@ ego_gpt_path = hf_hub_download(
58
  # pretrained = "/mnt/sfs-common/jkyang/EgoGPT/checkpoints/EgoGPT-llavaov-7b-EgoIT-109k-release"
59
  # pretrained = "/mnt/sfs-common/jkyang/EgoGPT/checkpoints/EgoGPT-llavaov-7b-EgoIT-EgoLife-Demo"
60
  pretrained = 'EgoLife-v1/EgoGPT'
61
- device = "cuda"
62
- device_map = "cuda"
63
 
64
  # Add this initialization code before loading the model
65
  def setup(rank, world_size):
 
58
  # pretrained = "/mnt/sfs-common/jkyang/EgoGPT/checkpoints/EgoGPT-llavaov-7b-EgoIT-109k-release"
59
  # pretrained = "/mnt/sfs-common/jkyang/EgoGPT/checkpoints/EgoGPT-llavaov-7b-EgoIT-EgoLife-Demo"
60
  pretrained = 'EgoLife-v1/EgoGPT'
61
+ device = torch.device('cuda' if torch.cuda.is_available() else 'cpu')
62
+ device_map = torch.device('cuda' if torch.cuda.is_available() else 'cpu')
63
 
64
  # Add this initialization code before loading the model
65
  def setup(rank, world_size):