I want to change the color of reporter in jupyter kernel of VSCode

Thank you for checking this topic.

I used this library with Jupyter kernel implemented in VS Code.

When I run the tutorial code (tune_basic_example — Ray 2.3.1), I found that the reporter of its results was difficult to read as you can see below the figure.

Would you please let me know how to solve this problem?

Of course, if the background color of VSCode was white, the reporter became easy to read. But, I want to use it with dark mode.

Thank you in advance.

How severe does this issue affect your experience of using Ray?

  • Low: It annoys or frustrates me for a moment.

I don’t think we do anything in reporter code to set the color. Maybe you wanna check how to set the correct theme for jupyternotebook in vscode.

Anyone figure out how to fix this?

The following works for me with tune.run, wrapping it in a white background:

%%writefile custom.css
/* custom.css */

/* Set background color for all widgets */
.tuneStatus {
    /* white background */
    background-color: #ffffff;
}

Then in another cell

from IPython.display import display, HTML

# Load custom CSS file
css = HTML('<link rel="stylesheet" type="text/css" href="./custom.css">') # make sure the path is correct, it fails silently otherwise
display(css)

def objective(config):
    return -1

from ray import tune
tune.run(
    objective,
    config = {"aa": tune.uniform(0, 1)},
)

For other ray progress reports, take a look at the widgets in <python_pkg_dir>/ray/widgets/templates/tune_status_messages.html.j2