Skip to content

Commit

Permalink
Fix bug in HFExample algorithm
Browse files Browse the repository at this point in the history
Signed-off-by: Fabrice Normandin <[email protected]>
  • Loading branch information
lebrice committed Nov 15, 2024
1 parent 86de71e commit eb4fe5b
Showing 1 changed file with 0 additions and 3 deletions.
3 changes: 0 additions & 3 deletions project/algorithms/hf_example.py
Original file line number Diff line number Diff line change
Expand Up @@ -47,9 +47,6 @@ def __init__(
experiment_id=datetime.now().strftime("%d-%m-%Y_%H-%M-%S"),
)

# Small fix for the `device` property in LightningModule, which is CPU by default.
self._device = next((p.device for p in self.parameters()), torch.device("cpu"))

def forward(
self,
input_ids: torch.Tensor,
Expand Down

0 comments on commit eb4fe5b

Please sign in to comment.