-
Notifications
You must be signed in to change notification settings - Fork 6
/
Makefile
48 lines (37 loc) · 925 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
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
run: train inference
clean: delete-checkpoints delete-best_model
clean-run: clean run
setup: set-precommit set-style-dep set-git
style: set-style-dep set-style
quality: set-style-dep check-quality
##### run #####
train:
python code/train.py
inference:
python code/inference.py
all:
sh read_config.sh
##### clean #####
delete-checkpoints:
rm -rf results/*
delete-best_model:
rm -rf best_model/*
##### setup #####
set-git:
git config --local commit.template .gitmessage
set-precommit:
pip3 install pre-commit==2.17.0
pre-commit install
set-style-dep:
pip3 install isort==5.12.0 black==23.3.0 flake8==4.0.1
##### style ######
set-style:
black --config pyproject.toml .
isort --settings-path pyproject.toml .
##### quality #####
check-quality:
black --config pyproject.toml --check .
isort --settings-path pyproject.toml --check-only .
flake8 .
# Reference:
# https://github.com/monologg/python-template