openml-python
openml-python copied to clipboard
Set default value of avoid_duplicate_runs to false for run_model_on_task
Reference Issue
Closes #1143
What does this PR implement/fix? Explain your changes.
Sets the default value of avoid_duplicate_runs in the run_model_on_task function to False. When true, this option avoids running an experiment that already exists on OpenML, but this requires an API key. This change means that an API key is not required unless explicitly setting avoid_duplicate_runs to true.
How should this PR be tested?
Tested that without an API key, the following code block does not return a 401 error any more after this change has been made.
from sklearn import ensemble
from openml import tasks, runs
clf = ensemble.RandomForestClassifier()
task = tasks.get_task(3954)
run = runs.run_model_on_task(clf, task)
I don't believe that an automated test should be required as we are just changing a default value and not changing any implementation, but please let me know if otherwise and I will add a test.