File tree Expand file tree Collapse file tree 4 files changed +6
-11
lines changed Expand file tree Collapse file tree 4 files changed +6
-11
lines changed Original file line number Diff line number Diff line change 24
24
- name : Install dependencies
25
25
run : |
26
26
python -m pip install --upgrade pip
27
- python setup.py egg_info
28
- sed '/^$/q' src/lighteval.egg-info/requires.txt > src/lighteval.egg-info/requires_lite.txt
29
- python -m pip install ruff -c src/lighteval.egg-info/requires_lite.txt
30
- rm -rf src/lighteval.egg-info
27
+ python -m pip install ".[quality]"
31
28
- name : Code quality
32
29
run : |
33
30
make quality
Original file line number Diff line number Diff line change 26
26
cache : ' pip'
27
27
- name : Install lighteval in editable mode
28
28
run : |
29
- pip install -e .[accelerate ]
29
+ pip install -e .[dev ]
30
30
- name : Get cached files
31
31
uses : actions/cache@v2
32
32
id : get-cache
Original file line number Diff line number Diff line change @@ -62,7 +62,7 @@ and pasting your access token.
62
62
Lastly, if you intend to push to the code base, you'll need to install the precommit hook for styling tests:
63
63
64
64
``` bash
65
- pip install pre-commit
65
+ pip install .[dev]
66
66
pre-commit install
67
67
```
68
68
Original file line number Diff line number Diff line change @@ -54,8 +54,6 @@ dependencies = [
54
54
" torch>=2.0" ,
55
55
" GitPython==3.1.31" , # for logging
56
56
" datasets>=2.14.0" ,
57
- # Test
58
- " pytest==7.4.0" ,
59
57
# Prettiness
60
58
" termcolor==2.3.0" ,
61
59
" pytablewriter" ,
@@ -64,16 +62,13 @@ dependencies = [
64
62
" aenum==3.1.15" ,
65
63
# Base metrics
66
64
" nltk==3.8.1" ,
67
- " numpy" ,
68
65
" scikit-learn" ,
69
66
" spacy==3.7.2" ,
70
67
" sacrebleu" ,
71
68
" rouge_score==0.1.2" ,
72
69
" sentencepiece>=0.1.99" ,
73
70
" protobuf==3.20.*" , # pinned for sentencepiece compat
74
71
" pycountry" ,
75
- # Code style
76
- " ruff==v0.2.2" ,
77
72
]
78
73
79
74
[project .optional-dependencies ]
@@ -87,6 +82,9 @@ nanotron = [
87
82
" nanotron" ,
88
83
" tensorboardX"
89
84
]
85
+ quality = [" ruff==v0.2.2" ," pre-commit" ]
86
+ tests = [" pytest==7.4.0" ]
87
+ dev = [" lighteval[accelerate,quality,tests]" ]
90
88
91
89
92
90
[project .urls ]
You can’t perform that action at this time.
0 commit comments