pytorch/torch/optim
Edward Yang 173f224570 Turn on F401: Unused import warning. (#18598)
Summary:
Pull Request resolved: https://github.com/pytorch/pytorch/pull/18598
ghimport-source-id: c74597e5e7437e94a43c163cee0639b20d0d0c6a

Stack from [ghstack](https://github.com/ezyang/ghstack):
* **#18598 Turn on F401: Unused import warning.**

This was requested by someone at Facebook; this lint is turned
on for Facebook by default.  "Sure, why not."

I had to noqa a number of imports in __init__.  Hypothetically
we're supposed to use __all__ in this case, but I was too lazy
to fix it.  Left for future work.

Be careful!  flake8-2 and flake8-3 behave differently with
respect to import resolution for # type: comments.  flake8-3 will
report an import unused; flake8-2 will not.  For now, I just
noqa'd all these sites.

All the changes were done by hand.

Signed-off-by: Edward Z. Yang <ezyang@fb.com>

Differential Revision: D14687478

fbshipit-source-id: 30d532381e914091aadfa0d2a5a89404819663e3
2019-03-30 09:01:17 -07:00
..
__init__.py Turn on F401: Unused import warning. (#18598) 2019-03-30 09:01:17 -07:00
adadelta.py Added parameter range checks for all optimizers (#6000) 2018-03-28 11:22:23 +02:00
adagrad.py Remove methods that start with an underscore from at::Tensor (#11152) 2018-09-07 11:55:11 -07:00
adam.py fix lint after new flake8 release added new style constraints (#13047) 2018-10-24 09:03:38 -07:00
adamax.py Added parameter range checks for all optimizers (#6000) 2018-03-28 11:22:23 +02:00
asgd.py Added parameter range checks for all optimizers (#6000) 2018-03-28 11:22:23 +02:00
lbfgs.py Make return uniform in lbfgs step (#7586) 2018-05-16 11:16:46 -04:00
lr_scheduler.py Turn on F401: Unused import warning. (#18598) 2019-03-30 09:01:17 -07:00
optimizer.py Add name for required optimizer parameter. (#13202) 2018-10-29 15:02:21 -07:00
rmsprop.py Added parameter range checks for all optimizers (#6000) 2018-03-28 11:22:23 +02:00
rprop.py Turn on F401: Unused import warning. (#18598) 2019-03-30 09:01:17 -07:00
sgd.py SGD: remove unneeded multiply-add initialization operations (#18114) 2019-03-19 10:34:17 -07:00
sparse_adam.py fix lint after new flake8 release added new style constraints (#13047) 2018-10-24 09:03:38 -07:00