Not able to use custom python environment
- Lingua principale
- Julia
- Stelle
- 1.5k
- Fork
- 186
- Metriche di merge delle PR
- Nessuna PR unita negli ultimi 30g
Descrizione
Hello, I'm on a mac m1 and have installed julia with the x86_64 arch. I also have a working python environment using the same arch. I tried building PyCall as mentioned in the readme to use a custom python environment where I have some libraries installed. However, I get an error. Here's the building procedure and attempt to use Pycall:
```julia
julia> ENV["PYTHON"] = "/Users/vladimirvargas/.local/share/virtualenvs/physics-jfSzH1Jb/bin/python"
"/Users/vladimirvargas/.local/share/virtualenvs/physics-jfSzH1Jb/bin/python"
julia> using Pkg; Pkg.build("PyCall")
Building Conda ─→ `~/.julia/scratchspaces/44cfe95a-1eb2-52ea-b672-e2afdf69b78f/6cdc8832ba11c7695f494c9d9a1c31e90959ce0f/build.log`
Building PyCall → `~/.julia/scratchspaces/44cfe95a-1eb2-52ea-b672-e2afdf69b78f/71fd4022ecd0c6d20180e23ff1b3e05a143959c2/build.log`
julia> using PyCall
julia> nk = pyimport("netket")
Assertion failed: (findOption(Name) == Values.size() && "Option already exists!"), function addLiteralOption, file /Users/ci/miniconda3/conda-bld/llvmdev_1601977477900/work/include/llvm/Support/CommandLine.h, line 853.
signal (6): Abort trap: 6
in expression starting at REPL[4]:1
__pthread_kill at /usr/lib/system/libsystem_kernel.dylib (unknown line)
Allocations: 3683833 (Pool: 3681426; Big: 2407); GC: 4
[1] 25372 abort julia
```
From the assertion message it seems that somehow PyCall is looking into some miniconda stuff. I don't know why this is the case since my python environment has nothing to do with conda: it is a pipenv environment.
Guida per i contributori
Nessuna guida per i contributori indicizzata per questo repository
Direzione di ricerca
Start with the PyCall README section on configuring a custom Python environment, then reproduce the reported ENV["PYTHON"], Pkg.build("PyCall"), and pyimport("netket") sequence on the stated macOS M1 setup. Check the PyCall and build logs for why miniconda paths appear; done means the configured pipenv Python can be imported without the LLVM assertion.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Valutazione
- Stack tecnologico
- julia, python
- Ambito
- tooling
- Tipo di issue
- Bug
- Difficoltà
- 4/5
- Tempo stimato
- 3-5 giorni
- Stato di attività
- Ferma
- Chiarezza
- Abbastanza chiara
- Idoneità per principianti
- 35/100