Skip to content

Commit

Permalink
Squashed commit of the following:
Browse files Browse the repository at this point in the history
commit f374782c65ff01f9814457c707b214698b0f27c6
Author: gianscarpe <gianluca@scarpellini.dev>
Date:   Tue Dec 15 18:28:21 2020 +0100

    Rebasing onto master

commit 84bb9db
Author: Jirka Borovec <Borda@users.noreply.github.com>
Date:   Mon Dec 14 22:46:14 2020 +0100

    simplify changelog (Lightning-AI#5135)

commit 69123af
Author: Tadej Svetina <tadej.svetina@gmail.com>
Date:   Mon Dec 14 20:13:58 2020 +0100

    Fix hanging metrics tests (Lightning-AI#5134)

commit eb9cb3c
Author: Shachar Mirkin <shacharmirkin@gmail.com>
Date:   Mon Dec 14 13:39:29 2020 +0100

    Add Google Colab badges (Lightning-AI#5111)

    * Add colab badges to notebook

    Add colab badges to notebook to notebooks 4 & 5

    * Add colab badges

    Co-authored-by: chaton <thomas@grid.ai>

commit 0327f6b
Author: Carlos Mocholí <carlossmocholi@gmail.com>
Date:   Mon Dec 14 08:38:10 2020 +0100

    Do not warn when the name key is used in the lr_scheduler dict (Lightning-AI#5057)

    * Do not warn when the name key is used

    * Missing line

    * Consistency

    * Update pytorch_lightning/callbacks/lr_monitor.py

    * Update docs

    * Update pytorch_lightning/core/lightning.py

    Co-authored-by: Rohit Gupta <rohitgr1998@gmail.com>

    * Update CHANGELOG

    Co-authored-by: Rohit Gupta <rohitgr1998@gmail.com>

commit 16feb51
Author: tarepan <tarepan5884@gmail.com>
Date:   Mon Dec 14 01:13:50 2020 +0900

    Refactor load in checkpoint connector (Lightning-AI#4593)

    * Refactor load step commentaries

    * Refactor hpc ckpt suffix acquisition

    * Refactor restore/hpc_load match

    * Refactor hpc load trial

    * Refactor checkpoint dir check

    * Refactor unneeded function nest

    * Refactor nested If

    * Refactor duplicated cache clear

    * Refactor attempt flow with if/elif

    * Fix pip8

    * Refactor hook commentary

    Co-authored-by: chaton <thomas@grid.ai>

    * Fix pep8

    * Refactor hpc load checkpoint path acquisition

    * Fix pip8

    * Fix doc

    Co-authored-by: Adrian Wälchli <aedu.waelchli@gmail.com>

    * Refactor None Union type with Optional

    Co-authored-by: chaton <thomas@grid.ai>
    Co-authored-by: Adrian Wälchli <aedu.waelchli@gmail.com>
    Co-authored-by: Jirka Borovec <Borda@users.noreply.github.com>
    Co-authored-by: Roger Shieh <sh.rog@protonmail.ch>

commit 398f122
Author: Carlos Mocholí <carlossmocholi@gmail.com>
Date:   Sun Dec 13 16:04:16 2020 +0100

    Improve some tests (Lightning-AI#5049)

    * Improve some tests

    * Add TrainerState asserts

    Co-authored-by: Roger Shieh <sh.rog@protonmail.ch>

commit a49291d
Author: Jirka Borovec <Borda@users.noreply.github.com>
Date:   Sat Dec 12 17:21:19 2020 +0100

    drop unused test with result api (Lightning-AI#5058)

    Co-authored-by: chaton <thomas@grid.ai>
    Co-authored-by: Rohit Gupta <rohitgr1998@gmail.com>

commit b50ad9e
Author: Jirka Borovec <Borda@users.noreply.github.com>
Date:   Sat Dec 12 15:55:11 2020 +0100

    split tests for deprecated api (Lightning-AI#5071)

    * imports

    * imports

    * flake8

    Co-authored-by: Rohit Gupta <rohitgr1998@gmail.com>

commit 3100b78
Author: Rohit Gupta <rohitgr1998@gmail.com>
Date:   Sat Dec 12 15:47:03 2020 +0530

    Allow any input in to_onnx and to_torchscript (Lightning-AI#4378)

    * branch merge

    * sample

    * update with valid input tensors

    * pep

    * pathlib

    * Updated with BoringModel and added more input types

    * try fix

    * pep

    * skip test with torch < 1.4

    * fix test

    * Apply suggestions from code review

    * update tests

    * Allow any input in to_onnx and to_torchscript

    * Update tests/models/test_torchscript.py

    Co-authored-by: Adrian Wälchli <aedu.waelchli@gmail.com>

    * no_grad

    * try fix random failing test

    * rm example_input_array

    * rm example_input_array

    Co-authored-by: chaton <thomas@grid.ai>
    Co-authored-by: Jeff Yang <ydcjeff@outlook.com>
    Co-authored-by: Roger Shieh <sh.rog@protonmail.ch>
    Co-authored-by: Jirka Borovec <Borda@users.noreply.github.com>
    Co-authored-by: Adrian Wälchli <aedu.waelchli@gmail.com>
    Co-authored-by: edenlightning <66261195+edenlightning@users.noreply.github.com>

commit b5a2afd
Author: Roger Shieh <sh.rog@protonmail.ch>
Date:   Sat Dec 12 15:14:17 2020 +0800

    Remove beta arg from F1 class and functional (Lightning-AI#5076)

    * remove beta from F1

    * remove from functional

    Co-authored-by: Teddy Koker <teddy.koker@gmail.com>

commit 0de43d1
Author: Roger Shieh <sh.rog@protonmail.ch>
Date:   Sat Dec 12 14:23:55 2020 +0800

    Fix docs metrics formatting (Lightning-AI#5077)

    * fix functional f1 fbeta formatting

    * Update f_beta.py

    * remove line breaks

    * Update f_beta.py

    add line breaks and pad

    * pad linea breaks with 2 spaces instead of tab

commit d38e4d1
Author: skhiuk <38586033+Shumpei-Kikuta@users.noreply.github.com>
Date:   Sat Dec 12 14:00:32 2020 +0900

    fix: MNIST minor bug (Lightning-AI#5075)

    Co-authored-by: Roger Shieh <sh.rog@protonmail.ch>

commit 5f34f2b
Author: edenlightning <66261195+edenlightning@users.noreply.github.com>
Date:   Fri Dec 11 20:42:04 2020 -0500

    Update installation instructions for FairScale (Lightning-AI#5099)

    Co-authored-by: Jirka Borovec <Borda@users.noreply.github.com>

commit 63fb7f9
Author: Jirka Borovec <Borda@users.noreply.github.com>
Date:   Sat Dec 12 00:17:19 2020 +0100

    CI: upload report only on failer (Lightning-AI#5086)

    * CI: upload report only on failer

    * Apply suggestions from code review

    Co-authored-by: chaton <thomas@grid.ai>

    * Apply suggestions from code review

    Co-authored-by: chaton <thomas@grid.ai>
    Co-authored-by: Roger Shieh <sh.rog@protonmail.ch>
    Co-authored-by: Rohit Gupta <rohitgr1998@gmail.com>

commit 1e501f0
Author: Jirka Borovec <Borda@users.noreply.github.com>
Date:   Fri Dec 11 22:56:19 2020 +0100

    add back compatibility for deprecated metrics 2/n (Lightning-AI#5068)

    * add back compatibility for deprecated metrics

    * fix

    * imports

    * imports

commit 4a3f906
Author: Jirka Borovec <Borda@users.noreply.github.com>
Date:   Fri Dec 11 22:11:21 2020 +0100

    add back compatibility for deprecated metrics 1/n (Lightning-AI#5067)

    * add back compatibility for metrics

    * tests

    * Add deprecated metric utility functions back to functional (Lightning-AI#5062)

    * add back *deprecated* metric utility functions to functional

    * pep

    * pep

    * suggestions

    * move

    Co-authored-by: Jirka Borovec <jirka.borovec@seznam.cz>

    * more

    * fix

    * import

    * docs

    * tests

    * fix

    Co-authored-by: Teddy Koker <teddy.koker@gmail.com>

commit ddc3757
Author: chaton <thomas@grid.ai>
Date:   Fri Dec 11 21:21:25 2020 +0100

    Pre release (Lightning-AI#5098)

    * add rc release

    * update changelog

    * Update CHANGELOG.md

    * Update CHANGELOG.md

    Co-authored-by: Rohit Gupta <rohitgr1998@gmail.com>

commit 1a970b2
Author: chaton <thomas@grid.ai>
Date:   Fri Dec 11 20:24:59 2020 +0100

    [hotfix] Extend Optimizer + update doc (Lightning-AI#5095)

    * resolve urgent bug

    * update pr

    * update doc

    * update

    * remove typo

    * add defaults

    * Update pytorch_lightning/__init__.py

    * Update setup.py

    * update doc

    * Update docs/source/optimizers.rst

    Co-authored-by: Jirka Borovec <Borda@users.noreply.github.com>

    * update

    * resolve doc

    * debug test

    * update test

    * Update docs/source/optimizers.rst

    Co-authored-by: Adrian Wälchli <aedu.waelchli@gmail.com>

    * Update docs/source/optimizers.rst

    Co-authored-by: Adrian Wälchli <aedu.waelchli@gmail.com>

    * Update docs/source/optimizers.rst

    Co-authored-by: Adrian Wälchli <aedu.waelchli@gmail.com>

    * remove useless import

    * Update docs/source/optimizers.rst

    Co-authored-by: Jirka Borovec <Borda@users.noreply.github.com>
    Co-authored-by: Adrian Wälchli <aedu.waelchli@gmail.com>

commit 74171ef
Author: Jirka Borovec <Borda@users.noreply.github.com>
Date:   Fri Dec 11 18:42:53 2020 +0100

    drop duplicate metrics (Lightning-AI#5014)

    * drop duplicate metrics

    * keep

    * fix

commit 7755572
Author: chaton <thomas@grid.ai>
Date:   Fri Dec 11 14:51:45 2020 +0100

    Check if optimizer supports closure (Lightning-AI#4981)

    * check if optimizer support closure

    * cleanup test

    * resolve tests

    * resolve flake

    * update test due to patch limit

    * update

    * update dep

    * Update tests/core/test_lightning_optimizer.py

    Co-authored-by: Rohit Gupta <rohitgr1998@gmail.com>

    * Update tests/core/test_lightning_optimizer.py

    Co-authored-by: Rohit Gupta <rohitgr1998@gmail.com>

    * resolve bug

    * update test

    * resolve tests

    * Update requirements/extra.txt

    Co-authored-by: Jirka Borovec <Borda@users.noreply.github.com>

    * remove bolts dep

    * remove bolts

    * add missing bolts dep for tests

    * remove need for bolts

    Co-authored-by: Rohit Gupta <rohitgr1998@gmail.com>
    Co-authored-by: Jirka Borovec <Borda@users.noreply.github.com>

commit 4e6a871
Author: Rohit Gupta <rohitgr1998@gmail.com>
Date:   Fri Dec 11 15:07:32 2020 +0530

    Added CHANGELOG section (Lightning-AI#5065)

commit 7e8673d
Author: Alan Du <alanhdu@gmail.com>
Date:   Thu Dec 10 12:26:02 2020 -0500

    Update DDP docs (Lightning-AI#5046)

    * Fix flake8 error to fix CI

    * Correct weights-loading to use correct callbacks

    * Fix dangling links

    Co-authored-by: chaton <thomas@grid.ai>
    Co-authored-by: Jirka Borovec <Borda@users.noreply.github.com>

commit 2c3d43d
Author: chaton <thomas@grid.ai>
Date:   Thu Dec 10 15:24:44 2020 +0100

    Initialize trainer with None in DDPAccelerator (Lightning-AI#4915)

    * Initialize trainer with None

    * add typing to all accelerators

    * resolve imports

    * update

    * add typing

    * removed typo

    * update

    * Fix formatting and imports in accelerator

    Co-authored-by: maxjeblick <maxjeblick@users.noreply.github.com>
    Co-authored-by: Sean Naren <sean.narenthiran@gmail.com>
    Co-authored-by: SeanNaren <sean@grid.ai>
    Co-authored-by: Roger Shieh <sh.rog@protonmail.ch>

commit d5fa02e
Author: Jirka Borovec <Borda@users.noreply.github.com>
Date:   Thu Dec 10 14:06:13 2020 +0100

    simplify accelerator steps (Lightning-AI#5015)

    * simplify accelerator steps

    * Apply suggestions from code review

    Co-authored-by: Rohit Gupta <rohitgr1998@gmail.com>

    Co-authored-by: Rohit Gupta <rohitgr1998@gmail.com>

commit 820d5c7
Author: Hemil Desai <hemil.desai10@gmail.com>
Date:   Thu Dec 10 16:26:18 2020 +0530

    Add a notebook example to reach a quick baseline of ~94% accuracy on CIFAR (Lightning-AI#4818)

    * Add a notebook example to reach a quick baseline of ~94% accuracy on CIFAR10 using Resnet in Lightning

    * Remove outputs

    * PR Feedback

    * some changes

    * some more changes

    Co-authored-by: chaton <thomas@grid.ai>
    Co-authored-by: rohitgr7 <rohitgr1998@gmail.com>

commit 4ebce38
Author: Jirka Borovec <Borda@users.noreply.github.com>
Date:   Thu Dec 10 11:01:33 2020 +0100

    update usage of deprecated automatic_optimization (Lightning-AI#5011)

    * drop deprecated usage automatic_optimization

    * Apply suggestions from code review

    Co-authored-by: Adrian Wälchli <aedu.waelchli@gmail.com>

    * Apply suggestions from code review

    Co-authored-by: Rohit Gupta <rohitgr1998@gmail.com>

    Co-authored-by: Adrian Wälchli <aedu.waelchli@gmail.com>
    Co-authored-by: Rohit Gupta <rohitgr1998@gmail.com>

commit 77fb425
Author: Jirka Borovec <Borda@users.noreply.github.com>
Date:   Thu Dec 10 08:38:14 2020 +0100

    update usage of deprecated profiler (Lightning-AI#5010)

    * drop deprecated profiler

    * lut

    Co-authored-by: Roger Shieh <sh.rog@protonmail.ch>

commit cdbddbe
Author: Jirka Borovec <Borda@users.noreply.github.com>
Date:   Thu Dec 10 01:52:39 2020 +0100

    release 1.1.0 (Lightning-AI#5048)

    * release 1.1.0

    * pep8

commit 05f25f3
Author: Jirka Borovec <Borda@users.noreply.github.com>
Date:   Wed Dec 9 20:14:34 2020 +0100

    update usage of deprecated checkpoint_callback (Lightning-AI#5006)

    * drop usage of deprecated checkpoint_callback

    * fix

    * fix

commit ce91795
Author: Jirka Borovec <Borda@users.noreply.github.com>
Date:   Wed Dec 9 20:13:57 2020 +0100

    ref: clean config [1/n] add intermediate setters (Lightning-AI#4990)

    * add intermediate setters

    * show inputs

    * fix options

    * move

    * fix

    * less talk

    * fix

    * talk less

    * str

    * cases

    * rename

    Co-authored-by: chaton <thomas@grid.ai>

commit 068502f
Author: Francisco J. H. Heras <fjhheras@gmail.com>
Date:   Wed Dec 9 19:13:13 2020 +0000

    Loss format from .3f to .3g in the tqdm (Lightning-AI#4972)

    Co-authored-by: Jirka Borovec <Borda@users.noreply.github.com>

commit bcbba3b
Author: Rohit Gupta <rohitgr1998@gmail.com>
Date:   Thu Dec 10 00:42:44 2020 +0530

    Simplify GPU and TPU accelerator (Lightning-AI#5024)

commit 90d1d9f
Author: Jirka Borovec <Borda@users.noreply.github.com>
Date:   Wed Dec 9 19:05:12 2020 +0100

    drop deprecated reorder from AUC (Lightning-AI#5004)

    * drop deprecated reorder from AUC

    * chlog

    * fix

    * fix

    * simple

    * fix

    * fix

    * fix

    Co-authored-by: Roger Shieh <sh.rog@protonmail.ch>

commit 20b806a
Author: chaton <thomas@grid.ai>
Date:   Wed Dec 9 16:31:18 2020 +0000

    [feat] 3/n pp (Lightning-AI#5036)

    * add pp doc

    * udpate doc

    * update doc

    * update doc

    * Update docs

    * update doc

    * udpate

    * update doc

    * update doc

    * Formatting, update sharded zip link

    * Update docs/source/multi_gpu.rst

    Co-authored-by: Carlos Mocholí <carlossmocholi@gmail.com>

    * Apply suggestions from code review

    * Reference directly to section

    Co-authored-by: SeanNaren <sean@grid.ai>
    Co-authored-by: Carlos Mocholí <carlossmocholi@gmail.com>
    Co-authored-by: Jirka Borovec <Borda@users.noreply.github.com>

commit 69725ad
Author: Carlos Mocholí <carlossmocholi@gmail.com>
Date:   Wed Dec 9 16:48:46 2020 +0100

    Add carmocca to core (Lightning-AI#5038)

    Co-authored-by: Roger Shieh <sh.rog@protonmail.ch>
    Co-authored-by: Jirka Borovec <Borda@users.noreply.github.com>

commit cff2489
Author: Jirka Borovec <Borda@users.noreply.github.com>
Date:   Wed Dec 9 15:53:49 2020 +0100

    fix GH release badges (Lightning-AI#5040)

    * fix GH release badges

    * rtd

commit ef8ef12
Author: chaton <thomas@grid.ai>
Date:   Wed Dec 9 12:56:51 2020 +0000

    [feat] pp 2/n (Lightning-AI#5026)

    * Added changes for RPC plugin

    * Add missing kwargs

    * Fix code format

    * Loading refactors by introducing is_distributed var, fix optimizer step flow

    * Add rpc guard

    * Added docstrings and typing

    * resolve comments

    * Add additional rpc hook, refactor name of exit process hook for clarity

    * remove annotation

    * Modify behaviour to allow optional return, add test for rpc plugin

    * resolve tests

    * rename is_ddp_based

    * update

    * update for windows

    * update

    * resolve test

    * code smell

    * Added sequential plugin

    * resolve bug

    * update

    * cleanup

    * add Exception

    * resolve docs

    * Remove ddp support

    * Revert distributed -> ddp

    * Update pl_examples/basic_examples/conv_sequential_example.py

    Co-authored-by: Jirka Borovec <Borda@users.noreply.github.com>

    * Update pl_examples/basic_examples/conv_sequential_example.py

    Co-authored-by: Jirka Borovec <Borda@users.noreply.github.com>

    * Update pytorch_lightning/plugins/ddp_sequential_plugin.py

    Co-authored-by: Jirka Borovec <Borda@users.noreply.github.com>

    * Address code review points

    * Update pytorch_lightning/plugins/ddp_sequential_plugin.py

    Co-authored-by: Jirka Borovec <Borda@users.noreply.github.com>

    * Update pytorch_lightning/plugins/ddp_sequential_plugin.py

    Co-authored-by: Jirka Borovec <Borda@users.noreply.github.com>

    * Add missing return

    * Fix formatting, add datamodule args

    * add small comment

    * resolve comments

    * resolve comments

    * update source for fairscale

    * update extras

    * remove staticmethod

    * resolve flake8

    * Skip tests that are failing due to bug upstream with multiple optimizers and shard

    * update

    * update on comments

    * clean test

    * latest comments

    * remove old comments

    * add todo

    * Update version

    * update

    * resolve bugs

    * resolve bugs

    * update test

    * remove hanging test

    * Update pytorch_lightning/plugins/ddp_sequential_plugin.py

    Co-authored-by: Carlos Mocholí <carlossmocholi@gmail.com>

    * resolve on comments

    * Update pytorch_lightning/plugins/ddp_sequential_plugin.py

    Co-authored-by: Carlos Mocholí <carlossmocholi@gmail.com>

    * resolve on comments

    * Update pytorch_lightning/plugins/ddp_sequential_plugin.py

    Co-authored-by: Carlos Mocholí <carlossmocholi@gmail.com>

    * Update pytorch_lightning/plugins/ddp_sequential_plugin.py

    Co-authored-by: Carlos Mocholí <carlossmocholi@gmail.com>

    * Update pytorch_lightning/plugins/ddp_sequential_plugin.py

    Co-authored-by: Carlos Mocholí <carlossmocholi@gmail.com>

    * Update pytorch_lightning/plugins/ddp_sequential_plugin.py

    Co-authored-by: Carlos Mocholí <carlossmocholi@gmail.com>

    * remove ImportError

    Co-authored-by: SeanNaren <sean@grid.ai>
    Co-authored-by: Sean Naren <sean.narenthiran@gmail.com>
    Co-authored-by: Jirka Borovec <Borda@users.noreply.github.com>
    Co-authored-by: Carlos Mocholí <carlossmocholi@gmail.com>

commit 7d9784e
Author: Jirka Borovec <Borda@users.noreply.github.com>
Date:   Wed Dec 9 12:53:37 2020 +0100

    adding missing changelogs (Lightning-AI#5019)

    * adding missing changelogs

    * Apply suggestions from code review

    Co-authored-by: Rohit Gupta <rohitgr1998@gmail.com>

    * Apply suggestions from code review

    Co-authored-by: Adrian Wälchli <aedu.waelchli@gmail.com>

    Co-authored-by: Rohit Gupta <rohitgr1998@gmail.com>
    Co-authored-by: Adrian Wälchli <aedu.waelchli@gmail.com>

commit 6a99d95
Author: Jirka Borovec <Borda@users.noreply.github.com>
Date:   Wed Dec 9 11:53:22 2020 +0100

    fix ci: release (Lightning-AI#5037)

commit e2c404b
Author: Jirka Borovec <Borda@users.noreply.github.com>
Date:   Wed Dec 9 10:59:44 2020 +0100

    CI: update badges for release (Lightning-AI#5002)

    * fix images

    * not sleep

    * a0

    * path

    * assets

    * assets

    * bitecode

    * rls

    * rls

    * badges

    * fix

    * org

    * drop

    * clean

    * codecov

    * fix

    * clean

commit 53d7c95
Author: Jirka Borovec <Borda@users.noreply.github.com>
Date:   Wed Dec 9 09:18:23 2020 +0100

    drop usage of deprecated distributed_backend (Lightning-AI#5009)

    Co-authored-by: chaton <thomas@grid.ai>
    Co-authored-by: Roger Shieh <sh.rog@protonmail.ch>

commit 2c11d96
Author: Jirka Borovec <Borda@users.noreply.github.com>
Date:   Wed Dec 9 03:57:11 2020 +0100

    replace pyright by mypy (Lightning-AI#5021)

    * drop pyright & add mypy

    * detail

    * name

    * fix

    * flake8

    * ver

    Co-authored-by: Sean Naren <sean.narenthiran@gmail.com>

commit 127454a
Author: Ananya Harsh Jha <ananya@pytorchlightning.ai>
Date:   Tue Dec 8 18:20:01 2020 -0500

    All gatherwith grads (Lightning-AI#5012)

    * all_gather

    * ddp

    * horovod

    * grad tests

    * fixed ddp

    * ddp fixed, removed tpu, horovod for now

    * changelog

    * windows fix

    * windows fix

    * removed batch from ctx

    * all_gather

    * ddp

    * horovod

    * grad tests

    * fixed ddp

    * ddp fixed, removed tpu, horovod for now

    * changelog

    * windows fix

    * windows fix

    * removed batch from ctx

    * removed code duplication

    * merge

    Co-authored-by: Jirka Borovec <Borda@users.noreply.github.com>

commit ee9b3fe
Author: Sean Naren <sean.narenthiran@gmail.com>
Date:   Tue Dec 8 22:02:10 2020 +0000

    [feat] pp 1/n (Lightning-AI#5016)

    * Added changes for RPC plugin

    * Add missing kwargs

    * Fix code format

    * Loading refactors by introducing is_distributed var, fix optimizer step flow

    * Add rpc guard

    * Added docstrings and typing

    * resolve comments

    * Add additional rpc hook, refactor name of exit process hook for clarity

    * remove annotation

    * Modify behaviour to allow optional return, add test for rpc plugin

    * resolve tests

    * rename is_ddp_based

    * update

    * update for windows

    * update

    * resolve test

    * code smell

    * Revert back to init_ddp_connection for backwards compat

    * Swap to explicit name for property

    * Add missing speed parity increase for CI variability, fix call counts for child process

    Co-authored-by: tchaton <thomas@grid.ai>

commit ddd3eda
Author: brett koonce <koonce@gmail.com>
Date:   Tue Dec 8 15:27:43 2020 -0600

    docs: minor spelling tweaks (Lightning-AI#5022)

commit 6d2aeff
Author: Rohit Gupta <rohitgr1998@gmail.com>
Date:   Wed Dec 9 01:37:53 2020 +0530

    fast_dev_run can be int (Lightning-AI#4629)

    * fast_dev_run can be int

    * pep

    * chlog

    * add check and update docs

    * logging with fdr

    * update docs

    * suggestions

    Co-authored-by: Carlos Mocholí <carlossmocholi@gmail.com>

    * fdr flush logs

    * update trainer.fast_dev_run

    * codefactor and pre-commit isort

    * tmp

    Co-authored-by: Carlos Mocholí <carlossmocholi@gmail.com>
    Co-authored-by: Roger Shieh <sh.rog@protonmail.ch>
    Co-authored-by: edenlightning <66261195+edenlightning@users.noreply.github.com>

commit 79ae66d
Author: maxjeblick <maxjeblick@users.noreply.github.com>
Date:   Tue Dec 8 18:19:55 2020 +0100

    Initialize trainer with None (Lightning-AI#4847)

    Co-authored-by: Sean Naren <sean.narenthiran@gmail.com>
    Co-authored-by: chaton <thomas@grid.ai>
    Co-authored-by: edenlightning <66261195+edenlightning@users.noreply.github.com>
  • Loading branch information
gianscarpe committed Dec 15, 2020
1 parent 41343d4 commit a4d1e48
Show file tree
Hide file tree
Showing 151 changed files with 4,206 additions and 1,806 deletions.
3 changes: 1 addition & 2 deletions .github/workflows/ci_test-base.yml
Original file line number Diff line number Diff line change
Expand Up @@ -76,8 +76,7 @@ jobs:
with:
name: pytest-results-${{ runner.os }}-${{ matrix.python-version }}-${{ matrix.requires }}
path: junit/test-results-${{ runner.os }}-${{ matrix.python-version }}-${{ matrix.requires }}.xml
# Use always() to always run this step to publish test results when there are test failures
if: always()
if: failure()

- name: Statistics
if: success()
Expand Down
3 changes: 1 addition & 2 deletions .github/workflows/ci_test-conda.yml
Original file line number Diff line number Diff line change
Expand Up @@ -50,5 +50,4 @@ jobs:
with:
name: pytest-results-${{ runner.os }}-${{ matrix.python-version }}-${{ matrix.requires }}
path: junit/test-results-${{ runner.os }}-${{ matrix.python-version }}-${{ matrix.requires }}.xml
# Use always() to always run this step to publish test results when there are test failures
if: always()
if: failure()
3 changes: 1 addition & 2 deletions .github/workflows/ci_test-full.yml
Original file line number Diff line number Diff line change
Expand Up @@ -129,8 +129,7 @@ jobs:
with:
name: pytest-results-${{ runner.os }}-${{ matrix.python-version }}-${{ matrix.requires }}
path: junit/test-results-${{ runner.os }}-${{ matrix.python-version }}-${{ matrix.requires }}.xml
# Use always() to always run this step to publish test results when there are test failures
if: always()
if: failure()

- name: Statistics
if: success()
Expand Down
93 changes: 30 additions & 63 deletions .github/workflows/code-formatting.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,88 +22,55 @@ jobs:
- name: Run isort
run: isort --settings-path=./pyproject.toml --check-only --diff .

code-black:
name: Check code formatting with Black
runs-on: ubuntu-20.04
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Set up Python 3.8
uses: actions/setup-python@v2
with:
python-version: 3.8
- name: Install Black
run: pip install black==19.10b0
- name: Run Black
run: echo "LGTM"
# run black --skip-string-normalization --config=pyproject.toml --check . # TODO, uncomment
#code-black:
# name: Check code formatting with Black
# runs-on: ubuntu-20.04
# steps:
# - name: Checkout
# uses: actions/checkout@v2
# - name: Set up Python 3.8
# uses: actions/setup-python@v2
# with:
# python-version: 3.8
# - name: Install Black
# run: pip install black==19.10b0
# - name: Run Black
# run: echo "LGTM"
# run black --skip-string-normalization --config=pyproject.toml --check . # TODO, uncomment

python-types:
name: Python static type checking with Pyright
python-pep8:
name: Python formatting PEP8
runs-on: ubuntu-20.04

# Timeout: https://stackoverflow.com/a/59076067/4521646
timeout-minutes: 15
timeout-minutes: 10
steps:
- name: Checkout
uses: actions/checkout@v2
- uses: actions/setup-python@v2
with:
python-version: 3.7

# Note: This uses an internal pip API and may not always work
# https://github.com/actions/cache/blob/master/examples.md#multiple-oss-in-a-workflow
- name: Cache pip
uses: actions/cache@v2
with:
path: ~/.cache/pip
key: ${{ runner.os }}-pip-extras-${{ hashFiles('requirements.txt') }}-${{ hashFiles('requirements/extra.txt') }}
restore-keys: |
${{ runner.os }}-pip-extras-
- name: Install dependencies
env:
HOROVOD_BUILD_ARCH_FLAGS: "-mfma"
HOROVOD_WITHOUT_MXNET: 1
HOROVOD_WITHOUT_TENSORFLOW: 1
run: |
# python -m pip install --upgrade --user pip
pip install --requirement requirements.txt --upgrade-strategy only-if-needed --find-links https://download.pytorch.org/whl/cpu/torch_stable.html --quiet
pip install --requirement ./requirements/devel.txt --quiet
# pip install tox coverage
python --version ; pip --version ; pip list
shell: bash

- name: Set up node
uses: actions/setup-node@v1
with:
node-version: '12'

- name: Install pyright
run: |
npm install pyright
pip install flake8
- name: Run type checking
- name: Run checking
run: |
$(npm bin)/pyright --project .pyrightconfig.json
flake8 .
python-pep8:
name: Python formatting PEP8
python-typing-mypy:
name: Python typing check [mypy]
runs-on: ubuntu-20.04

# Timeout: https://stackoverflow.com/a/59076067/4521646
timeout-minutes: 10
steps:
- name: Checkout
uses: actions/checkout@v2
- uses: actions/checkout@master
- uses: actions/setup-python@v2
with:
python-version: 3.7

- name: Install dependencies
python-version: 3.8
- name: Install mypy
run: |
pip install flake8
- name: Run checking
pip install mypy
pip list
- name: mypy check
run: |
flake8 .
mypy
11 changes: 11 additions & 0 deletions .github/workflows/release-pypi.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,17 @@ jobs:
python setup.py sdist bdist_wheel
ls -lh dist/
- name: Upload to release
if: startsWith(github.event.ref, 'refs/tags') || github.event_name == 'release'
uses: svenstaro/upload-release-action@v2
with:
repo_token: ${{ secrets.GITHUB_TOKEN }}
file: dist/*
tag: ${{ github.ref }}
asset_name: packages
overwrite: false
file_glob: true

- name: Delay releasing
if: startsWith(github.event.ref, 'refs/tags') || github.event_name == 'release'
uses: juliangruber/sleep-action@v1
Expand Down
5 changes: 5 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -30,3 +30,8 @@ repos:
args: [--settings-path, ./pyproject.toml]
language: system
types: [python]

- repo: https://github.com/pre-commit/mirrors-mypy
rev: v0.790
hooks:
- id: mypy
46 changes: 0 additions & 46 deletions .pyrightconfig.json

This file was deleted.

98 changes: 37 additions & 61 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,123 +4,100 @@ All notable changes to this project will be documented in this file.

The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/).

## Unreleased

### Fixed

- Fixed `LoggerConnector` to have logged metrics on root device in DP ([#4138](https://github.com/PyTorchLightning/pytorch-lightning/pull/4138))
## [unreleased.BugFix] - YYYY-MM-DD

### Added

## [1.1.0rc] - 2020-12-02

### Added
### Changed

- Added "monitor" key to saved `ModelCheckpoints` ([#4383](https://github.com/PyTorchLightning/pytorch-lightning/pull/4383))

### Deprecated

- Added `ConfusionMatrix` class interface ([#4348](https://github.com/PyTorchLightning/pytorch-lightning/pull/4348))

### Removed

- Added multiclass AUROC metric ([#4236](https://github.com/PyTorchLightning/pytorch-lightning/pull/4236))

### Fixed

- Added global step indexing to the checkpoint name for a better sub-epoch checkpointing experience ([#3807](https://github.com/PyTorchLightning/pytorch-lightning/pull/3807))
- Fixed trainer by default `None` in `DDPAccelerator` ([#4915](https://github.com/PyTorchLightning/pytorch-lightning/pull/4915))


- Added optimizer hooks in callbacks ([#4379](https://github.com/PyTorchLightning/pytorch-lightning/pull/4379))
- Fixed `LightningOptimizer` exposes optimizer attributes ([#5095](https://github.com/PyTorchLightning/pytorch-lightning/pull/5095))


- Added option to log momentum ([#4384](https://github.com/PyTorchLightning/pytorch-lightning/pull/4384))
- Do not warn when the `name` key is used in the `lr_scheduler` dict ([#5057](https://github.com/PyTorchLightning/pytorch-lightning/pull/5057))


- Added `current_score` to `ModelCheckpoint.on_save_checkpoint` ([#4721](https://github.com/PyTorchLightning/pytorch-lightning/pull/4721))
## [1.1.0] - 2020-12-09

### Added

- Added "monitor" key to saved `ModelCheckpoints` ([#4383](https://github.com/PyTorchLightning/pytorch-lightning/pull/4383))
- Added `ConfusionMatrix` class interface ([#4348](https://github.com/PyTorchLightning/pytorch-lightning/pull/4348))
- Added multiclass AUROC metric ([#4236](https://github.com/PyTorchLightning/pytorch-lightning/pull/4236))
- Added global step indexing to the checkpoint name for a better sub-epoch checkpointing experience ([#3807](https://github.com/PyTorchLightning/pytorch-lightning/pull/3807))
- Added optimizer hooks in callbacks ([#4379](https://github.com/PyTorchLightning/pytorch-lightning/pull/4379))
- Added option to log momentum ([#4384](https://github.com/PyTorchLightning/pytorch-lightning/pull/4384))
- Added `current_score` to `ModelCheckpoint.on_save_checkpoint` ([#4721](https://github.com/PyTorchLightning/pytorch-lightning/pull/4721))
- Added logging using `self.log` in train and evaluation for epoch end hooks (
[#4552](https://github.com/PyTorchLightning/pytorch-lightning/pull/4552),
[#4495](https://github.com/PyTorchLightning/pytorch-lightning/pull/4495),
[#4439](https://github.com/PyTorchLightning/pytorch-lightning/pull/4439))
[#4684](https://github.com/PyTorchLightning/pytorch-lightning/pull/4684))
[#4913](https://github.com/PyTorchLightning/pytorch-lightning/pull/4913))


- Added ability for DDP plugin to modify optimizer state saving ([#4675](https://github.com/PyTorchLightning/pytorch-lightning/pull/4675))


- Added casting to python types for numpy scalars when logging hparams ([#4647](https://github.com/PyTorchLightning/pytorch-lightning/pull/4647))
- Added `prefix` argument in loggers ([#4557](https://github.com/PyTorchLightning/pytorch-lightning/pull/4557))


- Added printing of total num of params, trainable and non-trainable params in ModelSummary ([#4521](https://github.com/PyTorchLightning/pytorch-lightning/pull/4521))


- Added optimizer refactors ([#4658](https://github.com/PyTorchLightning/pytorch-lightning/pull/4658))


- Added `PrecisionRecallCurve, ROC, AveragePrecision` class metric ([#4549](https://github.com/PyTorchLightning/pytorch-lightning/pull/4549))


- Added custom `Apex` and `NativeAMP` as `Precision plugins` ([#4355](https://github.com/PyTorchLightning/pytorch-lightning/pull/4355))


- Added `DALI MNIST` example ([#3721](https://github.com/PyTorchLightning/pytorch-lightning/pull/3721))


- Added `sharded plugin` for DDP for multi-gpu training memory optimizations (
[#4639](https://github.com/PyTorchLightning/pytorch-lightning/pull/4639),
[#4686](https://github.com/PyTorchLightning/pytorch-lightning/pull/4686),
[#4675](https://github.com/PyTorchLightning/pytorch-lightning/pull/4675),
[#4737](https://github.com/PyTorchLightning/pytorch-lightning/pull/4737),
[#4773](https://github.com/PyTorchLightning/pytorch-lightning/pull/4773))


[#4639](https://github.com/PyTorchLightning/pytorch-lightning/pull/4639),
[#4686](https://github.com/PyTorchLightning/pytorch-lightning/pull/4686),
[#4675](https://github.com/PyTorchLightning/pytorch-lightning/pull/4675),
[#4737](https://github.com/PyTorchLightning/pytorch-lightning/pull/4737),
[#4773](https://github.com/PyTorchLightning/pytorch-lightning/pull/4773))
- Added `experiment_id` to the NeptuneLogger ([#3462](https://github.com/PyTorchLightning/pytorch-lightning/pull/3462))


- Added `Pytorch Geometric` integration example with Lightning ([#4568](https://github.com/PyTorchLightning/pytorch-lightning/pull/4568))
- Added `all_gather` method to `LightningModule` which allows gradient based tensor synchronizations for use-cases such as negative sampling. ([#5012](https://github.com/PyTorchLightning/pytorch-lightning/pull/5012))
- Enabled `self.log` in most functions ([#4969](https://github.com/PyTorchLightning/pytorch-lightning/pull/4969))
- Added changeable extension variable for `ModelCheckpoint` ([#4977](https://github.com/PyTorchLightning/pytorch-lightning/pull/4977))


### Changed

- Removed `multiclass_roc` and `multiclass_precision_recall_curve`, use `roc` and `precision_recall_curve` instead ([#4549](https://github.com/PyTorchLightning/pytorch-lightning/pull/4549))



- Tuner algorithms will be skipped if `fast_dev_run=True` ([#3903](https://github.com/PyTorchLightning/pytorch-lightning/pull/3903))



- WandbLogger does not force wandb `reinit` arg to True anymore and creates a run only when needed ([#4648](https://github.com/PyTorchLightning/pytorch-lightning/pull/4648))


- `WandbLogger` does not force wandb `reinit` arg to True anymore and creates a run only when needed ([#4648](https://github.com/PyTorchLightning/pytorch-lightning/pull/4648))
- Changed `automatic_optimization` to be a model attribute ([#4602](https://github.com/PyTorchLightning/pytorch-lightning/pull/4602))


- Changed `Simple Profiler` report to order by percentage time spent + num calls ([#4880](https://github.com/PyTorchLightning/pytorch-lightning/pull/4880))
- Simplify optimization Logic ([#4984](https://github.com/PyTorchLightning/pytorch-lightning/pull/4984))
- Classification metrics overhaul ([#4837](https://github.com/PyTorchLightning/pytorch-lightning/pull/4837))
- Updated `fast_dev_run` to accept integer representing num_batches ([#4629](https://github.com/PyTorchLightning/pytorch-lightning/pull/4629))
- Refactored optimizer ([#4658](https://github.com/PyTorchLightning/pytorch-lightning/pull/4658))


### Deprecated

- Deprecated `prefix` argument in `ModelCheckpoint` ([#4765](https://github.com/PyTorchLightning/pytorch-lightning/pull/4765))


- Deprecated the old way of assigning hyper-parameters through `self.hparams = ...` ([#4813](https://github.com/PyTorchLightning/pytorch-lightning/pull/4813))


- Deprecated `mode='auto'` from `ModelCheckpoint` and `EarlyStopping` ([#4695](https://github.com/PyTorchLightning/pytorch-lightning/pull/4695))


### Removed


- Removed `reorder` parameter of the `auc` metric ([#5004](https://github.com/PyTorchLightning/pytorch-lightning/pull/5004))
- Removed `multiclass_roc` and `multiclass_precision_recall_curve`, use `roc` and `precision_recall_curve` instead ([#4549](https://github.com/PyTorchLightning/pytorch-lightning/pull/4549))

### Fixed

- Added feature to move tensors to CPU before saving ([#4309](https://github.com/PyTorchLightning/pytorch-lightning/pull/4309))

- Fixed `LoggerConnector` to have logged metrics on root device in DP ([#4138](https://github.com/PyTorchLightning/pytorch-lightning/pull/4138))


- Auto convert tensors to contiguous format when `gather_all` ([#4907](https://github.com/PyTorchLightning/pytorch-lightning/pull/4907))
- Fixed `PYTHONPATH` for ddp test model ([#4528](https://github.com/PyTorchLightning/pytorch-lightning/pull/4528))
- Fixed allowing logger to support indexing ([#4595](https://github.com/PyTorchLightning/pytorch-lightning/pull/4595))
- Fixed DDP and manual_optimization ([#4976](https://github.com/PyTorchLightning/pytorch-lightning/pull/4976))


## [1.0.8] - 2020-11-24
Expand Down Expand Up @@ -159,7 +136,6 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/).
### Changed

- Change Metrics `persistent` default mode to `False` ([#4685](https://github.com/PyTorchLightning/pytorch-lightning/pull/4685))

- LoggerConnector log_metrics will use `total_batch_idx` instead of `global_step` when logging on `training step` ([#4738](https://github.com/PyTorchLightning/pytorch-lightning/pull/4738))


Expand Down
1 change: 0 additions & 1 deletion MANIFEST.in
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,6 @@ exclude tests
recursive-exclude docs *
exclude docs
recursive-include docs/source/_images/logos/ *
recursive-include docs/source/_images/badges/ *
recursive-include docs/source/_images/general/ pl_overview* tf_* tutorial_* PTL101_*

# Include the Requirements
Expand Down
Loading

0 comments on commit a4d1e48

Please sign in to comment.