-
Notifications
You must be signed in to change notification settings - Fork 1
/
Makefile
45 lines (35 loc) · 1.35 KB
/
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
# copied from https://github.com/ashleve/lightning-hydra-template/edit/main/Makefile
help: ## Show help
@grep -E '^[.a-zA-Z_-]+:.*?## .*$$' $(MAKEFILE_LIST) | awk 'BEGIN {FS = ":.*?## "}; {printf "\033[36m%-30s\033[0m %s\n", $$1, $$2}'
clean: ## Clean autogenerated files
rm -rf dist
find . -type f -name "*.DS_Store" -ls -delete
find . | grep -E "(__pycache__|\.pyc|\.pyo)" | xargs rm -rf
find . | grep -E ".pytest_cache" | xargs rm -rf
find . | grep -E ".ipynb_checkpoints" | xargs rm -rf
rm -f .coverage
format: ## Run pre-commit hooks
poetry run pre-commit run -a
sync: ## Merge changes from main branch to your current branch
git pull
git pull origin main
test: ## Run not slow tests
poetry run pytest -v
test-full: ## Run all tests
poetry run pytest -v --slow
train: ## Train the model
python src/train.py
docker-build: ## Building Docker Image
docker build . -t speech-generation:latest --no-cache
docker-run:
docker run -it \
--gpus all \
--mount type=volume,source=speech-generation,target=/workspace \
speech-generation:latest
docker-run-mount:
docker run -it \
--gpus all \
--mount type=volume,source=speech-generation,target=/workspace \
--mount type=bind,source="${PWD}/data",target=/workspace/data \
--mount type=bind,source="${PWD}/logs",target=/workspace/logs \
speech-generation:latest