Skip to content

Commit

Permalink
Accept arguments in the optimizer advances #17
Browse files Browse the repository at this point in the history
  • Loading branch information
pab1s committed Jun 24, 2024
1 parent d4c8ba2 commit 125cd7e
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions factories/loss_factory.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,5 @@
class LossFactory(Factory):
def __init__(self):
super().__init__()
self.register("CrossEntropyLoss", lambda: CrossEntropyLoss())
self.register("MSELoss", lambda: MSELoss())
self.register("CrossEntropyLoss", lambda **kwargs: CrossEntropyLoss(**kwargs))
self.register("MSELoss", lambda **kwargs: MSELoss(**kwargs))

0 comments on commit 125cd7e

Please sign in to comment.