Skip to content

Commit d160b7b

Browse files
committed
Fix Init.check_keys
1 parent 2dc2433 commit d160b7b

File tree

1 file changed

+1
-1
lines changed
  • src/torchjd/autojac/_transform

1 file changed

+1
-1
lines changed

src/torchjd/autojac/_transform/init.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,6 @@ def __call__(self, input: EmptyTensorDict) -> Gradients:
2222
return Gradients({value: torch.ones_like(value) for value in self.values})
2323

2424
def check_keys(self, input_keys: set[Tensor]) -> set[Tensor]:
25-
if input_keys == set():
25+
if not input_keys == set():
2626
raise RequirementError(f"The input_keys should be the empty set. Found {input_keys}.")
2727
return self.values

0 commit comments

Comments
 (0)