Sadjad Alikhani commited on
Commit
ca2a3f1
·
verified ·
1 Parent(s): 7a9b064

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -183,7 +183,7 @@ def process_hdf5_file(uploaded_file, percentage_idx):
183
  # Step 4: Load the model from lwm_model module
184
  device = 'cuda' if torch.cuda.is_available() else 'cpu'
185
  print(f"Loading the LWM model on {device}...")
186
- model = lwm_model.LWM.from_pretrained(device=device)
187
 
188
  # Step 5: Load the HDF5 file and extract the channels and labels
189
  with h5py.File(uploaded_file.name, 'r') as f:
 
183
  # Step 4: Load the model from lwm_model module
184
  device = 'cuda' if torch.cuda.is_available() else 'cpu'
185
  print(f"Loading the LWM model on {device}...")
186
+ model = lwm_model.LWM.from_pretrained(device=device).to(torch.float32)
187
 
188
  # Step 5: Load the HDF5 file and extract the channels and labels
189
  with h5py.File(uploaded_file.name, 'r') as f: