File tree Expand file tree Collapse file tree 1 file changed +5
-2
lines changed
napari_cellseg3d/code_models Expand file tree Collapse file tree 1 file changed +5
-2
lines changed Original file line number Diff line number Diff line change @@ -546,10 +546,10 @@ def get_loader_func(num_samples):
546546 if device .type == "cuda" :
547547 self .log ("Memory Usage:" )
548548 alloc_mem = round (
549- torch .cuda .memory_allocated (0 ) / 1024 ** 3 , 1
549+ torch .cuda .memory_allocated (device_id ) / 1024 ** 3 , 1
550550 )
551551 reserved_mem = round (
552- torch .cuda .memory_reserved (0 ) / 1024 ** 3 , 1
552+ torch .cuda .memory_reserved (device_id ) / 1024 ** 3 , 1
553553 )
554554 self .log (f"Allocated: { alloc_mem } GB" )
555555 self .log (f"Cached: { reserved_mem } GB" )
@@ -593,6 +593,9 @@ def get_loader_func(num_samples):
593593
594594 self .log ("Updating scheduler..." )
595595 scheduler .step (epoch_loss )
596+ self .log (
597+ f"Current learning rate: { optimizer .param_groups [0 ]['lr' ]} "
598+ )
596599
597600 checkpoint_output = []
598601 eta = (
You can’t perform that action at this time.
0 commit comments