Closed VolodyaCO closed 2 years ago
No idea. Why don't you open an issue over at NNLib.jl?
Besides, even if they fix it, I wrote this stuff years ago and it's most likely not compatible with recent versions unless you take the time to fix issues
I will open an issue there then. I really just want to use the hilbert and operator abstractions, though. I'm spending too much time calling get_conn
from netket
Thé get conn here I think is implemented sub-optimally and might be slow. I'd be curious to know how it performs.
But then you can just clone the repo and delete everything except those parts
@PhilipVinc I created a new environment and installed NNlib and NeuralQuantum by doing add NNlib
without any issue:
(Downloads) pkg> add NNlib
Updating registry at `~/.julia/registries/General.toml`
Resolving package versions...
Installed NNlib ─ v0.8.4
Updating `~/Downloads/Project.toml`
[872c559c] + NNlib v0.8.4
Updating `~/Downloads/Manifest.toml`
[79e6a3ab] + Adapt v3.3.3
[d360d2e6] + ChainRulesCore v1.14.0
[34da2185] + Compat v3.42.0
[872c559c] + NNlib v0.8.4
[ae029012] + Requires v1.3.0
[0dad84c5] + ArgTools
[56f22d72] + Artifacts
[2a0f44e3] + Base64
[ade2ca70] + Dates
[8bb1440f] + DelimitedFiles
[8ba89e20] + Distributed
[f43a241f] + Downloads
[b77e0a4c] + InteractiveUtils
[b27032c2] + LibCURL
[76f85450] + LibGit2
[8f399da3] + Libdl
[37e2e46d] + LinearAlgebra
[56ddb016] + Logging
[d6f4376e] + Markdown
[a63ad114] + Mmap
[ca575930] + NetworkOptions
[44cfe95a] + Pkg
[de0858da] + Printf
[3fa0cd96] + REPL
[9a3f8284] + Random
[ea8e919c] + SHA
[9e88b42a] + Serialization
[1a1011a3] + SharedArrays
[6462fe0b] + Sockets
[2f01184e] + SparseArrays
[10745b16] + Statistics
[fa267f1f] + TOML
[a4e569a6] + Tar
[8dfed614] + Test
[cf7118a7] + UUIDs
[4ec0a83e] + Unicode
[e66e0078] + CompilerSupportLibraries_jll
[deac9b47] + LibCURL_jll
[29816b5a] + LibSSH2_jll
[c8ffd9c3] + MbedTLS_jll
[14a3606d] + MozillaCACerts_jll
[4536629a] + OpenBLAS_jll
[83775a58] + Zlib_jll
[8e850b90] + libblastrampoline_jll
[8e850ede] + nghttp2_jll
[3f19e933] + p7zip_jll
Precompiling project...
3 dependencies successfully precompiled in 2 seconds (8 already precompiled)
and then installed Neural Quantum
successfully:
(Downloads) pkg> add https://github.com/PhilipVinc/NeuralQuantum.jl
Updating git-repo `https://github.com/PhilipVinc/NeuralQuantum.jl`
Resolving package versions...
Installed DiffRules ─────────── v1.5.0
Installed RecursiveArrayTools ─ v2.11.4
Installed IRTools ───────────── v0.4.5
Installed ChainRules ────────── v0.7.70
Installed Zygote ────────────── v0.6.12
Installed NNlib ─────────────── v0.7.17
Installed LogExpFunctions ───── v0.3.0
Installed ChainRulesCore ────── v0.9.45
Installed SpecialFunctions ──── v1.8.3
Updating `~/Downloads/Project.toml`
[872c559c] ↓ NNlib v0.8.4 ⇒ v0.7.17
[eb923273] + NeuralQuantum v0.2.0 `https://github.com/PhilipVinc/NeuralQuantum.jl#master`
Updating `~/Downloads/Manifest.toml`
[621f4979] + AbstractFFTs v1.0.1
[79e6a3ab] ↓ Adapt v3.3.3 ⇒ v1.1.0
[ec485272] + ArnoldiMethod v0.1.0
[4fba245c] + ArrayInterface v3.2.2
[b7192094] + BinningAnalysis v0.5.1
[082447d4] + ChainRules v0.7.70
[d360d2e6] ↓ ChainRulesCore v1.14.0 ⇒ v0.9.45
[bbf7d656] + CommonSubexpressions v0.3.0
[864edb3b] + DataStructures v0.18.11
[163ba53b] + DiffResults v1.0.3
[b552c78f] + DiffRules v1.5.0
[ffbed154] + DocStringExtensions v0.8.6
[e2ba6199] + ExprTools v0.1.8
[7a1cc6ca] + FFTW v1.4.6
[1a297f60] + FillArrays v0.11.9
[f6369f11] + ForwardDiff v0.10.25
[0c68f7d7] + GPUArrays v2.0.1
[7869d1d1] + IRTools v0.4.5
[615f187c] + IfElse v0.1.1
[d25df0c9] + Inflate v0.1.2
[92d709cd] + IrrationalConstants v0.1.1
[42fd0dbc] + IterativeSolvers v0.9.2
[692b3bcd] + JLLWrappers v1.4.1
[50d2b5c4] + Lazy v0.15.1
[093fc24a] + LightGraphs v1.3.5
[7a12625a] + LinearMaps v3.6.0
[2ab3a3ac] + LogExpFunctions v0.3.0
[da04e1cc] + MPI v0.19.2
[1914dd2f] + MacroTools v0.5.9
[872c559c] ↓ NNlib v0.8.4 ⇒ v0.7.17
[77ba4419] + NaNMath v0.3.7
[eb923273] + NeuralQuantum v0.2.0 `https://github.com/PhilipVinc/NeuralQuantum.jl#master`
[bac558e1] + OrderedCollections v1.4.1
[21216c6a] + Preferences v1.2.5
[4f57444f] + QuantumOpticsBase v0.3.1
[3cdcf5f2] + RecipesBase v1.2.1
[731186ca] + RecursiveArrayTools v2.11.4
[189a3867] + Reexport v0.2.0
[699a6c99] + SimpleTraits v0.9.4
[276daf66] + SpecialFunctions v1.8.3
[24973c7f] + SpecializeVarargs v0.1.1
[aedffcd0] + Static v0.4.1
[90137ffa] + StaticArrays v1.4.3
[5e0ebb24] + Strided v1.1.2
[9d95972d] + TupleTools v1.3.0
[c4a57d5a] + UnsafeArrays v1.0.3
[98cad3c8] + ValueHistories v0.5.4
[e88e6eb3] + Zygote v0.6.12
[700de1a5] + ZygoteRules v0.2.2
[f5851436] + FFTW_jll v3.3.10+0
[1d5cc7b8] + IntelOpenMP_jll v2018.0.3+2
[856f044c] + MKL_jll v2022.0.0+0
[7cb0a576] + MPICH_jll v4.0.1+0
[9237b28f] + MicrosoftMPI_jll v10.1.3+2
[fe0851c0] + OpenMPI_jll v4.1.2+0
[efe28fd5] + OpenSpecFun_jll v0.5.5+0
[4af54fe1] + LazyArtifacts
[05823500] + OpenLibm_jll
Precompiling project...
✓ ChainRulesCore
✓ NNlib
17 dependencies successfully precompiled in 16 seconds (48 already precompiled)
2 dependencies precompiled but different versions are currently loaded. Restart julia to access the new versions
Then I opened another environment and I was able to install NeuralQuantum
from scratch without any error:
(deleteme) pkg> add https://github.com/PhilipVinc/NeuralQuantum.jl
Updating git-repo `https://github.com/PhilipVinc/NeuralQuantum.jl`
Updating registry at `~/.julia/registries/General.toml`
Resolving package versions...
Installed NNlib ─────────────── v0.7.9
Installed Zygote ────────────── v0.6.37
Installed ChainRules ────────── v1.28.1
Installed RecursiveArrayTools ─ v2.21.1
Updating `~/Downloads/deleteme/Project.toml`
[eb923273] + NeuralQuantum v0.2.0 `https://github.com/PhilipVinc/NeuralQuantum.jl#master`
Updating `~/Downloads/deleteme/Manifest.toml`
[621f4979] + AbstractFFTs v1.1.0
[79e6a3ab] + Adapt v1.1.0
[ec485272] + ArnoldiMethod v0.1.0
[4fba245c] + ArrayInterface v3.2.2
[b7192094] + BinningAnalysis v0.5.1
[082447d4] + ChainRules v1.28.1
[d360d2e6] + ChainRulesCore v1.14.0
[9e997f8a] + ChangesOfVariables v0.1.2
[bbf7d656] + CommonSubexpressions v0.3.0
[34da2185] + Compat v3.42.0
[864edb3b] + DataStructures v0.18.11
[163ba53b] + DiffResults v1.0.3
[b552c78f] + DiffRules v1.10.0
[ffbed154] + DocStringExtensions v0.8.6
[e2ba6199] + ExprTools v0.1.8
[7a1cc6ca] + FFTW v1.4.6
[1a297f60] + FillArrays v0.12.8
[f6369f11] + ForwardDiff v0.10.25
[0c68f7d7] + GPUArrays v2.0.1
[7869d1d1] + IRTools v0.4.5
[615f187c] + IfElse v0.1.1
[d25df0c9] + Inflate v0.1.2
[3587e190] + InverseFunctions v0.1.3
[92d709cd] + IrrationalConstants v0.1.1
[42fd0dbc] + IterativeSolvers v0.9.2
[692b3bcd] + JLLWrappers v1.4.1
[50d2b5c4] + Lazy v0.15.1
[093fc24a] + LightGraphs v1.3.5
[7a12625a] + LinearMaps v3.6.0
[2ab3a3ac] + LogExpFunctions v0.3.10
[da04e1cc] + MPI v0.19.2
[1914dd2f] + MacroTools v0.5.9
[872c559c] + NNlib v0.7.9
[77ba4419] + NaNMath v0.3.7
[eb923273] + NeuralQuantum v0.2.0 `https://github.com/PhilipVinc/NeuralQuantum.jl#master`
[bac558e1] + OrderedCollections v1.4.1
[21216c6a] + Preferences v1.2.5
[4f57444f] + QuantumOpticsBase v0.3.1
[c1ae055f] + RealDot v0.1.0
[3cdcf5f2] + RecipesBase v1.2.1
[731186ca] + RecursiveArrayTools v2.21.1
[189a3867] + Reexport v0.2.0
[ae029012] + Requires v1.3.0
[699a6c99] + SimpleTraits v0.9.4
[276daf66] + SpecialFunctions v2.1.4
[24973c7f] + SpecializeVarargs v0.1.1
[aedffcd0] + Static v0.4.1
[90137ffa] + StaticArrays v1.4.3
[5e0ebb24] + Strided v1.1.2
[9d95972d] + TupleTools v1.3.0
[c4a57d5a] + UnsafeArrays v1.0.3
[98cad3c8] + ValueHistories v0.5.4
[e88e6eb3] + Zygote v0.6.37
[700de1a5] + ZygoteRules v0.2.2
[f5851436] + FFTW_jll v3.3.10+0
[1d5cc7b8] + IntelOpenMP_jll v2018.0.3+2
[856f044c] + MKL_jll v2022.0.0+0
[7cb0a576] + MPICH_jll v4.0.1+0
[9237b28f] + MicrosoftMPI_jll v10.1.3+2
[fe0851c0] + OpenMPI_jll v4.1.2+0
[efe28fd5] + OpenSpecFun_jll v0.5.5+0
[0dad84c5] + ArgTools
[56f22d72] + Artifacts
[2a0f44e3] + Base64
[ade2ca70] + Dates
[8bb1440f] + DelimitedFiles
[8ba89e20] + Distributed
[f43a241f] + Downloads
[b77e0a4c] + InteractiveUtils
[4af54fe1] + LazyArtifacts
[b27032c2] + LibCURL
[76f85450] + LibGit2
[8f399da3] + Libdl
[37e2e46d] + LinearAlgebra
[56ddb016] + Logging
[d6f4376e] + Markdown
[a63ad114] + Mmap
[ca575930] + NetworkOptions
[44cfe95a] + Pkg
[de0858da] + Printf
[3fa0cd96] + REPL
[9a3f8284] + Random
[ea8e919c] + SHA
[9e88b42a] + Serialization
[1a1011a3] + SharedArrays
[6462fe0b] + Sockets
[2f01184e] + SparseArrays
[10745b16] + Statistics
[fa267f1f] + TOML
[a4e569a6] + Tar
[8dfed614] + Test
[cf7118a7] + UUIDs
[4ec0a83e] + Unicode
[e66e0078] + CompilerSupportLibraries_jll
[deac9b47] + LibCURL_jll
[29816b5a] + LibSSH2_jll
[c8ffd9c3] + MbedTLS_jll
[14a3606d] + MozillaCACerts_jll
[4536629a] + OpenBLAS_jll
[05823500] + OpenLibm_jll
[83775a58] + Zlib_jll
[8e850b90] + libblastrampoline_jll
[8e850ede] + nghttp2_jll
[3f19e933] + p7zip_jll
Precompiling project...
11 dependencies successfully precompiled in 13 seconds (57 already precompiled)
julia> using NeuralQuantum
julia> N = 5;
julia> hilb = HomogeneousSpin(N, 1//2)
Hilbert Space with 5 identical spins 1/2 of dimension 2
Moreover, this time the installation was much faster. No mention of BinaryProvider
is made... which is weird. The julia project toml where installation failed was this one:
(@v1.7) pkg> st
Status `~/.julia/environments/v1.7/Project.toml`
[6e4b80f9] BenchmarkTools v1.3.1
[98e50ef6] JuliaFormatter v0.22.7
[872c559c] NNlib v0.6.6
[eb923273] NeuralQuantum v0.2.0 `https://github.com/PhilipVinc/NeuralQuantum.jl#master`
[438e738f] PyCall v1.93.1
[6aa20fa7] TensorOperations v2.0.1
I also verified that the julia version is correct on the working environments:
julia> versioninfo()
Julia Version 1.7.2
Commit bf53498635 (2022-02-06 15:21 UTC)
Platform Info:
OS: macOS (arm64-apple-darwin21.2.0)
CPU: Apple M1
WORD_SIZE: 64
LIBM: libopenlibm
LLVM: libLLVM-12.0.1 (ORCJIT, cyclone)
I'm trying to install the library using Julia 1.7 with an arm64 arch in a Mac M1. However, I get the following error:
This looks to be an error triggered by
BinaryProvider
as explained here. Latest release was on 2020 before the Mac M1 was released. Apparently the guys from PastaQ reported the same installation issue, but it looks like they were able to find a fix with this PR.I wonder if a fix like this could be made here. Thanks. I really don't want to go back to using Rosetta again 😄 I don't know if such a fix could be written in
NNLib
directly.