0

while I'm training a model and the interpreter busy, is there a way that I can run another file on a new window or something.

I'm training a model here and the interpreter is busy

I want to code and test things on the commandline/python interpreter while the server is busy training my model.

Thanks, Chung

Additional img: Trying to run 'import time' from the editor as training the model and the command is queued to the already-busy terminal instead of the split one

Kim Chung
  • 15
  • 5

2 Answers2

1

As you take the Shift+Enter shortcut to execute the Run Selection/Line in Terminal command.

The VSCode will create a Terminal named Python to execute all the commands from Run Selection/Line in Terminal command.

If you want to avoid it. You need to create a new terminal and execute the python file manually instead of the shortcut command.

enter image description here

Steven-MSFT
  • 7,438
  • 1
  • 5
  • 13
0

You can simply open a new terminal by clicking the + sign on the top right-hand corner of the terminal panel. This will open another terminal that you can use to run commands.

If you would like to have them side by side, you may click the split terminal sign next to the + sign to open another terminal next to the current running terminal too.

More on that in the VSC guide here

kennysliding
  • 2,783
  • 1
  • 10
  • 31
  • Hi, I tried that but when I try to 'shift + enter' the code on the editor, it tries to run it on the terminal that is already training the model, so the line doesn't run until the training is done. In the screenshot that I have added, I am trying to run 'import time' as training the model and it doesn't work even after I split the terminal. – Kim Chung Jun 07 '21 at 06:27