I installed VSCode and its remote SSH and Python extensions.
I connected to a remote server, let’s say by ssh user_name@ip_address
.
Now, in the remote server, the path the folder with the Python packages I installed long time ago is: /home/user_name/.local/lib/python3.7/site-packages
.
How do I use them when I create a Python script in VSCode and, for example, try to import numpy as np
?
2
Answers
Press [control]+[shift]+[P] and type
Python: Select Interpreter
. Click the option that shows up and select the correct interpreter. Then your default environment should use that interpreter and all packages installed for it.You can add
"python": "path/to/python3.7"
inlaunch.json
then use debug mode.