Skip to content

Commit

Permalink
Adding a new example to README.:
Browse files Browse the repository at this point in the history
  • Loading branch information
kaanaksit committed Dec 1, 2023
1 parent d48e225 commit 74d7334
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -127,6 +127,8 @@ model_mlp = odak.learn.models.multi_layer_perceptron(
bias = False,
model_type = 'conventional'
)


optimizer = torch.optim.AdamW(model_mlp.parameters(), lr = 1e-3)
loss_function = torch.nn.MSELoss()
for epoch in range(10000):
Expand All @@ -138,6 +140,7 @@ for epoch in range(10000):
optimizer.step()
print('Training loss: {}'.format(loss.item()))


for item_id, item in enumerate(pos_x1):
torch.no_grad()
ground_truth = x1[item_id]
Expand Down

0 comments on commit 74d7334

Please sign in to comment.