queryverse / queryverse/ElectronDisplay.jl

Plotting VegaLite plot from REPL fails with `FATAL:gpu_data_manager_impl_private.cc(439)`

Open
#98 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
CSS
Stars
89
Forks
17
Avg merge
19h 47m
Merged PRs (30d)
5

Description

Hi, I'm stuck with this error, when trying to display a simple plot from VegaLite via ElectronDisplay:

 [30851:0724/155718.915298:FATAL:gpu_data_manager_impl_private.cc(439)] GPU process isn't usable. Goodbye.
ERROR: Unexpected end of input
Line: 0
Around: ......
           ^

Stacktrace:
  [1] error(s::String)
    @ Base ./error.jl:35
  [2] _error(message::String, ps::JSON.Parser.MemoryParserState)
    @ JSON.Parser ~/.julia/packages/JSON/93Ea8/src/Parser.jl:140
  [3] byteat
    @ ~/.julia/packages/JSON/93Ea8/src/Parser.jl:49 [inlined]
  [4] parse_value(pc::JSON.Parser.ParserContext{Dict{String, Any}, Int64, true, nothing}, ps::JSON.Parser.MemoryParserState)
    @ JSON.Parser ~/.julia/packages/JSON/93Ea8/src/Parser.jl:160
  [5] parse(str::String; dicttype::Type, inttype::Type{Int64}, allownan::Bool, null::Nothing)
    @ JSON.Parser ~/.julia/packages/JSON/93Ea8/src/Parser.jl:450
  [6] parse
    @ ~/.julia/packages/JSON/93Ea8/src/Parser.jl:443 [inlined]
  [7] req_response(app::Electron.Application, cmd::Dict{String, Any})
    @ Electron ~/.julia/packages/Electron/ILvWR/src/Electron.jl:242
  [8] Electron.Window(app::Electron.Application, options::Dict{String, Any})
    @ Electron ~/.julia/packages/Electron/ILvWR/src/Electron.jl:326
  [9] #Window#16
    @ ~/.julia/packages/Electron/ILvWR/src/Electron.jl:344 [inlined]
 [10] Window
    @ ~/.julia/packages/Electron/ILvWR/src/Electron.jl:340 [inlined]
 [11] Electron.Window(args::URIParser.URI; kwargs::Base.Pairs{Symbol, Dict{String, Dict{String, Bool}}, Tuple{Symbol}, NamedTuple{(:options,), Tuple{Dict{String, Dict{String, Bool}}}}})
    @ Electron ~/.julia/packages/Electron/ILvWR/src/Electron.jl:374
 [12] _getglobalplotwindow()
    @ ElectronDisplay ~/.julia/packages/ElectronDisplay/Mu44j/src/ElectronDisplay.jl:91
 [13] displayplot(d::ElectronDisplay.ElectronDisplayType, type::String, data::JSON.Writer.JSONText; options::Dict{String, Dict{String, Bool}})
    @ ElectronDisplay ~/.julia/packages/ElectronDisplay/Mu44j/src/ElectronDisplay.jl:99
 [14] displayplot
    @ ~/.julia/packages/ElectronDisplay/Mu44j/src/ElectronDisplay.jl:98 [inlined]
 [15] _display_vega(d::ElectronDisplay.ElectronDisplayType, major_version::String, x::VegaLite.VLSpec)
    @ ElectronDisplay ~/.julia/packages/ElectronDisplay/Mu44j/src/vega.jl:31
 [16] display
    @ ~/.julia/packages/ElectronDisplay/Mu44j/src/vega.jl:55 [inlined]
 [17] display(d::ElectronDisplay.ElectronDisplayType, x::VegaLite.VLSpec)
    @ ElectronDisplay ~/.julia/packages/ElectronDisplay/Mu44j/src/ElectronDisplay.jl:270
 [18] electrondisplay(x::VegaLite.VLSpec; config::Base.Pairs{Symbol, Union{}, Tuple{}, NamedTuple{(), Tuple{}}})
    @ ElectronDisplay ~/.julia/packages/ElectronDisplay/Mu44j/src/ElectronDisplay.jl:343
 [19] electrondisplay
    @ ~/.julia/packages/ElectronDisplay/Mu44j/src/ElectronDisplay.jl:324 [inlined]
 [20] plotCFNSolution(pltcfg::PlotConfig, trajectory_df::DataFrames.DataFrame)
    @ plotting ~/VS Code Workspace/Julia/CFNsim/src/plotting.jl:20
 [21] runSingle(config::Dict{String, Any})
    @ singlerun ~/VS Code Workspace/Julia/CFNsim/src/singlerun.jl:91
 [22] top-level scope
    @ REPL[28]:1

The corresponding code uses a DataFrame trajectory_df, which holds a trajectory:

    g = trajectory_df |> @vlplot(:line, x="t:t", y="b1")
    electrondisplay(g)

The code works fine, when I just save the plot as a png (by VegaLite.jl's save() method):

traj_test

(b1 is constant over time)

I am working on Xubuntu 22.10 (Xfce display), which might be integral to the problem. Any hints on how to resolve this are very appreciated!

Many thanks already!

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Reproduce the failure with the shown DataFrame and @vlplot call, then inspect ElectronDisplay.jl around _getglobalplotwindow and displayplot and Electron.jl around req_response. Confirm whether the Electron window returns an incomplete response on this Xubuntu setup; done means the VegaLite plot opens from the REPL without the GPU or JSON parsing failure.

Written by the indexing model from the issue text.

Assessment

Tech stack
electron, julia
Domain
data-visualization, desktop
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.