add autopep8 to Contributions guide (#852)

* add autopep8 to Contrib.

* simplify cmd

* update GH templates

* add pytest-flake8

* update GH template
This commit is contained in:
Jirka Borovec
2020-02-15 20:24:38 -05:00
committed by GitHub
parent 539d129178
commit 9f939447f2
7 changed files with 12 additions and 3 deletions
+4
View File
@@ -51,3 +51,7 @@ A lot of good work has already been done in project mechanics (requirements.txt,
## Coding Styleguide
1. Test the code with flake8.
2. Use f-strings.
3. run locally PEP8 fixes:
```
autopep8 -v -r --max-line-length 120 --in-place .
```
+3 -1
View File
@@ -2,14 +2,16 @@
name: Bug report
about: Create a report to help us improve
title: ''
labels: bug
labels: bug, help wanted
assignees: ''
---
<!--
### Common bugs:
1. Tensorboard not showing in Jupyter-notebook see [issue 79](https://github.com/PyTorchLightning/pytorch-lightning/issues/79).
2. PyTorch 1.1.0 vs 1.2.0 support [see FAQ](https://github.com/PyTorchLightning/pytorch-lightning#faq)
-->
## 🐛 Bug
+1 -1
View File
@@ -2,7 +2,7 @@
name: Typos and doc fixes
about: Typos and doc fixes
title: ''
labels: typo
labels: typo, documentation
assignees: ''
---
+1
View File
@@ -31,6 +31,7 @@ class CometLogger(LightningLoggerBase):
r"""
Log using `comet.ml <https://www.comet.ml>`_.
"""
def __init__(self, api_key=None, save_dir=None, workspace=None,
rest_api_key=None, project_name=None, experiment_name=None, **kwargs):
r"""
+1
View File
@@ -27,6 +27,7 @@ class NeptuneLogger(LightningLoggerBase):
Neptune logger can be used in the online mode or offline (silent) mode.
To log experiment data in online mode, NeptuneLogger requries an API key:
"""
def __init__(self, api_key=None, project_name=None, offline_mode=False,
experiment_name=None, upload_source_files=None,
params=None, properties=None, tags=None, **kwargs):
+1 -1
View File
@@ -862,7 +862,7 @@ class Trainer(TrainerIOMixin,
# check if we should run validation during training
self.disable_validation = ((self.num_val_batches == 0 or
not self.is_overriden('validation_step')) and
not self.is_overriden('validation_step')) and
not self.fast_dev_run)
# run tiny validation (if validation defined)
+1
View File
@@ -4,6 +4,7 @@ coverage
codecov
pytest>=3.0.5
pytest-cov
pytest-flake8
flake8
check-manifest
test-tube>=0.7.5