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

Difference between Dataset and Loader #46

Open
clegaard opened this issue Apr 19, 2020 · 1 comment
Open

Difference between Dataset and Loader #46

clegaard opened this issue Apr 19, 2020 · 1 comment
Labels
question Further information is requested

Comments

@clegaard
Copy link
Collaborator

What is the difference between a Dataset and a Loader? From a conceptual standpoint, a loader behaves exactly like a dataset. In terms of the implementation, it seems like the Loader simply wraps the dataset?

@clegaard clegaard added the question Further information is requested label Apr 19, 2020
@LukasHedegaard
Copy link
Owner

Now that Loader.extend was removed, you are right. It just wraps a function in a concrete ItemGetter class. We could remove it, but then all the other from_* functions would need to define the concrete ItemGetter. The alternative could be to extend the Dataset.__init__ to allow the parent to be a function. We could do this by moving the logic from Loader.__init__ into Dataset.__init__. The downside to this would be that we add more logic to an already complex function.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants