* add ppo rl lightning template
* flake
* import gym without try as in qnet example
* fix import format
* remove torch.optim import, not required
* fix import format isort
* add trainer argparse
* change name of trajectory collection method
* add repo in references
* fix typo in comments
* use isinstance to verify actionspace type
* use fstring
* deduplication of logic code
* rename unused forloop variable
* use pl.seed_everything instead
* remove unused numpy import
* format string printed on error
* fix typo in comments
Co-authored-by: chaton <thomas@grid.ai>
* fix num_workers for Windows example
* chlog
* Apply suggestions from code review
Co-authored-by: Carlos Mocholí <carlossmocholi@gmail.com>
* warn
Co-authored-by: Carlos Mocholí <carlossmocholi@gmail.com>
* black formatting and migrated to self.log logging
* Apply suggestions from code review
Co-authored-by: Rohit Gupta <rohitgr1998@gmail.com>
* migrated to accuracy in the metrics package
migrated to accuracy in the metrics package
* removed trailing whitespace
* Apply suggestions from code review
Co-authored-by: Jirka Borovec <Borda@users.noreply.github.com>
Co-authored-by: Rohit Gupta <rohitgr1998@gmail.com>
Co-authored-by: Nicki Skafte <skaftenicki@gmail.com>
(cherry picked from commit 17a0784c5e)
* update DALIClassificationLoader to not use deprecated arguments
* fix line length
* dali version check added and changed args accordingly
* versions
* checking version using disutils.version.LooseVersion now
* .
* ver
* import
Co-authored-by: Jirka Borovec <jirka.borovec@seznam.cz>
Co-authored-by: Jirka Borovec <Borda@users.noreply.github.com>
* add option to step result to do aggregation on a specific device
* in dp: do aggregation on root gpu
* Update CHANGELOG.md
* pep8
* trailing whitespace
* uncomment DP
* more cases
* tmpdir
* test
* note
* move to root
move result
stupid result object
revert to master
undo import
add "to" method to result
generalize to
try a test
try a test
Revert "try a test"
This reverts commit 22e3c1001e6c5774ea18ad925830304c245bf145.
Revert "try a test"
This reverts commit 4d2d8fb2a52d552894809a0cbe51af126d78f070.
new test
max epochs
super epoch end
log in test
hanging test
undo test
initial test that fails on master
step end
pass
step end
step end
epoch end
print
step
check dev
clean up test
sanity check
wtf is go ing on
frustration
debugging test
test
test
test
test
test
test
test
test
unused import
* dist backend -> accelerator
* remove todo
Co-authored-by: Justus Schock <justus.schock@rwth-aachen.de>
Co-authored-by: Justus Schock <12886177+justusschock@users.noreply.github.com>
Co-authored-by: Adrian Wälchli <aedu.waelchli@gmail.com>
* Update to latest logging format and modify the accuracy method.
* Apply suggestions from code review
Co-authored-by: Jirka Borovec <Borda@users.noreply.github.com>
Co-authored-by: chaton <thomas@grid.ai>
Adam's beta 2 parameter was mistakenly referred to as the first order momentum of the gradient, whereas it should be the second order momentum. This has no effect on the correct working of the example.
* add MNIST DALI example, update README.md
* Fix PEP8 warnings
* reformatted using black
* add mnist_dali to test_examples.py
* Add documentation as docstrings
* add nvidia-pyindex and nvidia-dali-cuda100
* replace nvidia-pyindex with --extra-index-url
* mark mnist_dali test as Linux and GPU only
* adjust CUDA docker and examples.txt, fix import error in test_examples.py
* adjust the GPU check
* Exit when DALI is not available
* remove requirements-examples.txt and DALI pip install
* Refactored example, moved to new logging api, added runtime check for test and dali script
* Patch to reflect the mnist example module
* add req.
* Apply suggestions from code review
* Removed requirement as it breaks CPU install, added note in README to install DALI
* add DALI to Drone
* test examples
* Apply suggestions from code review
* imports
* ABC
* cuda
* cuda
* pip DALI
* Move build into init function
Co-authored-by: SeanNaren <sean@grid.ai>
Co-authored-by: Jirka Borovec <jirka@pytorchlightning.ai>
Co-authored-by: Jirka Borovec <Borda@users.noreply.github.com>
Co-authored-by: Sean Naren <sean.narenthiran@gmail.com>
* Removed image generation inside the training step.
It was overwriting the image grid generated in `on_epoch_end`. I also made `adversarial_loss` a static method.
* Incorporated Hyperparameter best practices
Using ArgumentParser and hparams as defined in the Hyperparameters section of
the documentation. This way we can set trainer flags (such as precision,
and gpus) from the command line.
* Incorporated Hyperparameter best practices
Using ArgumentParser and hparams as defined in the Hyperparameters section of
the documentation. This way we can set trainer flags (such as precision,
and gpus) from the command line.
* Split the data part into a LightningDataModule
* Update pl_examples/domain_templates/generative_adversarial_net.py
Co-authored-by: Jeff Yang <ydcjeff@outlook.com>
* fix imagenet example: lr_scheduler, loader workers, batch size when ddp
* Fix evaluation for imagenet example
* add imagenet example test
* cleanup
* gpu
* add imagenet example evluation test
* fix test output
* test is fixed in master, remove unecessary hack
* CHANGE
* Apply suggestions from code review
* image net example
* update imagenet example
* update example
* pep
* imports
* type hint
* docs
* obsolete arg
* [wip] fix imagenet example: lr_scheduler, loader workers, batch size when ddp (#2432)
* fix imagenet example: lr_scheduler, loader workers, batch size when ddp
* Fix evaluation for imagenet example
* add imagenet example test
* cleanup
* gpu
* add imagenet example evluation test
* fix test output
* test is fixed in master, remove unecessary hack
* CHANGE
* Apply suggestions from code review
Co-authored-by: Jirka <jirka@pytorchlightning.ai>
Co-authored-by: Adrian Wälchli <aedu.waelchli@gmail.com>
* update chlog
* add missing chlog
* pep
* pep
Co-authored-by: Ruotian Luo <rluo@ttic.edu>
Co-authored-by: Jirka <jirka@pytorchlightning.ai>
* add tests for single scalar return from training
* add tests for single scalar return from training
* add tests for single scalar return from training
* fixing val step only
* fixing val step only
* fixing val step only
* fixing val step only
* fixing val step only
* fixing val step only
* fixing val step only
* fixing val step only
* fixing val step only
* fixing val step only
* fixing val step only
* fixing val step only
* fixing val step only
* fixing val step only
* fixing val step only
* fixing val step only
* fixing val step only
* fixing val step only
* fixing val step only
* fixing val step only
* fixing val step only
* fixing val step only
* fix tpu hang
* fix tpu hang
* fix tpu hang
* fix tpu hang
* fix tpu hang
* fix tpu hang
* fix tpu hang
* fix tpu hang
* fix tpu hang
* fix tpu hang
* fix tpu hang
* fix tpu hang
* fix tpu hang
* fix tpu hang
* fix tpu hang
* fix tpu hang
* fix tpu hang
* fix tpu hang
* fix tpu hang
* fix tpu hang
* fix tpu hang
* fix tpu hang
* fix tpu hang
* fix tpu hang
* fix tpu hang
* fix tpu hang
* fix tpu hang
* fix tpu hang
* fix tpu hang
* fix tpu hang
* fix tpu hang
* fix tpu hang
* fix tpu hang
* fix tpu hang
* fix tpu hang
* fix tpu hang
* fix tpu hang
* fix tpu hang
* fix tpu hang
* fix tpu hang
* no cov
* no cov
* ReduceOp
* group
* reduce_op.sum
* Update sklearns.py
* formatting
* horovod
* Apply suggestions from code review
* horovod
* horovod
* horovod
* horovod
* ci
* print
* ci
* timeout
* timeout
* time
* fix
* distributed cpu
* pipes
* time
* cpu
* spawn
* spawn
* spawn
* tp
* separate
* os
* os
* npm
* Fix load_from_checkpoint() not working with URL on Windows
* Update CHANGELOG
* Update CHANGELOG.md
Co-authored-by: Peter Yu <2057325+yukw777@users.noreply.github.com>
* Apply suggestions from code review
* fix
* fix meta tags creating empty lines
* pyright
* node
* fix httpserver address
* drop tutils.default_trainer_options
* imports
* Better fix for load_from_checkpoint() not working with absolute path on Windows (#2294)
* Fix load_from_checkpoint() not working with URL on Windows
* Update CHANGELOG
* Update CHANGELOG.md
Co-authored-by: Peter Yu <2057325+yukw777@users.noreply.github.com>
* Apply suggestions from code review
Co-authored-by: Jirka Borovec <Borda@users.noreply.github.com>
Co-authored-by: Peter Yu <2057325+yukw777@users.noreply.github.com>
* drop duplicate
Co-authored-by: Justus Schock <12886177+justusschock@users.noreply.github.com>
Co-authored-by: airium <airium@outlook.com>
Co-authored-by: Peter Yu <2057325+yukw777@users.noreply.github.com>
Co-authored-by: Adrian Wälchli <aedu.waelchli@gmail.com>
Co-authored-by: AIRIUM <38249940+airium@users.noreply.github.com>
* replace ddp spawn with subprocess
* replace ddp spawn with subprocess
* replace ddp spawn with subprocess
* replace ddp spawn with subprocess
* replace ddp spawn with subprocess
* replace ddp spawn with subprocess
* replace ddp spawn with subprocess
* replace ddp spawn with subprocess
* replace ddp spawn with subprocess
* replace ddp spawn with subprocess
* replace ddp spawn with subprocess
* replace ddp spawn with subprocess
* replace ddp spawn with subprocess
* replace ddp spawn with subprocess
* replace ddp spawn with subprocess
* replace ddp spawn with subprocess
* replace ddp spawn with subprocess
* replace ddp spawn with subprocess
* replace ddp spawn with subprocess
* replace ddp spawn with subprocess
* replace ddp spawn with subprocess
* replace ddp spawn with subprocess
* replace ddp spawn with subprocess
* replace ddp spawn with subprocess
* replace ddp spawn with subprocess
* replace ddp spawn with subprocess
* replace ddp spawn with subprocess
* replace ddp spawn with subprocess
* replace ddp spawn with subprocess
* replace ddp spawn with subprocess
* replace ddp spawn with subprocess
* replace ddp spawn with subprocess
* replace ddp spawn with subprocess
* replace ddp spawn with subprocess
* replace ddp spawn with subprocess
* replace ddp spawn with subprocess
* replace ddp spawn with subprocess
* replace ddp spawn with subprocess
* replace ddp spawn with subprocess
* replace ddp spawn with subprocess
* replace ddp spawn with subprocess
* replace ddp spawn with subprocess
* replace ddp spawn with subprocess
* replace ddp spawn with subprocess
* replace ddp spawn with subprocess
* replace ddp spawn with subprocess
* replace ddp spawn with subprocess
* replace ddp spawn with subprocess
* replace ddp spawn with subprocess
* replace ddp spawn with subprocess
* replace ddp spawn with subprocess
* replace ddp spawn with subprocess
* replace ddp spawn with subprocess
* replace ddp spawn with subprocess
* replace ddp spawn with subprocess
* hot fix
* hot fix
* hot fix
* hot fix
* hot fix
* hot fix
* hot fix
* hot fix
* hot fix
* hot fix
* hot fix
* hot fix
* hot fix
* hot fix
* hot fix
* hot fix
* hot fix
* hot fix
* hot fix
* hot fix
* hot fix
* hot fix
* hot fix
* hot fix
* hot fix
* hot fix
* hot fix
* hot fix
* hot fix
* hot fix
* hot fix
* hot fix
* hot fix
* hot fix
* hot fix
* hot fix
* hot fix
* hot fix
* hot fix
* hot fix
* hot fix
* hot fix
* hot fix
* hot fix
* hot fix
* hot fix
* hot fix
* hot fix
* hot fix
* hot fix
* hot fix
* hot fix
* hot fix
* hot fix
* hot fix
* hot fix
* hot fix
* hot fix
* hot fix
* 🐛 fixed fake example type assigning and hparams arg
* fixed GAN example to work with dp, ddp., ddp_cpu
* Update generative_adversarial_net.py
Co-authored-by: William Falcon <waf2107@columbia.edu>
* Set precision=16 when use_amp is passed as True
* Update CHANGELOG.md
* add use_amp to deprecated API
* Update trainer.py
* Update trainer.py
* move the use_amp attribute to deprecated API
* move use_amp deprecation back to Trainer's __init__
* drop unsed
* drop deprecated
* reorder imports
* typing
Co-authored-by: Jirka Borovec <Borda@users.noreply.github.com>
Co-authored-by: William Falcon <waf2107@columbia.edu>
Co-authored-by: J. Borovec <jirka.borovec@seznam.cz>
* removes need to unsqueeze from dp
* removes need to unsqueeze from dp
* fixed examples
* added auto unsqueeze
* added auto unsqueeze
* added auto unsqueeze
* added auto unsqueeze
* Update pytorch_lightning/overrides/data_parallel.py
Co-Authored-By: Adrian Wälchli <adrian.waelchli@students.unibe.ch>
* fixed dp parse
* fixed dp parse
Co-authored-by: Adrian Wälchli <adrian.waelchli@students.unibe.ch>
* `add_argparse_args` method fixed (argument types added)
* CHANGELOG.md upd
* autopep8 fixes
* --gpus=0 removed from test (for ci tests)
* typo fixed
* reduce on plateau scheduler fixed
* Trainer cli related tests moved to test_trainer_cli.py
* refactored: get_init_arguments_and_types is a public classmethod of the Trainer now
* test_get_init_arguments_and_types added
* autopep8 fixes
* Trainer cli related tests moved to test_trainer_cli.py
* refactored: get_init_arguments_and_types is a public classmethod of the Trainer now
* test_get_init_arguments_and_types added
* autopep8 fixes
* Trainer cli related tests moved to test_trainer_cli.py
* refactored: get_init_arguments_and_types is a public classmethod of the Trainer now
* test_get_init_arguments_and_types added
* autopep8 fixes
* Trainer cli related tests moved to test_trainer_cli.py
* test_get_init_arguments_and_types added
* autopep8 fixes
* Apply suggestions from code review
* cosmetics
* cosmetics
* Update pytorch_lightning/trainer/trainer.py
Co-Authored-By: Jirka Borovec <Borda@users.noreply.github.com>
* `Trainer.get_init_arguments_and_types` now returns arg types wrapped in tuples (not in sets)
* deprecated args are now ignored in argparser
* get_deprecated_arg_names small refactor
* get_deprecated_arg_names bug fixed
* Trainer cli related tests moved to test_trainer_cli.py
* refactored: get_init_arguments_and_types is a public classmethod of the Trainer now
* test_get_init_arguments_and_types added
* autopep8 fixes
* Trainer cli related tests moved to test_trainer_cli.py
* autopep8 fixes
* Trainer cli related tests moved to test_trainer_cli.py
* Trainer cli related tests moved to test_trainer_cli.py
* test_get_init_arguments_and_types added
* autopep8 fixes
* autopep8 fixes
* Apply suggestions from code review
* cosmetics
* cosmetics
* Update pytorch_lightning/trainer/trainer.py
Co-Authored-By: Jirka Borovec <Borda@users.noreply.github.com>
* `Trainer.get_init_arguments_and_types` now returns arg types wrapped in tuples (not in sets)
* deprecated args are now ignored in argparser
* get_deprecated_arg_names small refactor
* get_deprecated_arg_names bug fixed
* Update pytorch_lightning/trainer/trainer.py
Co-Authored-By: Joe Davison <joe@huggingface.co>
* Update pytorch_lightning/trainer/trainer.py
Co-Authored-By: Joe Davison <joe@huggingface.co>
Co-authored-by: Jirka Borovec <Borda@users.noreply.github.com>
Co-authored-by: Joe Davison <joe@huggingface.co>
Co-authored-by: William Falcon <waf2107@columbia.edu>
* added get dataloaders directly using a getter
* deleted decorator
* added prepare_data hook
* refactored dataloader init
* refactored dataloader init
* added dataloader reset flag and main loop
* added dataloader reset flag and main loop
* added dataloader reset flag and main loop
* made changes
* made changes
* made changes
* made changes
* made changes
* made changes
* made changes
* made changes
* made changes
* made changes
* made changes
* made changes
* made changes
* made changes
* made changes
* made changes
* made changes
* made changes
* made changes
* made changes
* made changes
* made changes
* made changes
* made changes
* made changes
* made changes
* made changes
* made changes
* made changes
* made changes
* made changes
* made changes
* made changes
* made changes
* made changes
* made changes
* made changes
* made changes
* made changes
* made changes
* made changes
* made changes
* made changes
* made changes
* made changes
* made changes
* fixed bad loaders
* fixed bad loaders
* fixed bad loaders
* fixed bad loaders
* fixed bad loaders
* fixed bad loaders
* fixed bad loaders
* fixed bad loaders
* fixed bad loaders
* fixed error in .fit with loaders
* fixed error in .fit with loaders
* fixed error in .fit with loaders
* fixed error in .fit with loaders
* fixed error in .fit with loaders
* fixed error in .fit with loaders
* fixed error in .fit with loaders
* fixed error in .fit with loaders
* fixed error in .fit with loaders
* fixed error in .fit with loaders
* fixed error in .fit with loaders
* fixed error in .fit with loaders
* fixed error in .fit with loaders
* fixes#909
* fixes#909
* bug fix
* Fixes#902
* added initial semantic segmentation example
* removed unnecessary lines.
* changed according to reviews
* minor changes
* Added some documentation for Dataset class
* Fixed some long lines
* added docstring for LightningModule
* implement forward and update args (#709)
Fixes the following issues as discussed in issue #709
1) Implement forward method wrapped.
2) Set default value for seed. "None" breaks tensorboard.
3) Update redundant hparams.data to new hparams.data_path.
4) Update 'use-16bit' to 'use_16bit' to maintain consistency.
* Fix failing GPU tests (#722)
* Fix distributed_backend=None test
We now throw a warning instead of an exception. Update test
to reflect this.
* Fix test_tube logger close when debug=True
* Clean docs (#725)
* updated gitignore
* updated gitignore
* updated links in ninja file
* updated docs
* finished callbacks
* finished callbacks
* finished callbacks
* fixed left menu
* added callbacks to menu
* added direct links to docs
* added direct links to docs
* added direct links to docs
* added direct links to docs
* added direct links to docs
* added direct links to docs
* updated gitignore
* updated links in ninja file
* updated docs
* finished callbacks
* finished callbacks
* finished callbacks
* fixed left menu
* added callbacks to menu
* added direct links to docs
* added direct links to docs
* added direct links to docs
* added direct links to docs
* added direct links to docs
* added direct links to docs
* finished rebase
* making private members
* making private members
* making private members
* working on trainer docs
* working on trainer docs
* working on trainer docs
* working on trainer docs
* working on trainer docs
* working on trainer docs
* set auto dp if no backend
* working on trainer docs
* working on trainer docs
* working on trainer docs
* working on trainer docs
* working on trainer docs
* working on trainer docs
* working on trainer docs
* working on trainer docs
* fixed lightning import
* cleared spaces
* cleared spaces
* cleared spaces
* cleared spaces
* cleared spaces
* cleared spaces
* cleared spaces
* cleared spaces
* cleared spaces
* cleared spaces
* finished lightning module
* finished lightning module
* finished lightning module
* finished lightning module
* added callbacks
* added loggers
* added loggers
* added loggers
* added loggers
* added loggers
* added loggers
* added loggers
* added loggers
* set auto dp if no backend
* added loggers
* added loggers
* added loggers
* added loggers
* added loggers
* added loggers
* flake 8
* flake 8
* fix docs path
* updated gitignore
* updated gitignore
* updated links in ninja file
* updated docs
* finished callbacks
* finished callbacks
* finished callbacks
* fixed left menu
* added callbacks to menu
* added direct links to docs
* added direct links to docs
* added direct links to docs
* added direct links to docs
* added direct links to docs
* added direct links to docs
* updated gitignore
* updated docs
* finished callbacks
* finished callbacks
* finished callbacks
* fixed left menu
* added callbacks to menu
* added direct links to docs
* added direct links to docs
* added direct links to docs
* added direct links to docs
* added direct links to docs
* added direct links to docs
* finished rebase
* making private members
* making private members
* making private members
* working on trainer docs
* working on trainer docs
* working on trainer docs
* working on trainer docs
* working on trainer docs
* working on trainer docs
* set auto dp if no backend
* working on trainer docs
* working on trainer docs
* working on trainer docs
* working on trainer docs
* working on trainer docs
* working on trainer docs
* working on trainer docs
* fixed lightning import
* cleared spaces
* cleared spaces
* cleared spaces
* cleared spaces
* cleared spaces
* finished lightning module
* finished lightning module
* finished lightning module
* finished lightning module
* added callbacks
* added loggers
* added loggers
* added loggers
* added loggers
* added loggers
* added loggers
* added loggers
* added loggers
* added loggers
* added loggers
* added loggers
* flake 8
* flake 8
* fix docs path
* flake 8
* Update theme_variables.jinja
* implement forward and update args (#709)
Fixes the following issues as discussed in issue #709
1) Implement forward method wrapped.
2) Set default value for seed. "None" breaks tensorboard.
3) Update redundant hparams.data to new hparams.data_path.
4) Update 'use-16bit' to 'use_16bit' to maintain consistency.
* use self.forward for val step (#709)
Co-authored-by: Nic Eggert <nic@eggert.io>
Co-authored-by: William Falcon <waf2107@columbia.edu>