Skip to content

Commit e00bd34

Browse files
committed
trying github integration
1 parent 85195c6 commit e00bd34

1 file changed

Lines changed: 65 additions & 0 deletions

File tree

.github/workflows/ci.yml

Lines changed: 65 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,65 @@
1+
name: CI
2+
3+
on:
4+
push:
5+
# Sequence of patterns matched against refs/heads
6+
branches:
7+
# Push events on main branch
8+
- main
9+
- master
10+
# Sequence of patterns matched against refs/tags
11+
tags: '*'
12+
13+
jobs:
14+
test:
15+
name: ${{ matrix.version }} - ${{ matrix.os }} - ${{ matrix.arch }} - ${{ github.event_name }}
16+
runs-on: ${{ matrix.os }}
17+
strategy:
18+
fail-fast: false
19+
matrix:
20+
version:
21+
- '1.8'
22+
os:
23+
- ubuntu-latest
24+
arch:
25+
- x64
26+
exclude:
27+
- os: macOS-latest
28+
arch: x86
29+
python-version: ["3.10"]
30+
steps:
31+
- uses: actions/checkout@v3
32+
with:
33+
submodules: 'true'
34+
- name: Set up Python
35+
uses: actions/setup-python@v4
36+
with:
37+
python-version: ${{ matrix.python-version }}
38+
- uses: conda-incubator/setup-miniconda@v2
39+
with:
40+
auto-update-conda: true
41+
python-version: ${{ matrix.python-version }}
42+
- name: Install dependencies
43+
shell: bash -el {0}
44+
run: |
45+
conda create -n faiss python=3.10
46+
conda activate faiss
47+
conda install -c pytorch faiss-cpu
48+
conda install matplotlib
49+
pip install h5py
50+
- name: Run benchmark
51+
shell: bash -el {0}
52+
run: |
53+
conda activate faiss
54+
python3 search/search.py --task task1
55+
python3 search/search.py --task task2
56+
python3 eval/eval.py res.csv
57+
python3 eval/plot.py --task task1 res.csv
58+
python3 eval/plot.py --task task2 res.csv
59+
- uses: actions/upload-artifact@v3
60+
with:
61+
name: Results
62+
path: |
63+
res.csv
64+
result_task1.png
65+
result_task2.png

0 commit comments

Comments
 (0)