AhmedSSabir
commited on
Commit
•
f6e09cf
1
Parent(s):
4e74afc
Update app.py
Browse files
app.py
CHANGED
@@ -55,13 +55,13 @@ model = GPT2LMHeadModel.from_pretrained('gpt2', output_hidden_states = True, out
|
|
55 |
#tokenizer = gr.Interface.load('huggingface/distilgpt2')
|
56 |
|
57 |
#tokenizer = GPT2Tokenizer.from_pretrained('distilgpt2')
|
58 |
-
tokenizer = GPT2Tokenizer.from_pretrained('
|
59 |
#tokenizer = GPT2Tokenizer.from_pretrained('distilgpt2')
|
60 |
|
61 |
|
62 |
|
63 |
-
tokenizer = GPT2Tokenizer.from_pretrained('
|
64 |
-
model = GPT2LMHeadModel.from_pretrained('
|
65 |
|
66 |
def sentence_prob_mean(text):
|
67 |
# Tokenize the input text and add special tokens
|
|
|
55 |
#tokenizer = gr.Interface.load('huggingface/distilgpt2')
|
56 |
|
57 |
#tokenizer = GPT2Tokenizer.from_pretrained('distilgpt2')
|
58 |
+
tokenizer = GPT2Tokenizer.from_pretrained('distilgpt2')
|
59 |
#tokenizer = GPT2Tokenizer.from_pretrained('distilgpt2')
|
60 |
|
61 |
|
62 |
|
63 |
+
tokenizer = GPT2Tokenizer.from_pretrained('distilgpt2')
|
64 |
+
model = GPT2LMHeadModel.from_pretrained('distilgpt2')
|
65 |
|
66 |
def sentence_prob_mean(text):
|
67 |
# Tokenize the input text and add special tokens
|