Skip to content

Commit f44422e

Browse files
authored
Re-add comments in code example
1 parent 3c70b25 commit f44422e

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -99,9 +99,9 @@ Here is how to change a standard multi-task training loop to use Jacobian descen
9999
optimizer = SGD(params, lr=0.1)
100100
+ aggregator = UPGrad()
101101

102-
inputs = torch.randn(8, 16, 10)
103-
task1_targets = torch.randn(8, 16, 1)
104-
task2_targets = torch.randn(8, 16, 1)
102+
inputs = torch.randn(8, 16, 10) # 8 batches of 16 random input vectors of length 10
103+
task1_targets = torch.randn(8, 16, 1) # 8 batches of 16 targets for the first task
104+
task2_targets = torch.randn(8, 16, 1) # 8 batches of 16 targets for the second task
105105

106106
for input, target1, target2 in zip(inputs, task1_targets, task2_targets):
107107
features = shared_module(input)

0 commit comments

Comments
 (0)