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

Design test procedures for examples/ #245

Open
FilipBolt opened this issue Dec 18, 2020 · 7 comments
Open

Design test procedures for examples/ #245

FilipBolt opened this issue Dec 18, 2020 · 7 comments

Comments

@FilipBolt
Copy link
Collaborator

We need a way to automatically test examples to ensure they work with framework core changes. One solution would be marking these tests can be marked with slow to avoid running them each time. Also, dataset loading and downloading, training models and similar slow running operations should all be mocked (perhaps a set of mocking tools can be created)

@mariosasko
Copy link
Collaborator

Currently, the test examples are not part of the docs and some of them are outdated.

When we add them, it shouldn't be too hard to implement automatic execution of these examples as part of the existing test suite. Not sure about the mocking tool, think this is a long term goal (probably because I'm not a big fan of mocking). Ideally, we would have an external runner (e.g. TakeLab server) connected to CI that runs slow examples if the file content is changed/new files are added. This means we would need the server only from time to time. IMO, these examples (only BERT comes to my mind) are "slow", but not that slow to mock parts of them.

@FilipBolt
Copy link
Collaborator Author

This sounds fantastic, if we could setup a CI that detects changes and runs only in those cases. We could probably get away without mocking whatsoever, which sounds great.

I'd say the docs are a separate issue (though a valid point), so I wouldn't like to expand this issue too much.

@ivansmokovic
Copy link
Collaborator

ivansmokovic commented Dec 23, 2020

How would we go about checking the correctness of non-deterministic parts of the examples, e.g. training of a model, which should be a fairly common example case? I see breaking examples into subfunctions and testing those subfunctions separately as a good first step, but would that impact the "esthetics" of the examples?

@mttk
Copy link
Member

mttk commented Dec 23, 2020

We can either fix training of the model (you can make it deterministic at the cost of speed) or simply not care about performance metrics (unless they are relevant) as long as the training completes.

@ivansmokovic
Copy link
Collaborator

We can either fix training of the model (you can make it deterministic at the cost of speed) or simply not care about performance metrics (unless they are relevant) as long as the training completes.

But can we guarantee the correctness of training examples?

@mttk
Copy link
Member

mttk commented Jan 8, 2021

We can either fix training of the model (you can make it deterministic at the cost of speed) or simply not care about performance metrics (unless they are relevant) as long as the training completes.

But can we guarantee the correctness of training examples?

Not sure what you mean by this.

I'd delegate this for post 1.1.0.

@mttk mttk mentioned this issue Mar 31, 2021
@mttk
Copy link
Member

mttk commented Apr 2, 2021

Will be closed via #318

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

No branches or pull requests

4 participants