-
Notifications
You must be signed in to change notification settings - Fork 219
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Unable to load Turing.jl #409
Comments
Hi, are you in the master branch of Turing.jl? From |
I should be (I think). Whatever is installed when I use Pkg.add(). |
Can you try |
Am able to load through the above command, but getting an error while running the following example given in the introduction. Any suggestions on what to do?
Error message below:
|
Please do Pkg.build("Turing") |
Thank you! When I gave this build command, got the following error. Does this I have to install xcode & homebrew?
|
It seems that you haven't installed the Command Line Tools from Xcode? I'm not sure about the error but please try install it. |
Installed XCode, and is working fine now. Thank you! |
Great! You're welcome |
I reinstalled using Pkg.checkout("Turing", "master"). I can now get it to load. However, more problems arise. First, because Gadfly is a requirement, some of my packages are downgraded: DataFrames, CSV, among some others, which breaks some of the code I have written using the most recent versions of those packages. Second, I tried running the simple Gaussian model example presented in the introduction in both a notebook and in command line. In both cases, when I try to sample, c = sample(gdemo([1.5, 2]), PG(50, 300)), Julia crashes. |
Here is the command line output: Please submit a bug report with steps to reproduce this fault, and any error messages that follow (in their entirety). Thanks. |
Did you run |
No, after having done that, it appears to be working. Is it possible to use Turing with Plots.jl instead of Gadfly? Installing Gadfly downgrades some packages. If not, is it planned? |
The reason Turing.jl has some dependencies on specific packages is because Turing.jl depends on Mamba.jl which depends on some packages including Gadfly.jl. You can certainly use Plots.jl with Turing.jl. I personally did this and in some of the notebook examples we have we also use Plots.jl. What specific problem do you meet? |
The problem is not with Turing.jl, but with Gadfly.jl. Currently, it appears that installing Gadfly.jl causes some packages to downgrade, notably DataFrames.jl and CSV.jl, which breaks code that I'm working on. But as you said, Turing.jl depends on Mamba.jl which in turn depends on Gadfly.jl, so my problem really has nothing to do with Turing.jl per say. Turing.jl appears to be working now. Which Turing.jl examples are using Plots.jl? Would you happen to know the status of Gadfly.jl? Is it still under development, or will it eventually be replaced by Plots.jl? Thanks very much for the help. |
For examples this one uses I'm not sure the status of Gadfly.jl. Maybe @ChrisRackauckas knows. |
Gadfly's development has slowed ever since the main developer left. It has two contributors who work a little bit on it, totaling 100 commits over the last year, so it seems like it's mostly in maintenance mode. I don't think it will be going away any time soon, but it's definitely not the main Julia plotting library anymore and I would only recommend it if you're really wedded to Grammar of Graphics APIs (even though, I hope that Plots.jl or eventually Makie.jl gets a GoG API so we can dump Gadfly). |
Thanks for the much appreciated insight Chris. Is it possible use Plots.jl in place of Gadfly.jl in the examples in which Gadfly.jl is currently used? For example, I've tried using Plots.jl in introduction.ipynb but I get the following error: No user recipe defined for Turing.Chain Is there currently a workaround for this or will this be possible with future changes to Turing.jl? |
You can always extract samples from
|
Thanks for the help Kai! I'm going to close this out because it's gotten off of the original topic. |
Hi,
I'm unable to load Turing.jl. Here is the error I receive when attempting to load Turing.jl into a Jupyter notebook (using 0.62 on Windows 10):
LoadError: LoadError: LoadError: invalid subtyping in definition of HMC
while loading C:\Users#####.julia\v0.6\Turing\src\samplers\hmc.jl, in expression starting on line 521
while loading C:\Users#####.julia\v0.6\Turing\src\samplers/sampler.jl, in expression starting on line 29
while loading C:\Users#####.julia\v0.6\Turing\src\Turing.jl, in expression starting on line 72
Stacktrace:
[1] include_from_node1(::String) at .\loading.jl:576
[2] include(::String) at .\sysimg.jl:14
[3] include_from_node1(::String) at .\loading.jl:576
[4] include(::String) at .\sysimg.jl:14
[5] include_from_node1(::String) at .\loading.jl:576
[6] eval(::Module, ::Any) at .\boot.jl:235
[7] _require(::Symbol) at .\loading.jl:490
[8] require(::Symbol) at .\loading.jl:405
[9] include_string(::String, ::String) at .\loading.jl:522
The text was updated successfully, but these errors were encountered: