Analysis manager
A tree-view panel: manages the start, stop, status monitoring and automatic restart of analysis scripts.
Overview
quatm/GUI/entries/analysismanager.py provides the analysis manager: it lists the analysis
scripts in a checkable tree table (name / script / category / input stream) and is responsible
for starting and stopping subprocesses, monitoring and automatic restart, as well as adding,
deleting and configuring analysis entries.
Components
| Component | Description |
|---|---|
AnalysisManager | Main panel: loads and organises the analysis entries, and provides delete/configure entry points |
TreeViewWidget | Analysis script management tree: checking starts and stops, monitoring restarts automatically, add/delete/edit |
addAnalysisWidget | Toolbar for adding an analysis entry (name / category / script / input stream) |
Functions
| Operation | Description |
|---|---|
| Check to start | Checking an entry starts the corresponding analysis subprocess; unchecking stops it |
| Stop | endProcess: terminates first and waits briefly for exit, then forces the end on timeout |
| Status refresh | updateStatus: periodically checks whether the process is still running |
| Clean up stray processes | killVagabonding: terminates leftover processes of the same script from the previous round |
| Add / configure / delete | The toolbar registers new entries; a selected row can be configured or deleted |
Usage
from quatm.GUI.entries.analysismanager import AnalysisManager
mgr = AnalysisManager(name="AnalysisManager", parent=parent)
Analysis scripts are independent processes: once an entry is checked, the manager launches the script with the current interpreter and injects the project environment variables into the child process, so analysis code and the main program are isolated from each other and a script crash cannot affect experiments.