Error Running Jupyter Notebook on Pycharm - python

This is my first stack overflow question, so I hope it is comprehensible.
I have a neural net from a couple of years ago on a flash drive. I made it on a windows computer and am now trying to run it on a mac. When I try to run the program it asked for my token, I canceled and clicked run jupyter notebook in the pop up (as was directed at https://www.jetbrains.com/help/pycharm/running-ipython-notebook-cells.html). But when I clicked run jupyter notebook it gave me this error:
Error running 'Building Neural Networks': Cannot run program
"C:/Users/myusername/AppData/Local/Programs/Python/Python36-
32/python.exe" (in directory "/Volumes/myflashdrive/Building Neural
Networks"): error=2, No such file or directory
it seems like there is some error because it was made on a windows, but I can't find where I can fix it. I am able to use jupyter notebook on projects not from the flash drive. Thanks.

Related

Can i work locally on VS Code with a virtual environment while ssh'ed to google colab

I want to know if it's possible to work in a virtual environment while ssh'ed to google colab. I tried ssh'ing to google colab and did it but when I was going to code a .ipynb file I needed to select the kernel and when I tried selecting the one from my Conda Virtual Environment it did nothing. Wanted to know if it's possible or if I did something wrong. If you know some guide or video that teaches how to do this link it if possible, I already searched but found nothing. Thanks
After ssh'ing to google colab i tried inserting my conda env kernel in the VS Code kernel button but it did nothing so i couldn't run my .ipynb file
I'm not sure if it helps, but if you want to work on a running Jupyter server using VScode, you need to connect to that remote jupyter server.
Here's the link to doc https://code.visualstudio.com/docs/datascience/jupyter-notebooks#_connect-to-a-remote-jupyter-server
But also I'm not sure if collab supports plugins which vscode needs to install to run Jupyter remotely. But you should definitely try and install the Jupyter add-on first.

Can´t make jupyter notebook work in Anaconda

On my windows PC, i have Anaconda installed, but today i could not open Jupyter Notebook correctly. When i use these commands to set up an enviornment, i can open the Jupyter notebook.
conda activate [name_of_the_environment]
jupyter notebook
The error occurs when internet explorer opens the Jupyter notebook, because i can't access to my ipynb files or any other. The page just stays like this (in blanc, like it does not end loading):
Internet explorer general site
Trying to open a file
I am not having any connection problems and this happens regardless of the file size.
I also tried updating Anaconda, but it didn´t work.
Code written in the terminal:
Code

My jupyter notebook refuses to open in VS Code

I use Jupyter Notebooks through my browser but have recently started to use Visual Studio Code for a lot of my coding. I have created a virtual environment and installed pandas, started VScode and tried to run a single line of code and I keep getting this error.
Failed to start Jupyter in the environment 'Python 3.9.5 64-bit (/opt/homebrew/opt/python#3.9/bin/python3.9)'.
View Jupyter [log](command:jupyter.viewOutput) for further details.
I can not solve this and I have no idea where to go to ask for help. Can anyone get me through this?

Google Colab Unrecognized Runtime

This might be a dumb question but I'm using Google Colab to host notebooks for my students. I create the notebooks in a local Anaconda Python 3 environment, and when I upload them to Google Colab this warning pops up:
I know that it won't cause problems, and the notebook will run just fine. But is there a way to change the the notebook runtime to Python 3 so my students don't see this message and panic?
You can open the notebook with a text editor. It's just a json file.
You can edit it, change conda-env-py3-py to python3

Jupyter Notebooks in VS Code using WSL 2 are not working

I want to use Jupyter Notebooks inside VS Code running within WSL 2. Regular Python works within WSL without a problem, that means the base conda enviroment is connected and I can run .py files. Moreover, I’m able to run the command jupyter notebook which will start the notebook server within WSL exposing the localhost to the Windows system.
However, I want to test the new Jupyter Notebook feature within VS Code, which is not working for me; VS Code shows: Jupyter Server: No Kernel and Python: Not Started (see screenshot below).
My testing machine is:
WSL 2 (using Pengwin distribution) on Windows 20H1 (19041.21)
VS Code 1.41 (having the Python extension installed)
Anaconda
What I did:
Open WSL
Open VS Code in my target directory (code .)
Create a new Notebook file from the command palette Python: Create New Blank Jupyter Notebook
Create dummy print("test")
Run Cell will trigger the warning:
Is there anything I’m missing?
The VS Code insiders actually works out of box with Jupyter notebooks. Just remember to run code-insiders . instead of code ..
Another solution would be, according to this website, start the VS Code in windows, then use WSL 2 as a remote server.
The code installation on wsl2 needs a restart to work properly, I was told by a notification, and in the question's comments you may see people experiencing the same issue(' it's working now. not sure why'). So before looking upon any elaborate solution, just restart code.

Categories

Resources