-
Notifications
You must be signed in to change notification settings - Fork 4
/
Makefile
30 lines (25 loc) · 912 Bytes
/
Makefile
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
.PHONY: test clean docs
# initially based on https://bit.ly/3rFergQ
# assume you have installed needed packages
export SPHINX_MOCK_REQUIREMENTS=1
# export PACKAGE_NAME=pytorch
clean:
# clean all temp runs
rm -rf $(shell find . -name "mlruns")
rm -rf $(shell find . -name "lightning_log")
rm -rf $(shell find . -name "lightning_logs")
rm -rf _ckpt_*
rm -rf .mypy_cache
rm -rf .pytest_cache
rm -rf ./docs/build
rm -rf ./docs/source/generated
rm -rf ./docs/source/*/generated
rm -rf ./docs/source/api
test: clean
pip install -r requirements/devel.txt
# run tests with coverage (cpu-only, running gpu standalone tests required for full coverage)
python -m coverage run --source src/finetuning_scheduler -m pytest src/finetuning_scheduler tests -v
python -m coverage report
docs: clean
pip install --quiet -r requirements/docs.txt
python -m sphinx -b html -W --keep-going docs/source docs/build