ray-project / tune-sklearn

A drop-in replacement for Scikit-Learn’s GridSearchCV / RandomizedSearchCV -- but with cutting edge hyperparameter tuning techniques.
https://docs.ray.io/en/master/tune/api_docs/sklearn.html
Apache License 2.0
465 stars 52 forks source link

Pass local_dir parameter to search functions #55

Closed TiesdeKok closed 4 years ago

TiesdeKok commented 4 years ago

Problem: It doesn't appear possible to pass the local_dir parameter to the search functions in tune-sklearn. This causes the temporary files to be created in the default directory, which in my case is problematic due to file size/count constraints on my home directory.

Proposed solution: Allow the local_dir parameter to be passed to the functions, for example:

tune_search = TuneGridSearchCV(
    pipeline_svc,
    parameters,
    local_dir = '/.../',   # <-----
    max_iters=10, 
)

There might be an alternative method to achieve this that is already implemented, however, I was going by the following part of the Ray documentation: https://docs.ray.io/en/latest/tune/api_docs/logging.html?highlight=ray_results#log-directory

Thanks!

inventormc commented 4 years ago

Hey @TiesdeKok, thanks for reaching out! We don't currently have this implemented but we'll look into adding this.

TiesdeKok commented 4 years ago

Awesome, thanks a lot. Great package!