From 847c433304d4233da1311c92a04bb75bf76a5b8f Mon Sep 17 00:00:00 2001 From: Ankita Katiyar <110245118+ankatiyar@users.noreply.github.com> Date: Thu, 9 Jan 2025 12:21:58 +0000 Subject: [PATCH] Document the convention for filepath related attributes in custom dataset creation (#4403) * Document the magic behaviour of filepath attributes Signed-off-by: Ankita Katiyar * pin vale Signed-off-by: Ankita Katiyar --------- Signed-off-by: Ankita Katiyar --- .github/workflows/docs-language-linter.yml | 1 + docs/source/data/how_to_create_a_custom_dataset.md | 4 ++++ 2 files changed, 5 insertions(+) diff --git a/.github/workflows/docs-language-linter.yml b/.github/workflows/docs-language-linter.yml index 93e1ce9c67..ebdf5c3528 100644 --- a/.github/workflows/docs-language-linter.yml +++ b/.github/workflows/docs-language-linter.yml @@ -15,3 +15,4 @@ jobs: - uses: errata-ai/vale-action@reviewdog with: reporter: github-pr-check + version: 3.9.2 # temp diff --git a/docs/source/data/how_to_create_a_custom_dataset.md b/docs/source/data/how_to_create_a_custom_dataset.md index 7f39987dd7..43536fbf82 100644 --- a/docs/source/data/how_to_create_a_custom_dataset.md +++ b/docs/source/data/how_to_create_a_custom_dataset.md @@ -40,6 +40,10 @@ This typing is optional however, and defaults to `Any` type. The `_EPHEMERAL` boolean attribute in `AbstractDataset` indicates if a dataset is persistent. For example, in the case of {py:class}`~kedro.io.MemoryDataset`, which is not persistent, it is set to True. By default, `_EPHEMERAL` is set to False. +```{note} +The parameter to specify the location of the data file/folder must be called either `filename`, `filepath`, or `path` in the constructor function of the custom dataset class to comply with the Kedro convention. +``` + Here is an example skeleton for `ImageDataset`: