Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Create some pre-canned standard datasets like the h20 groupby dataset #256

Open
MrPowers opened this issue Mar 7, 2024 · 2 comments
Open
Assignees
Labels
enhancement New feature or request
Milestone

Comments

@MrPowers
Copy link

MrPowers commented Mar 7, 2024

Expected Behavior

It'd be nice to make some "standard" datasets easily accessible, so users don't have to figure out how to create them from scratch. For example, the datasets used in the h2o benchmarks here.

Here are three rows from the h2o groupby dataset:

Screenshot 2024-03-07 at 9 41 09 AM

It would be nice if I could generate this dataset as follows:

DataGenerator.h2o_groupby(spark, rows=1_000_000_000, partitions=10)

Current Behavior

I am guessing that there is some way to generate this dataset with the current API, but might take me a little while to figure it out.

@ronanstokes-db
Copy link
Contributor

ronanstokes-db commented Mar 21, 2024

This is a great idea

Here's what I would propose:

The API would look something like the following:

import dbldatagen as dg

# using hierarchical naming
df = dg.Datasets("basic/iot_like").get(table="primary",  rows=100000, numPartitions=4).build()
# or simply use 
df = dg.Datasets("basic/iot_like").get().build()

We could also have some documentation of the datasets available via APIs so that we would not have to revise the docs every time we add a new dataset - along the lines of how dbutils is self describing.

import dbldatagen as dg

dg.Datasets.list("<pattern>") # get summary details
db.Datasets.describe("basic/iot_like") # get detailed description of data set

# describe should indicate the tables available, defaults, what the data looks like etc

Initial datasets would be a) the data sets described in the documentation as examples, b) some curated set of datasets such as the H20 one you reference

To others reading this, feel free to suggest datasets

@ronanstokes-db ronanstokes-db self-assigned this Mar 21, 2024
@ronanstokes-db ronanstokes-db added the enhancement New feature or request label Mar 21, 2024
@ronanstokes-db ronanstokes-db added this to the v0.3.7 milestone Mar 21, 2024
@MrPowers
Copy link
Author

This looks like a great proposal! Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants