Skip to content

Error when Plotting: Cannot convert LaplaceRedux.Laplace to series data for plotting #61

@patrickm663

Description

@patrickm663

Hi

I am running into an issue when getting to the plotting section of the MLP regression tutorial.

I had originally run into the error on my own example, but I still face it when following the tutorial. The fitting and optimisation step runs without error!

Below is my environment (Pluto notebook; Julia 1.9.3):

Status `/tmp/jl_HCANJ7/Project.toml`
  [587475ba] Flux v0.14.6
  [c52c1a26] LaplaceRedux v0.1.3
  [91a5bcdd] Plots v1.39.0
  [44cfe95a] Pkg v1.9.2
  [10745b16] Statistics v1.9.0

For clarification, below is the code:

begin
	subset_w = :all
	la = Laplace(nn; likelihood=:regression, subset_of_weights=subset_w)
	fit!(la, data)
	plot(la, X, y; zoom=-5, size=(400,400))
end

And below is the full error:

Cannot convert LaplaceRedux.Laplace to series data for plotting

    error(::String)@error.jl:35
    _prepare_series_data(::LaplaceRedux.Laplace)@series.jl:8
    _series_data_vector(::LaplaceRedux.Laplace, ::Dict{Symbol, Any})@series.jl:36
    macro expansion@series.jl:128[inlined]
    apply_recipe(::AbstractDict{Symbol, Any}, ::Type{RecipesPipeline.SliceIt}, ::Any, ::Any, ::Any)@RecipesBase.jl:300
    _process_userrecipes!(::Any, ::Any, ::Any)@user_recipe.jl:38
    recipe_pipeline!(::Any, ::Any, ::Any)@RecipesPipeline.jl:72
    _plot!(::Plots.Plot, ::Any, ::Any)@plot.jl:223
    #plot#[email protected]:102[inlined]
    plot@plot.jl:93[inlined]
    top-level scope@[Local: 5](http://localhost:1234/edit?id=0e0472c4-5887-11ee-1f75-2fc9822473d3#)[inlined]

Thank you for any assistance.

Kind regards
Patrick

Metadata

Metadata

Assignees

No one assigned

    Labels

    documentationImprovements or additions to documentation

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions