kimikage / ProfileSVG.jl

Write flame graphs to SVG format and explore them interactively in Jupyter, Pluto, etc.
MIT License
53 stars 7 forks source link

Support for displaying SVG wrapped in HTML #50

Closed kimikage closed 3 years ago

kimikage commented 4 years ago

HTML support enables interactive features in more tools (e.g. Pluto.jl). On the other hand, depending on the environment (e.g. Jupyter+IE11), the display may not be the same as the current SVG version.

This also fixes the showable to avoid displaying the configuration as an SVG.

codecov-io commented 4 years ago

Codecov Report

Merging #50 into master will not change coverage. The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff            @@
##            master       #50   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files            2         2           
  Lines          155       162    +7     
=========================================
+ Hits           155       162    +7     
Impacted Files Coverage Δ
src/ProfileSVG.jl 100.00% <100.00%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more Δ = absolute <relative> (impact), ø = not affected, ? = missing data Powered by Codecov. Last update 8789b76...9cc7e91. Read the comment docs.

kimikage commented 4 years ago

Note that ProfileSVG and Gadfly's SVGJS backend use the same background technology, so ProfileSVG has the same problems as what I wrote in https://github.com/fonsp/Pluto.jl/issues/546.

(Pluto's reactive mechanism and Julia's profiling mechanism are a bit incompatible, though. However, it's better to be able to use it than not.)

diegozea commented 3 years ago

(Pluto's reactive mechanism and Julia's profiling mechanism are a bit incompatible, though. However, it's better to be able to use it than not.)

Hi! I was curious about how they are incompatible. Could you expand more on this? Thanks

kimikage commented 3 years ago

The profile data will not be updated when the code or data changes. It would be technically possible to re-run the profiling after each change, but I think it would be annoying that the old profile data are automatically dropped.