Cristopher Roach wrote the blog of "Running Jupyter Lab as a Desktop Application" for Mac users. It did not work for Anaconda users in Windows 10. Eventually, what I did is the below:
Many steps were required to go through. Is there any simpler way?
Standalone and self-containedJupyterLab App is the cross-platform standalone application distribution of JupyterLab. It is a self-contained desktop application which bundles a Python environment with several popular Python libraries ready to use in scientific computing and data science workflows.
Run Anaconda Prompt from your Start menu and type:
jupyter lab --generate-config
Use your favorite text editor to open the Jupyter config file found on this location:
C:\Users\<User>\.jupyter\jupyter_notebook_config.py
Add this line to the end of the config file:
c.NotebookApp.browser = "C:/Program Files (x86)/Google/Chrome/Application/chrome.exe --app=%s"
Navigate to
"C:\Users\Serendipity\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\Anaconda3 (64-bit)"
Make a copy of the Jupyter Notebook shortcut and name it Jupyter Lab
Right click the newly created Jupyter Lab shortcut and go to Properties, change the icon to your downloaded icon, change the comment field to say "Jupyter Lab". On the Target field, where it says jupyter-notebook-script.py
, change it to jupyter-lab-script.py
.
The Target field should look like this:
C:\Users\Serendipity\Anaconda3\python.exe C:\Users\Serendipity\Anaconda3\cwp.py C:\Users\Serendipity\Anaconda3 C:\Users\Serendipity\Anaconda3\python.exe C:\Users\Serendipity\Anaconda3\Scripts\jupyter-lab-script.py %USERPROFILE%
Run the shortcut, it should spawn a command prompt running the server instance, and the Jupyter Lab Chrome App window.
You can create a shortcut to connect to a local server with Right Click->New>Shortcut and using this as location target:
"C:\Program Files (x86)\Google\Chrome\Application\chrome.exe" --app=http://localhost:8888/
You can also start a server without spawning the Chrome App window by typing jupyter lab --no-browser
into the Anaconda Prompt console.
First write this command it will ask to overwrite please say yes:
Jupyter lab --generate-config
Then open this notebook_config.py file from this location
C:\Users\username\.jupyter\jupyter_notebook_config.py
Paste this line at the end of the file and save it. Note that you might want/have to change the location depending on the .exe
(here I will be using the browser Chrome)
c.NotebookApp.browser = "C:/Program Files (x86)/Google/Chrome/Application/chrome.exe --app=%s"
Run the jupyter lab from the command line
For more info follow this link
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With