Skip to content
Merged
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 6 additions & 3 deletions openml/tasks/task.py
Original file line number Diff line number Diff line change
Expand Up @@ -145,9 +145,12 @@ def _get_repr_body_fields(self) -> Sequence[tuple[str, str | int | list[str]]]:
]
return [(key, fields[key]) for key in order if key in fields]

def get_dataset(self) -> datasets.OpenMLDataset:
"""Download dataset associated with task."""
return datasets.get_dataset(self.dataset_id)
def get_dataset(self, /, **kwargs) -> datasets.OpenMLDataset:
Comment thread
PGijsbers marked this conversation as resolved.
Outdated
"""Download dataset associated with task.

Accepts the same keyword arguments as the `openml.datasets.get_dataset`.
"""
return datasets.get_dataset(self.dataset_id, **kwargs)

def get_train_test_split_indices(
self,
Expand Down