rename variables nb -> num (#567)

* rename nb -> num

* flake8

* batch_nb, epoch_nb, gpu_nb, split_nb

* add _num deprecations
This commit is contained in:
Jirka Borovec
2019-12-04 06:57:10 -05:00
committed by William Falcon
parent 63717e8fda
commit 3a58937d8b
30 changed files with 326 additions and 290 deletions
+2 -2
View File
@@ -121,7 +121,7 @@ class LightningTestModelBase(LightningModule):
loss_val = loss_val.unsqueeze(0)
# alternate possible outputs to test
if self.trainer.batch_nb % 1 == 0:
if self.trainer.batch_idx % 1 == 0:
output = OrderedDict({
'loss': loss_val,
'progress_bar': {'some_val': loss_val * loss_val},
@@ -129,7 +129,7 @@ class LightningTestModelBase(LightningModule):
})
return output
if self.trainer.batch_nb % 2 == 0:
if self.trainer.batch_idx % 2 == 0:
return loss_val
# ---------------------