lvwerra HF staff commited on
Commit
c1066a5
1 Parent(s): b96d2de

Update Space (evaluate main: cf7f9820)

Browse files
Files changed (3) hide show
  1. README.md +1 -1
  2. perplexity.py +4 -4
  3. requirements.txt +1 -1
README.md CHANGED
@@ -72,7 +72,7 @@ results = perplexity.compute(model_id='gpt2',
72
  print(list(results.keys()))
73
  >>>['perplexities', 'mean_perplexity']
74
  print(round(results["mean_perplexity"], 2))
75
- >>>646.74
76
  print(round(results["perplexities"][0], 2))
77
  >>>32.25
78
  ```
 
72
  print(list(results.keys()))
73
  >>>['perplexities', 'mean_perplexity']
74
  print(round(results["mean_perplexity"], 2))
75
+ >>>646.75
76
  print(round(results["perplexities"][0], 2))
77
  >>>32.25
78
  ```
perplexity.py CHANGED
@@ -63,10 +63,10 @@ Examples:
63
  ... data=data) # doctest:+ELLIPSIS
64
  >>> print(list(results.keys()))
65
  ['perplexities', 'mean_perplexity']
66
- >>> print(round(results["mean_perplexity"], 2))
67
- 646.74
68
- >>> print(round(results["perplexities"][0], 2))
69
- 32.25
70
 
71
  Example 2:
72
  >>> from datasets import load_dataset
 
63
  ... data=data) # doctest:+ELLIPSIS
64
  >>> print(list(results.keys()))
65
  ['perplexities', 'mean_perplexity']
66
+ >>> print(round(results["mean_perplexity"], 0))
67
+ 647.0
68
+ >>> print(round(results["perplexities"][0], 0))
69
+ 32.0
70
 
71
  Example 2:
72
  >>> from datasets import load_dataset
requirements.txt CHANGED
@@ -1,3 +1,3 @@
1
- git+https://github.com/huggingface/evaluate@4487d9d1e65216a36b4aa94e3396a570f44a1525
2
  torch
3
  transformers
 
1
+ git+https://github.com/huggingface/evaluate@cf7f98201001c9ef673c49ffbcb8439e606e06a6
2
  torch
3
  transformers