-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
48 lines (35 loc) · 1.46 KB
/
Makefile
File metadata and controls
48 lines (35 loc) · 1.46 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
PYTHON ?= python
CI_CHECK_PROOF_PACK ?= 1
.PHONY: install test ci-check serve codebook-benchmark context-benchmark vector-benchmark dense-baseline-benchmark route-benchmark resident-benchmark native proof-pack
install:
$(PYTHON) -m pip install -e .[dev]
native:
$(PYTHON) -c "from hyperquant.native_core import build_native_fwht; print(build_native_fwht(force=True))"
test:
pytest -q
ci-check:
$(PYTHON) -m compileall hyperquant
$(MAKE) native
$(MAKE) test
$(PYTHON) -m build
@if [ "$(CI_CHECK_PROOF_PACK)" = "1" ]; then \
tmp_dir="$$(mktemp -d)"; \
$(PYTHON) scripts/build_proof_pack.py --skip-tests --iterations 1 --warmup 0 --slice-iterations 1 --output-dir "$$tmp_dir/evidence"; \
rm -rf "$$tmp_dir"; \
fi
serve:
hyperquant serve --bundle bundle.npz --host 0.0.0.0 --port 8080
codebook-benchmark:
hyperquant codebook-benchmark --bundle bundle.npz --input demo.npy
context-benchmark:
hyperquant context-benchmark --input context_demo.npy --with-guarantee --fail-closed
vector-benchmark:
hyperquant vector-benchmark --input demo.npy
dense-baseline-benchmark:
hyperquant dense-baseline-benchmark --input demo.npy
route-benchmark:
hyperquant route-benchmark --markdown-output docs/evidence/route-benchmark.md --json-output docs/evidence/route-benchmark.json
resident-benchmark:
hyperquant resident-benchmark --markdown-output docs/evidence/resident-benchmark.md --json-output docs/evidence/resident-benchmark.json
proof-pack:
$(PYTHON) scripts/build_proof_pack.py