0

I am running a Jupyter Notebook on my laptop. Is it possible to run one/two cells of the script on a remote server that I have access to?

The remote server is more powerful, however I have been allocated a limited amount of storage on the server so the bulk of work has to happen on my device.

I have used OS.system to run a python script on the server from Jupyter on my laptop, but it seems inefficient.

Both devices are running Ubuntu.

James
  • 43
  • 4
  • You are conflagrating terms which makes things hard to follow. (Specifically, "Is it possible to run one/two cells of the script"? If you are triggering running a Python script, text file ending in '`.py`' extension, from inside a notebook then there's a chance it is easy to separate out. If you are indeed running Python code inside a notebook & want to only run the processing that occurs in two cells, then less likely without some work. Similar questions come up with, "used OS.system to run a python script on the server from Jupyter on my laptop"?) Perhaps provide more details/a toy example. – Wayne Jan 12 '23 at 16:22
  • [This post at the Jupyter Discourse Forum](https://discourse.jupyter.org/t/remote-execution-of-code-using-gpus-in-jupyter/15810/2) makes me think it isn't straightforward, but maybe I'm overlooking something since it that case it was CPUs vs some parts on GPUs. Your improved post may be better posted to that forum as well. Or maybe cross-posted with clear links to each place in **both**, that way there's no redundancy because someone on one forum is unaware of the other. .... There is also [remote-kernel](https://pypi.org/project/remote-kernel/). – Wayne Jan 12 '23 at 16:44
  • [This post](https://discourse.jupyter.org/t/how-to-connect-a-local-jupyterlab-notebook-to-a-remote-kernel/11781?u=fomightez) seems related maybe? Maybe [here](https://discourse.jupyter.org/t/single-user-setups-for-local-client-remote-kernel/13882) is overly complex but looks vaguely related. Plus more on remote-kernel [here](https://stackoverflow.com/a/30670602/8508004) and [here](https://stackoverflow.com/a/60094686/8508004). – Wayne Jan 12 '23 at 16:52

0 Answers0