[make] Create Makefile (#4620)
* [make] Create Makefile * exclude makefile * contributing info * rm .run_local_test.sh
This commit is contained in:
parent
396a18eb78
commit
79fc92647c
|
@ -182,10 +182,10 @@ python -m pip install ".[dev, examples]"
|
|||
python -m pip install pre-commit
|
||||
```
|
||||
|
||||
You can run the full test-case in your terminal via this bash script:
|
||||
You can run the full test-case in your terminal via this make script:
|
||||
|
||||
```bash
|
||||
bash .run_local_tests.sh
|
||||
make test
|
||||
```
|
||||
|
||||
Note: if your computer does not have multi-GPU nor TPU these tests are skipped.
|
||||
|
|
|
@ -1,14 +0,0 @@
|
|||
#!/usr/bin/env bash
|
||||
|
||||
# install APEX, see https://github.com/NVIDIA/apex#linux
|
||||
# to imitate SLURM set only single node
|
||||
export SLURM_LOCALID=0
|
||||
|
||||
# use this to run tests
|
||||
rm -rf _ckpt_*
|
||||
rm -rf ./lightning_logs
|
||||
python -m coverage run --source pytorch_lightning -m py.test pytorch_lightning tests pl_examples -v --flake8
|
||||
python -m coverage report -m
|
||||
|
||||
# specific file
|
||||
# python -m coverage run --source pytorch_lightning -m py.test --flake8 --durations=0 -v -k
|
|
@ -57,6 +57,9 @@ exclude *.yaml
|
|||
# Exclude pyright config
|
||||
exclude .pyrightconfig.json
|
||||
|
||||
# Exclude Makefile
|
||||
exclude Makefile
|
||||
|
||||
prune .git
|
||||
prune .github
|
||||
prune .circleci
|
||||
|
|
|
@ -0,0 +1,15 @@
|
|||
.PHONY: test
|
||||
|
||||
test:
|
||||
# install APEX, see https://github.com/NVIDIA/apex#linux
|
||||
# to imitate SLURM set only single node
|
||||
export SLURM_LOCALID=0
|
||||
|
||||
# use this to run tests
|
||||
rm -rf _ckpt_*
|
||||
rm -rf ./lightning_logs
|
||||
python -m coverage run --source pytorch_lightning -m pytest pytorch_lightning tests pl_examples -v --flake8
|
||||
python -m coverage report -m
|
||||
|
||||
# specific file
|
||||
# python -m coverage run --source pytorch_lightning -m py.test --flake8 --durations=0 -v -k
|
Loading…
Reference in New Issue