25,074 questions
0
votes
0
answers
22
views
Whitespace at the bottom of Jupyter Notebooks in Pycharm 2025.2.5
I switched from using JupyterLab in my browser to Jupyter Notebooks in Pycharm itself since it has improved since my last version. However, I find it quite disturbing that there is a lot of whitespace ...
0
votes
0
answers
27
views
Matplotlib simple plot rendering is way off [closed]
When displaying a plot via Jupyter Notebook in VSC (newest version, 1.106.3) the graph is getting rendered in the right upper corner, and the labels in the lower left corner. I already restarted VSC ...
0
votes
1
answer
56
views
If I do a magic command, %run file, does that run the script as main? If so how do I get around this?
I have a .ipynb file and want to only import certain functions from it to another .ipynb file.
if I use:
if __name__ == "__main__":
would the script run what is under that if statement ...
0
votes
1
answer
35
views
How to run jupyter notebook using docker? [closed]
I try to run jupiter notebook with docker. I run this in my terminal:
docker run -it -v $(pwd):/home/optimus/localwork --workdir /home/optimus/localwork -p 8888:8888 optimuslib/optimus:latest
I ...
0
votes
0
answers
34
views
I am using JupyterLite to run some python code. And there is a specific cell which is not executing as desired
When I run the cell below, and there is no file with the same name as filename, it executes perfectly. But on subsequent runs, if there exists a file with the same name, the kernel gets busy and ...
0
votes
0
answers
55
views
Rendering matplotlib figure in VSCode (Jupyter) like fig.savefig
Problem
When saving a matplotlib figure using fig.savefig(), the figure looks different from when the figure is rendered in a Jupyter Notebook.
Question
How can I render a static (non-interactive) ...
1
vote
0
answers
81
views
How to download the output folder on Kaggle?
I wrote a notebook on Kaggle and imported a dataset.
The main content of the notebook is as follows:
%%bash
pip install xxx # Install dependencies
if [ ! -d "/kaggle/working/latex-ocr-...
0
votes
0
answers
40
views
Dask distributed stores old version of my code
I am analysing some data using dask distributed on a SLURM cluster. I am also using jupyter notebook. I am changing my codebase frequently and running jobs. Recently, a lot of my jobs started to crash....
0
votes
1
answer
132
views
How to modify a Python function to handle one, several, or all parameters in a dictionary
I want to setup an environment in a Jupyter notebook where parameters are stored in a dictionary parValue and where you can change values of one or several parameters with a function par(), while ...
1
vote
0
answers
159
views
Transformers 'could not import module pipeline' to jupyter notebook
I need to to run a series of pre-trained fine-tuned models from Hugging Face to Jupyter notebook. I have updated to the latest version of both PyTorch and Transformers, but when I run the code
from ...
0
votes
1
answer
105
views
Slicing pandas dataframe with a value from a Jupyter widget raises an error
In a Jupyter Notebook, I make use of a Jupyter Widget to interact with a function.
The widget gives me a dropdown that can cycle through some plots, and its options are retrieved from a dataframe.
...
1
vote
0
answers
76
views
Passing the font-size to Quarto
I'm having a problem passing the font size that I chose within the itables package to be the font size that Quarto will use for that specific table. What I'm doing currently is
options.lengthMenu = [5]...
1
vote
0
answers
98
views
Jupyter notebook stuck in [*] for a day
In the Umbrella-sampling gromacs tutorial jupyter notebook, it stuck in running gmx mdrun for a day. Is it supposed to be like this?
This is the gromacs tutorial jupyter notebook cell for running gmx ...
0
votes
1
answer
55
views
Jupyter Markdown hyperlink with <style> does not show color
Can someone help explain what is going on, and how to fix it so I don't have too put a <span> in every link.
I am actually writing some .md files and using Juypter to display it in its final ...
0
votes
1
answer
78
views
Issue with pygame-ce in the Jupyter Notebook Demo
Every time I run any pygame code in Jupyter Notebook (the online demo) it just crashes, giving an error that I've looked for everywhere, to no avail. I'm using the Pyodide Kernel, which apparently ...
0
votes
0
answers
70
views
Strands Tools not working in Jupyter "Lookup Error:ContextVar name='parent_header'"
I have just tried a lot of things but i can't fix it. I am trying to run a simple strands tool calculator in 3 different jupyter environments and I always get the same error
"Error: LookupError ...
3
votes
1
answer
63
views
I would like to know how to configure jupyter notebook to display dot-files in the file browser
I regularly run jupyter notebook for tinkering with python projects (usually related to data analytics). It would be helpful if the jupyter "Home" page (the file system browser window) would ...
2
votes
0
answers
60
views
Python package to compute ekman velocities in the water column from observations? [closed]
Is there any python package to compute ekman velocities in the water column from wind data observations? I have wind direction and velocity on an specific location and I would like to obtain a ...
3
votes
2
answers
150
views
FuncAnimation not rendering in Jupyter and VSCode
import matplotlib.pyplot as plt
from matplotlib.animation import FuncAnimation
#plt.rcParams["animation.html"] = "jshtml"
import matplotlib.pyplot as plt
fig, ax = plt.subplots(...
1
vote
0
answers
198
views
Jupyter/VSCode does not recognize pip from .venv despite being properly installed
EDIT: the issue is resolved (kinda). Check GitHub discussion. It turns out that there are possibly two problematic factors. First (my case), the newest version of Jupyter extension. When I switched ...
0
votes
1
answer
107
views
"[Errno 28] No space left on device" when trying to save a jupyter notebook
I'm currently working on a thesis project using jupyter notebook on a remote cluster. After running my code I'm not able to save anything anymore and I keep getting the following error:[Errno 28] No ...
2
votes
2
answers
131
views
Jupyter in Visual Studio Code shows “requires the pip, jupyter and notebook package” even though they are installed
I’m trying to run a .ipynb notebook in VS Code with Python 3.11.0. I have already installed the Jupyter extension and Python extension in VS Code. Everything works fine when I run the same code as a ....
16
votes
2
answers
4k
views
Jupyter Notebook extension Visual Studio Code stuck "connecting to kernel"
I use Python 3.11.1 and Jupyter Notebook to run code selections or lines in the Interactive Window for debugging or coding purposes.
A few days ago, everything was working fine, and I didn't have any ...
-1
votes
1
answer
46
views
Jupyter Dependency Issue
Following an update of Python and Jupyter extensions on my VS Code yesterday, my virtual environment dependencies haven't been working properly. My Vscode setup has been demanding that I install ...
2
votes
1
answer
312
views
VSCode: Running cells with '.venv (Python 3.13.5)' requires the ipykernel and pip package
I'm using VSCode version 1.105.0. I want to run some Python code in Jupyter Notebook. To do this, I need to install ipykernel, which I do after activating venv (pip install ipykernel). Next, I execute ...
7
votes
2
answers
2k
views
VS Code Jupyter extension fails to activate: "Typ"eError: this.vscNotebook.onDidChangeNotebookCellExecutionState is not a function
So recently I wanted to work with Jupyter notebooks in VS Code, but I ran into an activation error with the Jupyter extension.
I’m using:
VS Code version: 1.104.3
Jupyter extension version: 2025.8.0
...
-1
votes
1
answer
59
views
Why does changing a DataFrame in one Jupyter cell also change another variable? [duplicate]
I am working in Jupyter Notebook with pandas, and I noticed something strange.
In one cell , I did this:
import pandas as pd
df1 = pd.DataFrame({"A":[1,2,3]})
df2 = df1
Then in another ...
0
votes
0
answers
52
views
Unable to make python virtual env work with jupyter
I followed the instructions from https://stackoverflow.com/a/58134257/31654471:
(qiskit) C:\Users\erick> ipython kernel install --user --name=qiskit
Installed kernelspec qiskit in C:\Users\erick\...
0
votes
1
answer
34
views
How to prevent markdown headings in a Jupyter Notebook (VSCode or JupyterLab) from appearing in the Table of Contents (TOC)
In Jupyter Notebooks (both in VS Code and JupyterLab), every markdown heading (like #, ##, etc.) automatically appears in the Table of Contents (TOC) or Outline view.
Sometimes, I want to include ...
1
vote
0
answers
61
views
How to programmatically set a default Jupyter kernel in VSCode integration tests?
We're developing a VSCode extension that works with Jupyter notebooks and need to run integration tests in CI/CD. The main issue is that when running integration tests, VSCode prompts the user to ...
0
votes
1
answer
124
views
How to export a Jupyter Notebook with plots and rich formatting to PDF without losing formatting?
I am using Jupyter Notebook inside an Anaconda virtual environment and I have a notebook with multiple plots using matplotlib and pandas DataFrames with styled formatting.
When I try to export the ...
0
votes
1
answer
75
views
Running flake8 linter in JupyterLab, getting E303 false positives
My goal is to have a PEP8 linter that highlights style violations while I'm editing Python notebooks on my Windows 10 computer.
I've installed pylsp as a JupyterLab extension. It's working, except ...
2
votes
1
answer
106
views
How to clear output from all cells?
With iPython, is there any way to clear output from all cells? I am looking for a command that can do it in one shot.
I see that clear_out like below can do the cleaning work, but it works for one ...
0
votes
1
answer
61
views
Jupyter notebook shell command/line magic failure does not cause cell failure
I'm using a Jupyter notebook as a tutorial for a command-line tool. However, I noticed that regardless of whether I use a shell command (!) or line magic (%), an error does not cause the cell to fail, ...
1
vote
1
answer
132
views
How to fix Jupyter Lab installation on Windows 11 (using powershell)?
On Windows 11 I had jupyter lab running before (on PowerShell), but now it seems to be gone. I installed and reinstalled jupyter lab:
pip uninstall jupyterlab
pip install jupyterlab
but this does not ...
-1
votes
1
answer
57
views
Jupyter notebook memory overhead [closed]
Every Jupyter notebook I open seems to use a constant 900-1200 MB of RAM continuously. Where is most of this overhead coming from? It seems to be relatively independent of the contents of the notebook,...
2
votes
1
answer
78
views
Jupyter notebook always return errors when loading an xlsx file
I'm taking an online course, and I was trying to follow this code from the instructor. But I alway get an error message. This is the code I tried:
import pandas as pd
# Replace 'your_excel_file.xlsx' ...
0
votes
0
answers
53
views
Problem with publishing Jupyter Notebook online
I am currently working on an interactive UI in Jupyter Notebook based mainly on IPy Widgets to feature 3D interactive models created and exported previously using Blender. I used an HTML 3D model ...
0
votes
0
answers
55
views
Confusion about virtual environment and kernels in jupyter notebook
I created a virtual environment called "fastai" by conda. I tried to install ipywidgets in it by
mamba install ipywidgets
Then I checked it and it did exist. But when I used
jupyter --...
2
votes
1
answer
221
views
Error when opening Jupyter notebook from cmd/power shell (Windows)
[Problem solved] When I try to open jupyter notebook in cmd/power shell I get the following error:
Fatal error in launcher: Unable to create process using '"c:\users\NAME\appdata\local\programs\...
0
votes
1
answer
296
views
How to deal with "DDGSException: No results found."
I tried to use DDGS to search for images in Jupyter Notebook with fastai, but the search seems to be not very stable. Most of time there turned out to be an ERROR:DDGSException: No results found.I ...
0
votes
0
answers
31
views
ipywidgets intractive_output function is being called many times
When invoking interactive_output in a python notebook, the function given to it is being called many times at each invokation.
This problem happens in the notebook editor of vscode. In collab it shows ...
2
votes
1
answer
102
views
plotly cant plot scatter graphs anymore
I am using the update plotly version 6.3.0 and im trying to plot a simple stock close price in 1year period. The uploaded image is the graph output, how it can be seen its not right. Im also in ...
0
votes
0
answers
76
views
Getting a libusb windows access denied error when re-running a widget in Jupyter
Summary
I am trying to create a widget to read sensor data from a usb device within a Jupyter Notebook. I have tried both matplotlib ipywidgets, Dash-plotly, and Bokeh.
When re-executing the widget ...
0
votes
0
answers
50
views
Clear output then lose control of IPython debugger in jupyterhub notebook
So I import a module:
from IPython.core.debugger import Pdb
Then I initiate an object for debugging:
ipdb = Pdb()
I define a function to test debug mode:
def f(a=1):
ipdb.set_trace()
print(a)...
0
votes
0
answers
36
views
Can I show both File Browser and Table of Contents in the same sidebar in JupyterLab?
I'm using JupyterLab 4.4.5 and want to view both the File Browser and the Table of Contents at the same time in the sidebar. I don't want to move one to open two sidebars, I want both visible in the ...
0
votes
1
answer
65
views
No way to quit IPython debugger's interactive mode in jupyterhub notebook
So I import a module:
from IPython.core.debugger import Pdb
Then I initiate an object for debugging:
ipdb = Pdb()
I define a function to test debug mode:
def f(a=1):
ipdb.set_trace()
print(a)...
0
votes
0
answers
184
views
plt.imshow() causes Jupyter notebook kernel to crash
I'm following Karpathy's Makemore tutorial step by step. When I get to the part where he uses plt.imshow(N) to create a plot inside the notebook, my kernel crashes. I've been troubleshooting this for ...
0
votes
4
answers
174
views
How to find values appear the most
I have a dataframe that has the number 6 in each row. Which will be my main number I would like to use
to find values that appear most often with the number 6 that has more than 2 of the same values. ...
0
votes
1
answer
100
views
asyncio.run() raise "RuntimeError: Event loop is closed" in a Jupyter Notebook
I'm trying to run an async function inside a Jupyter Notebook using asyncio.run() like this:
import asyncio
async def my_task():
await asyncio.sleep(1)
return "Done"
asyncio.run(...