Open yarikoptic opened 1 week ago
I imagine the usage would look something like:
duct --output-prefix myprefix_ sleep 2
duct-suite render --matplotlib myprefix_usage.json
@yarikoptic does that match what you are thinking?
yeap, something like that.
duct-suite render --backend matplotlib -o myprefix_usage.png myprefix_usage.json
and if no -o
-- just display on screen. Eventually tricky part could become if we get various backends, and decide to get them backend specific options. For datalad-installer @jwodder ended up with quite evolved solution for smth like that. Hopefully we would not fall into such a rabbit hole here, just let's start somewhere ;-)
POC https://github.com/asmacdo/fancy-duct
(fake data)
Might complement #105 nicely
I think with that we should initiate a helper "entry script" we could call
duct-suite
(or anything else) which would have support commands like this one to plot based on the stats collected for a process. Could probably be by default overlap of memory and CPU consumption with left "y" axis to have CPU and right - memory. Example for two graph plot with different scales: https://matplotlib.org/stable/gallery/subplots_axes_and_figures/two_scales.htmlThen we can define extra-depends for the
duct[suite]
to use matplotlib etc as desired for theduct-suite
.Note that might want to code right away so we might later provide different plotting backends (may be for inclusion online etc)