Repository navigation
Expand file tree
/
Copy pathMakefile
More file actions
55 lines (42 loc) · 1.58 KB
/
Copy pathMakefile
File metadata and controls
55 lines (42 loc) · 1.58 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
49
50
51
52
53
54
55
ENV=env-dev
TEST_ENV=env-dev
reset_env:
@hatch env prune
shell:
@hatch -v -e $(ENV) shell
styletest:
@echo "Style test:"
@hatch -e $(TEST_ENV) run env-test:ruff-test
@hatch -e $(TEST_ENV) run env-test:pycodestyle-test
@hatch -e $(TEST_ENV) run env-test:mypy-test
doctest:
@echo "Style test:"
@hatch -e $(TEST_ENV) run env-docs:doc-test
test: test_sk test_misc test_gen
lfstests:
@pytest -v ./tests/torch_tests/test_regularized_linear_exact.py -W ignore::FutureWarning
test_gen:
@echo "General tests:"
@hatch -e $(TEST_ENV) run env-test:test-custom
test_sk:
@echo "Sklearn tests:"
@hatch -e $(TEST_ENV) run env-test:test-sklearn
test_misc:
@echo "Solo tests:"
@hatch -e $(TEST_ENV) run env-test:test-misc
coverage:
@echo "Converage computation"
bash -O extglob -c 'coverage run -m pytest -v ./tests/torch_tests/!(test_regularized_linear_exact.py) -W ignore::FutureWarning'
coverage run -a -m pytest -v ./skwdro/tests -W ignore::FutureWarning
coverage run -a -m pytest -v ./tests/test_interfaces -W ignore::FutureWarning
coverage run -a -m pytest -v ./tests/dirac_test.py -W ignore::FutureWarning
coverage report
coverage html
coverage xml
genbadge coverage -i coverage.xml
epsilon_plotting_in_source:
mv skwdro/solvers/entropic_dual_torch.py skwdro/solvers/entropic_dual_torch.cp.py
mv skwdro/solvers/__entropic_dual_torch_epsilon.py skwdro/solvers/entropic_dual_torch.py
remove_epsilon_plotting_in_source:
mv skwdro/solvers/entropic_dual_torch.py skwdro/solvers/__entropic_dual_torch_epsilon.py
mv skwdro/solvers/entropic_dual_torch.cp.py skwdro/solvers/entropic_dual_torch.py