unable to save jupyter notebook on vs code - python

on vs code (last version) I can create a new jupyter notebook typing:
'Jupyter: Create New Jupyter Notebook'
but then I can't save it as I don't have the extension ipynb on the saving window.
If I try with python or json extension it doesn't work
I have python and jupyter modules installed
I have on an other computer vs code (an other and I don't have this problem
I have uninstall module jupyter and reinstall it (version v2022.2.1030672458) with no sucess
do you know what it could be?

Related

How can I add shared library in anaconda?

When I use python command, I can import library (boost.python) from code if .so files are stored in the same folder as .py script. How I can do this with anaconda and Jupyter Notebook?
Anaconda has a shell interface called “Anaconda Prompt”
inside the prompt, just use the following command:
conda install <yourPackageName>
and it will be available for your jupyter notebook
https://francescolelli.info/python/install-anaconda-and-import-libraries-into-the-ide/

How to open ipynb files on a Mac?

How to open an .ipynb file on a Mac and use it?
Which apps is needed for that or what are your recommendations?
you need to install jupyter you can do it using: pip install jupyter
and run it in terminal with the command jupyter notebook this will open a browser window where you can view and run juputer notebooks
You can also open these notebooks in pyCharm and Visual Studio Code (after installing the python extension from microsoft)
You tagged this with visual-studio-code so I'm answering in the context of Visual Studio Code.
VS Code has support for creating, opening/viewing, and running Jupyter notebooks (.ipynb files). Check out their complete tutorial from the VS Code docs: Working with Jupyter Notebooks in Visual Studio Code.
Visual Studio Code supports working with Jupyter Notebooks natively,
as well as through Python code files. This topic covers the native
support available for Jupyter Notebooks and demonstrates how to:
Create, open, and save Jupyter Notebooks
Work with Jupyter code cells
View, inspect, and filter variables using the Variable explorer and Data viewer
Connect to a remote Jupyter server
Debug a Jupyter notebook
If you just want to view/open a .ipynb file, just open it in VS Code like any other file.
If it doesn't open like that and you get a "weird" JSON-like file, make sure the setting "Jupyter: Use Notebook Editor" is enabled.
"jupyter.useNotebookEditor": true
If you need to be running cells, you'll need to setup your environment and install the Jupyter package.
You can let VS Code do all the initial setup steps for you. Open or create a .ipynb file, and try to run any cell. If your environment is not yet setup, it will show an error:
So click on that Install button to let VS Code install all the dependencies on the currently selected Python environment.
Or if you want to install it yourself, select and activate an environment, then:
$ pip install jupyter
Once the Jupyter package is now installed, you'll see that the "Jupyter Server" indicator at the top right is now activate. Now, you can run cells.
So basically, all you need to do is:
Install VS Code
Setup a Python environment
On mac OS, it already has Python 2 but I recommend not using that
Instead, I recommend installing Python 3 via Homebrew
Install the Jupyter package
Select the Python environment (with the Jupyter package)
Open and edit .ipynb files
To quickly view an .ipynb file you can use the nbviewer-app.
Installation via Homebrew:
$ brew install --cask jupyter-notebook-viewer
Alternatively, you can also download the app directly.
Starting with Mac OS Catalina, you might have to open a terminal and run
xattr -d com.apple.quarantine /Applications/Jupyter\ Notebook\ Viewer.app
after installation because the app is not notarized by Apple [Source].

Jupyter Lab auto nbconvert to python setting?

On my work computer I set Jupyter Lab to auto-convert notebooks to python .py, so both the notebook and .py script are autosaved.
But having installed Jupyter Lab on my home computer, strangely I don't see that setting or option.
I also conda installed nbconvert in case it's a required package but that didn't help.

Delete 'Python Interactive' environment created by VSCode inside Jupyter?

I ran some jupyter notebook using VSCode. However, VSCode created some 'Python Interactive' environment which appears in my Jupyter Notebook. How do I remove them?
Sorry that's a bug in the python extension.
To delete them you can follow the directions here:
remove kernel on jupyter notebook
They're just json files in a directory that Jupyter maintains. The VS Code python extension created them to get our kernel to work.
If you still see these after deleting using jupyter kernelspec uninstall unwanted-kernal, you can clear these by uninstalling and then reinstalling your Jupyter extension in VSCode.
In VSCode, click the 'extensions' icon, then search 'Jupyter'. Uninstall it. Then install it.

Unable to open Jupyter notebook in AWS

I have created a free ubuntu instances on AWS ec2. I have installed jupyter notebook using command pip install jupyter. Please refer the screen shot showing
But while I'm trying to run jupyter notebook or jupyter notebook --generate-config, I'm getting error message as Command 'jupyter' not found. Can you please help me resolve this issue?
I use Jupyter too but I installed it completely different. You can install Anaconda3 which is used for python very often. From there, you can open the Anaconda3 prompt and use the simple command jupyter notebook to open it.

Categories

Resources