What's the best way to install both Julia and Python-Miniconda?

I’m on Windows 11. My goal is to have a convenient installation of Python (via Miniconda) and Julia where both use Jupyter Notebook, and Julia can run Python via PyCall and Conda.jl.

Recently, I purged my entire Anaconda and Julia installation, aiming to start again, as Anaconda was too big and full of stuff I didn’t need. So I did the following: 1) downloaded and installed Miniconda using the default settings 2) installed Jupyter Notebook via conda 3) installed Julia and 4) installed IJulia.

When doing so, IJulia required me to install Jupyter Notebook again inside the installation directory of Julia (C:\Users\username\AppData\Local\Programs\Julia-1.8.5). I tried (with the help of ChatGPT) to get Julia to point to the existing installation of Jupyter Notebook, but that didn’t work.

So I fear I have a second installation of Jupyter Notebook in the Julia installation folder. In addition, I’m going through slide 9 of GitHub - JuliaAcademy/Introduction-to-Julia: Learn the language basics in this 10-part course. and it seems to have a step where I install conda inside the Julia installation folder. This seems another layer of redundancy.

Is it possible to start again, maybe install Julia first, then Miniconda and Python inside the same Julia installation folder? Or what’s the cleanest way to install Python and Julia with the stated aims of the first para? Thanks in advance.

In my experience, letting Julia manage its own Python installation saves much trouble and headache. So unless you have a very good reason for accessing your PythonCall environments externally (don’t use PyCall btw, PythonCall is newer), I would recommend avoiding it. This is especially true since PythonCall works with CondaPkg, which is basically conda but from the Julia console.

As for your Python install, you should probably replace (mini)conda with (micro)mamba, which does the same job but much much quicker.

Personally I have Python and Jupyter installed via Conda (well Mamba actually - recommended) and Julia installed via JuliaUp and they all work together fine.

I think you just need to ensure that your Conda environment is activated before you install the IJulia kernel.

That said, I never bother launching Jupyter from IJulia, I just launch it from the command line (in the Conda environment).

Hi, I guess I’d just like to save space (as my computer is low), so I’d like just one installation of Python. Is it possible for my computer’s only installation of Python to be managed by Julia inside the Julia installation directory?

It may depend on what else you want to do.

If you are combining Julia and Python in a single process, you may seriously want to consider installing julia from conda-forge if available on your platform:
https://anaconda.org/conda-forge/julia

I’ve been involved in GitHub - conda-forge/julia-feedstock: A conda-smithy repository for julia. that creates the above builds. It is a best effort attempt. There are some known issues.

Alternatively, you could also consider using python_jll.jl:

The reason for this is you may encounter a situation where Julia and Python are trying to load distinct versions of the same binary dependency. The only way to ensure compatibility is to have them built in the same binary environment.

If you are not combining them into the same process, then this not matter quite as much.

As separate processes, I recommend using mambaforge to install Python and juliaup to install Julia.

There is some additional work to do here and not quite enough people to make it happen.