Spaces:
Runtime error
Runtime error
Commit
·
fbecc81
1
Parent(s):
87968ca
Update app.py
Browse files
app.py
CHANGED
@@ -6,8 +6,8 @@ import os
|
|
6 |
import torch
|
7 |
from transformers import RobertaModel, AutoTokenizer
|
8 |
|
9 |
-
|
10 |
-
@st.cache(show_spinner=False, hash_funcs={RobertaModel:
|
11 |
def load():
|
12 |
text_encoder = RobertaModel.from_pretrained('SajjadAyoubi/clip-fa-text')
|
13 |
tokenizer = AutoTokenizer.from_pretrained('SajjadAyoubi/clip-fa-text')
|
|
|
6 |
import torch
|
7 |
from transformers import RobertaModel, AutoTokenizer
|
8 |
|
9 |
+
# @st.cache(hash_funcs={transformers.models.gpt2.tokenization_gpt2_fast.GPT2TokenizerFast: hash}, suppress_st_warning=True, allow_output_mutation=True)
|
10 |
+
@st.cache(show_spinner=False, hash_funcs={RobertaModel: hash, AutoTokenizer: hash})
|
11 |
def load():
|
12 |
text_encoder = RobertaModel.from_pretrained('SajjadAyoubi/clip-fa-text')
|
13 |
tokenizer = AutoTokenizer.from_pretrained('SajjadAyoubi/clip-fa-text')
|