Skip to content

Commit c32ac4c

Browse files
committed
Remove extra gradient checking
This was redundant.
1 parent b3eb2b4 commit c32ac4c

File tree

2 files changed

+1
-2
lines changed

2 files changed

+1
-2
lines changed

common/darts/architecture.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,6 @@ def comp_unrolled_model(self, data, target, eta, optimizer):
5656
moment = torch.zeros_like(theta)
5757

5858
# flatten all gradients
59-
gradient= autograd.grad(loss, self.model.parameters(), allow_unused=True)
6059
dtheta = F.flatten(autograd.grad(loss, self.model.parameters())).data
6160
# indeed, here we implement a simple SGD with momentum and weight decay
6261
# theta = theta - eta * (moment + weight decay + dtheta)

examples/darts/advanced/default_model.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[Global_Params]
22
model_name = 'darts_uno'
3-
unrolled = False
3+
unrolled = True
44
data_url = 'ftp.mcs.anl.gov/pub/candle/public/benchmarks/Pilot1/uno/'
55
savepath = './results'
66
log_interval = 10

0 commit comments

Comments
 (0)