stockfishintraining
stockfishintraining

Reputation: 13

Background execution in Jupyter

notebook image

mcq_helper.py code

import ipywidgets as widgets
from IPython.display import display
import sys

output = widgets.Output()

if __name__ == '__main__':
    question = sys.argv[1]
    options = sys.argv[2:]
    with output:
        display(widgets.RadioButtons(options=options, description=question))
display(output)

I'm serving jupyterlab from my server. I would like to achieve the following:

  1. Instead of writing %run command in the cell explicitly, I want it to run by default every time a cell is executed.
  2. I want to hide the cell soon as it is executed, and only the output to be visible.

How can I do that?

Upvotes: 0

Views: 12

Answers (0)

Related Questions