Skip to content

Commit 8f1a37d

Browse files
committed
ci: run integrations
1 parent 0e329c0 commit 8f1a37d

File tree

2 files changed

+13
-8
lines changed

2 files changed

+13
-8
lines changed

.github/workflows/ci.yml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,5 +18,7 @@ jobs:
1818
run: |
1919
python -m pip install --upgrade pip
2020
pip install -r requirements-dev.txt
21-
- name: Run tests
21+
- name: Run tests (skip GPU sampling)
22+
env:
23+
LLM_BENCH_SKIP_GPU: '1'
2224
run: make test

benches/monitor.py

Lines changed: 10 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -11,16 +11,19 @@
1111
psutil = None # type: ignore
1212
_PS_OK = False
1313

14-
try:
15-
import pynvml
14+
_NV_OK = False
15+
pynvml = None
16+
if not (os.environ.get('LLM_BENCH_SKIP_GPU') == '1'):
1617
try:
17-
pynvml.nvmlInit()
18-
_NV_OK = True
18+
import pynvml
19+
try:
20+
pynvml.nvmlInit()
21+
_NV_OK = True
22+
except Exception:
23+
_NV_OK = False
1924
except Exception:
25+
pynvml = None # type: ignore
2026
_NV_OK = False
21-
except Exception:
22-
pynvml = None # type: ignore
23-
_NV_OK = False
2427

2528

2629
@dataclass

0 commit comments

Comments
 (0)