2

Has anyone had a problem running julia from a jupyter notebook?

I have looked at how-to pages like this one and this one, which all pretty much recommend the same series of steps:

  1. Open the terminal, launch Julia, and Pkg.add("IJulia").

I follow this step and got the following output

Resolving package versions... Updating `~/.julia/environments/v1.7/Project.toml` [7073ff75] + IJulia v1.23.3 Updating `~/.julia/environments/v1.7/Manifest.toml` [7073ff75] + IJulia v1.23.3 [b85f4697] + SoftGlobalScope v1.1.0 [c2297ded] + ZMQ v1.2.1 [8f1865be] + ZeroMQ_jll v4.3.4+0 [a9144af2] + libsodium_jll v1.0.20+0 
  1. Launch a Jupyter session and choose a Julia kernel.

I'm able to launch a Jupyter session. However, when I click new, all my option are Python kernels. I don't see anywhere to launch a Julia kernel.

Has anyone run into a similar problem??

I am running macOS Monterey, version 12.4, Apple M1 Max Chip.

My julia is 1.7.2

4 Answers 4

2

Try a different step 2:

julia> using IJulia julia> notebook() 

This should open Jupyter in a new browser/tab window. Do you see the Julia kernel in this window? (In which case you might just have different Jupyter versions installed on your system).

Sign up to request clarification or add additional context in comments.

Comments

0

you're probably using a jupyter notebook that didn't come with IJulia, thus, you will have to install a kernel spec (a JSON file) so the jupyter knows where to find Julia kernel.

Try following: https://julialang.github.io/IJulia.jl/stable/manual/installation/#Installing-IJulia

More specifically,

You can force it to use a specific jupyter installation by setting ENV["JUPYTER"] to the path of the jupyter program before running Pkg.build("IJulia")

Comments

0

That's probably because the Jupyter notebook you have installed doesn't have IJulia installed. You will have to load IJulia to access Jupyter with a Julia kernel to fix that.

julia> using IJulia julia> notebook() 

Comments

0

I had the same problem which was the result of having an older version of Jupyter. I solved it by uninstalling and reinstalling the latest jupyter, then added the R and Julia kernels from thw official R, through R Studio, and Julia sites respectively where each kernel installation did not take more than 2 minutes and all work well.

Good luck EK

Comments

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.