Tokymin commited on
Commit
576ed22
1 Parent(s): b9644ff

更换path

Browse files
Files changed (1) hide show
  1. app.py +3 -1
app.py CHANGED
@@ -1,3 +1,5 @@
 
 
1
  import streamlit as st
2
  from transformers import AutoTokenizer, AutoModelForSequenceClassification
3
  import torch
@@ -20,7 +22,7 @@ else:
20
  # response = requests.post(API_URL, headers=headers, json=payload)
21
  # return response.json()
22
  # data = query("Can you please let us know more details about your ")
23
- path = os.path('Tokymin/Mood_Anxiety_Disorder_Classify_Model')
24
  tokenizer = AutoTokenizer.from_pretrained(path, cache_dir='/home/user', token=huggingface_token)
25
 
26
  # tokenizer = AutoTokenizer.from_pretrained('Tokymin/Mood_Anxiety_Disorder_Classify_Model')
 
1
+ from pathlib import Path
2
+
3
  import streamlit as st
4
  from transformers import AutoTokenizer, AutoModelForSequenceClassification
5
  import torch
 
22
  # response = requests.post(API_URL, headers=headers, json=payload)
23
  # return response.json()
24
  # data = query("Can you please let us know more details about your ")
25
+ path = Path('Tokymin/Mood_Anxiety_Disorder_Classify_Model')
26
  tokenizer = AutoTokenizer.from_pretrained(path, cache_dir='/home/user', token=huggingface_token)
27
 
28
  # tokenizer = AutoTokenizer.from_pretrained('Tokymin/Mood_Anxiety_Disorder_Classify_Model')