tqdm
tqdm copied to clipboard
tqdm_gui.write() in the GUI instead of console?
tqdm_gui.write() currently outputs text into the console. Maybe it should prints into the GUI, below the figure in a textbox that would autowrap and overflow (have scrollbars)?
I googled a bit, but it will likely be very complicated to do that using only matplotlib (the currently used lib for drawing the GUI). Eg:
A solution would be to encase the matplotlib drawing into a QT window, but then the GUI would depend on QT lib...
I use wxPython and I am creating a GUI that use a CLI Python program (and inside it, tqdm). For me, was interesting if possible to easy overload the method / change the output method that tqdm output in a graphical process bar and labels already present in my GUI (to the CLI still work without the GUI, if necessary).
About create a graphical independent process bar for tqdm, it is interesting if could run in different graphical libraries / not depend of more package installations / or, at least, use the default graphical library already provide in Python (Python 2 use TKinter and Python 3, not, if I remember).
This should be easier with inheritance in the new architecture which will be in v5.
Glad to hear that.
I am now working in my GUIDE that intend to use the tqdm. My the software already use the tqdm on CLI version, now, with a "guide layer" for the user I intend to stop print tqdm on terminal and use the scraping_progress.avg_time, 's/'+scraping_progress.unit and scraping_progress.last_print_n,'/',scraping_progress.total to update the guide informations.
On version 4, is it possible to overload some class to:
- Not print any process bar on terminal;
- Overload / replace the update to output the percentage, so I could use to update a GUI process bar;
- Use the information completed parts and time to update other graphical element.
Which class or function I have to overload?
all of this is do-able as-is, but I'm hesitant because it'll be clunky and have to be upgraded when I (finally) get around to v5...
see #494 for hacky parsing of update strings, and tqdm_gui which inherits from tqdm
I'm using a package that uses tqdm to print progress on console. Is there a way to capture output without modifying the package I'm using, so I can display on gui like WXPython? I searched tqdm inheritance to update gui, but I couldn't find much.
I'm using a package that uses tqdm to print progress on console. Is there a way to capture output without modifying the package I'm using, so I can display on gui like WXPython? I searched tqdm inheritance to update gui, but I couldn't find much.
I time ago I wrote this code https://github.com/hildogjr/KiCost/blob/master/kicost/kicost_gui.py, it is not fancy but worked. The tool was mainly CLI and I just wanted to create a gauge of tqdm in the GUI mode. Search by frame.m_gauge_process.SetValue inside ProgressGUI class.