Skip to content

Commit

Permalink
Fix type of y in RandomFeaturesPandasDataset
Browse files Browse the repository at this point in the history
  • Loading branch information
azoz01 committed Dec 5, 2023
1 parent 49a5d23 commit b0d853b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion liltab/data/datasets.py
Original file line number Diff line number Diff line change
Expand Up @@ -215,7 +215,7 @@ def __getitem__(self, idx: list[int]) -> tuple[Tensor, Tensor]:

X = torch.from_numpy(self.df[self.attributes].to_numpy()).type(torch.float32)
if self.encode_categorical_target:
y = self.y
y = torch.from_numpy(self.y).type(torch.float32)
else:
y = torch.from_numpy(self.df[self.responses].to_numpy()).type(torch.float32)

Expand Down

0 comments on commit b0d853b

Please sign in to comment.