wangpangintsig commited on
Commit
0809be0
·
verified ·
1 Parent(s): c25fc46

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -49,7 +49,7 @@ def run_t5_and_save(text):
49
  print(f"使用设备: {device}")
50
  t5 = load_t5(device, max_length=512)
51
  embeddings = t5([text])
52
- output_path = "/home/user/embeddings.pt"
53
  torch.save(embeddings, output_path)
54
  return f"嵌入形状: {embeddings.shape}", output_path
55
  except Exception as e:
 
49
  print(f"使用设备: {device}")
50
  t5 = load_t5(device, max_length=512)
51
  embeddings = t5([text])
52
+ output_path = "/tmp/embeddings.pt"
53
  torch.save(embeddings, output_path)
54
  return f"嵌入形状: {embeddings.shape}", output_path
55
  except Exception as e: