ONNX
onnxruntime
onnx-mlir
quantization
fp32
File size: 1,575 Bytes
ed3aeeb
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
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
.PHONY: setup validate convert accuracy netron mlir mlir-graphs test-core test check

setup:
	./scripts/bootstrap_environment.sh

validate:
	PYTHONPATH=scripts .venv/bin/python scripts/validate_registry.py model_registry.csv --verify-files --require-complete
	.venv/bin/python scripts/validate_config_layout.py --output /tmp/graph_config_layout_validation.json

convert:
	.venv/bin/python scripts/run_batch.py --workers 4 --resume-failed $$(find configs/pipelines -name '*.json' -type f | sort)

accuracy:
	@run_dir=$$(mktemp -d /tmp/graph_accuracy_XXXXXX); \
	.venv/bin/python scripts/run_model_accuracy_summary.py --repo-root $$(pwd) --run-dir "$$run_dir" --python $$(pwd)/.venv/bin/python

netron:
	@run_dir=$$(mktemp -d /tmp/graph_netron_XXXXXX); \
	.venv/bin/python scripts/run_netron_checks.py --repo-root $$(pwd) --run-dir "$$run_dir"

mlir:
	.venv/bin/python scripts/run_mlir_batch.py --workers 4 --reuse-failures

mlir-graphs:
	.venv/bin/python scripts/build_ir_stage_coverage.py --repo-root $$(pwd)
	@run_dir=logs/graphs/mlir/make_$$(date -u +%Y%m%dT%H%M%SZ)_$$$$; \
	.venv/bin/python scripts/run_mlir_graph_checks.py --repo-root $$(pwd) --run-dir "$$run_dir"

test-core:
	.venv/bin/python -m pytest -q tests/test_config_layout.py tests/test_pipeline.py tests/test_mlir_batch.py tests/test_netron_exports.py tests/test_model_accuracy_summary.py tests/test_mlir_ir_graphs.py tests/test_mlir_graph_builder_resilience.py tests/test_validate_mlir_ir_graphs.py

test:
	.venv/bin/python -m pytest -q

check: validate test
	.venv/bin/python -m compileall -q scripts tests