Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
gaoqiong
lm-evaluation-harness
Commits
8558b8d4
Unverified
Commit
8558b8d4
authored
Dec 17, 2024
by
Baber Abbasi
Committed by
GitHub
Dec 17, 2024
Browse files
drop python 3.8 support (#2575)
* feat: drop Python 3.8 support * feat: drop Python 3.8 tests * pre-commit
parent
4c26a9c1
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
15 additions
and
12 deletions
+15
-12
.github/workflows/unit_tests.yml
.github/workflows/unit_tests.yml
+5
-5
lm_eval/decontamination/archiver.py
lm_eval/decontamination/archiver.py
+9
-6
pyproject.toml
pyproject.toml
+1
-1
No files found.
.github/workflows/unit_tests.yml
View file @
8558b8d4
...
@@ -22,10 +22,10 @@ jobs:
...
@@ -22,10 +22,10 @@ jobs:
steps
:
steps
:
-
name
:
Checkout Code
-
name
:
Checkout Code
uses
:
actions/checkout@v4
uses
:
actions/checkout@v4
-
name
:
Set up Python
3.
8
-
name
:
Set up Python
3.
9
uses
:
actions/setup-python@v5
uses
:
actions/setup-python@v5
with
:
with
:
python-version
:
3.
8
python-version
:
3.
9
cache
:
pip
cache
:
pip
cache-dependency-path
:
pyproject.toml
cache-dependency-path
:
pyproject.toml
-
name
:
Pre-Commit
-
name
:
Pre-Commit
...
@@ -42,7 +42,7 @@ jobs:
...
@@ -42,7 +42,7 @@ jobs:
runs-on
:
ubuntu-latest
runs-on
:
ubuntu-latest
strategy
:
strategy
:
matrix
:
matrix
:
python-version
:
[
"
3.8"
,
"
3.9"
,
"
3.10"
,
"
3.11"
]
python-version
:
[
"
3.9"
,
"
3.10"
,
"
3.11"
,
"
3.12"
]
timeout-minutes
:
30
timeout-minutes
:
30
steps
:
steps
:
-
name
:
Checkout Code
-
name
:
Checkout Code
...
@@ -75,10 +75,10 @@ jobs:
...
@@ -75,10 +75,10 @@ jobs:
steps
:
steps
:
-
name
:
Checkout Code
-
name
:
Checkout Code
uses
:
actions/checkout@v4
uses
:
actions/checkout@v4
-
name
:
Set up Python
3.
8
-
name
:
Set up Python
3.
9
uses
:
actions/setup-python@v5
uses
:
actions/setup-python@v5
with
:
with
:
python-version
:
3.
8
python-version
:
3.
9
cache
:
pip
cache
:
pip
cache-dependency-path
:
pyproject.toml
cache-dependency-path
:
pyproject.toml
-
name
:
Install dependencies
-
name
:
Install dependencies
...
...
lm_eval/decontamination/archiver.py
View file @
8558b8d4
...
@@ -110,12 +110,15 @@ class TextReader:
...
@@ -110,12 +110,15 @@ class TextReader:
def
read_tqdm
(
self
,
update_frequency
:
int
=
10000
):
def
read_tqdm
(
self
,
update_frequency
:
int
=
10000
):
current_file_position
=
0
current_file_position
=
0
line_counter
=
0
line_counter
=
0
with
open
(
self
.
file_path
,
"r"
,
encoding
=
"utf-8"
)
as
fh
,
tqdm
.
tqdm
(
with
(
open
(
self
.
file_path
,
"r"
,
encoding
=
"utf-8"
)
as
fh
,
tqdm
.
tqdm
(
total
=
os
.
path
.
getsize
(
self
.
file_path
),
total
=
os
.
path
.
getsize
(
self
.
file_path
),
dynamic_ncols
=
True
,
dynamic_ncols
=
True
,
unit
=
"byte"
,
unit
=
"byte"
,
unit_scale
=
1
,
unit_scale
=
1
,
)
as
progress
:
)
as
progress
,
):
with
mmap
.
mmap
(
fh
.
fileno
(),
length
=
0
,
access
=
mmap
.
ACCESS_READ
)
as
mmap_obj
:
with
mmap
.
mmap
(
fh
.
fileno
(),
length
=
0
,
access
=
mmap
.
ACCESS_READ
)
as
mmap_obj
:
for
line
in
iter
(
mmap_obj
.
readline
,
b
""
):
for
line
in
iter
(
mmap_obj
.
readline
,
b
""
):
line
=
line
.
decode
(
"utf-8"
)
line
=
line
.
decode
(
"utf-8"
)
...
...
pyproject.toml
View file @
8558b8d4
...
@@ -16,7 +16,7 @@ classifiers = [
...
@@ -16,7 +16,7 @@ classifiers = [
"License :: OSI Approved :: MIT License"
,
"License :: OSI Approved :: MIT License"
,
"Operating System :: OS Independent"
,
"Operating System :: OS Independent"
,
]
]
requires-python
=
">=3.
8
"
requires-python
=
">=3.
9
"
license
=
{
"text"
=
"MIT"
}
license
=
{
"text"
=
"MIT"
}
dependencies
=
[
dependencies
=
[
"accelerate>=0.26.0"
,
"accelerate>=0.26.0"
,
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment