minko186 commited on
Commit
266b5b8
·
verified ·
1 Parent(s): 4fd751f

Update gptzero_free.py

Browse files
Files changed (1) hide show
  1. gptzero_free.py +5 -3
gptzero_free.py CHANGED
@@ -84,10 +84,12 @@ class GPT2PPL:
84
  print(f"Burstiness {max(Perplexity_per_line)}")
85
  results["Burstiness"] = max(Perplexity_per_line)
86
 
87
- out, label = self.getResults(results["Perplexity per line"])
88
- results["label"] = label
89
 
90
- return results, out
 
 
91
 
92
  def getPPL(self,sentence):
93
  encodings = self.tokenizer(sentence, return_tensors="pt")
 
84
  print(f"Burstiness {max(Perplexity_per_line)}")
85
  results["Burstiness"] = max(Perplexity_per_line)
86
 
87
+ # out, label = self.getResults(results["Perplexity per line"])
88
+ # results["label"] = label
89
 
90
+ # return results, out
91
+
92
+ return self.getResults(results["Perplexity per line"])
93
 
94
  def getPPL(self,sentence):
95
  encodings = self.tokenizer(sentence, return_tensors="pt")