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

RuntimeError: Tune is not installed, so get_tune_resources is not supported. You can install Ray Tune via pip install ray[tune]. #313

Open
ksneab7 opened this issue Jul 11, 2024 · 1 comment

Comments

@ksneab7
Copy link

ksneab7 commented Jul 11, 2024

Problem

When running the example code for ray.tune integration in the readme,
The script successfully exectures from ray import tune but fails on the line resources_per_trial=ray_params.get_tune_resources())
I think this is due to the TUNE_INSTALLED global set in the xgboost_ray/tune.py file.

It seems that line 15 in that script (from ray.tune import is_session_enabled) is failing due to ray.tune not having that attribute.

Steps to reproduce:

in this section of the readme

Error

Traceback (most recent call last):
  File "./testing_ray_data_load.py", line 46, in <module>
    resources_per_trial=ray_params.get_tune_resources())
                        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "./venv/lib/python3.11/site-packages/xgboost_ray/main.py", line 484, in get_tune_resources
    return _get_tune_resources(
           ^^^^^^^^^^^^^^^^^^^^
  File "./venv/lib/python3.11/site-packages/xgboost_ray/tune.py", line 180, in _get_tune_resources
    raise RuntimeError(
RuntimeError: Tune is not installed, so `get_tune_resources` is not supported. You can install Ray Tune via `pip install ray[tune]`.
@littlethumb123
Copy link

Came across the same issue and reinstall Ray didn't help.

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

2 participants