dataclasses
Classes for describing Task state and results.
Classes:
Name | Description |
---|---|
TaskResult |
Output of a specific analysis task. |
TaskStatus |
Enumeration of possible Task statuses (running, pending, failed, etc.). |
DescribedAnalysis |
Executor's description of a |
DescribedAnalysis
dataclass
Complete analysis description. Held by an Executor.
Source code in lute/tasks/dataclasses.py
148 149 150 151 152 153 154 155 156 157 |
|
ElogSummaryPlots
dataclass
Holds a graphical summary intended for display in the eLog.
Converts figures to a byte stream of HTML data to be written out, so the eLog can properly display them.
Attributes:
Name | Type | Description |
---|---|---|
display_name |
str
|
This represents both a path and how the result will be
displayed in the eLog. Can include "/" characters. E.g.
|
figures |
(Tabs, Image, Figure, bytes)
|
The figures to be displayed. Except panel/holoviews (bokeh backend) and matplotlib plots as well as a raw series of bytes for the HTML file. Figures from the plotting libraries will be converted to an HTML byte stream automatically. |
Source code in lute/tasks/dataclasses.py
111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 |
|
_setup_figures()
Convert figures to an HTML file in a byte stream.
Source code in lute/tasks/dataclasses.py
138 139 140 141 142 143 144 145 |
|
TaskParametersDBReference
dataclass
Contains information about how to reconstruct a TaskParameters object.
Attributes:
Name | Type | Description |
---|---|---|
db_dir |
str
|
The path to the database containing the TaskParameters schema definition. |
row_ids |
RowIds
|
The ids of the rows in the various tables required for reconstructing the TaskParameters object. |
Source code in lute/tasks/dataclasses.py
30 31 32 33 34 35 36 37 38 39 40 41 42 43 |
|
TaskResult
dataclass
Class for storing the result of a Task's execution with metadata.
Attributes:
Name | Type | Description |
---|---|---|
task_name |
str
|
Name of the associated task which produced it. |
task_status |
TaskStatus
|
Status of associated task. |
summary |
Any
|
Short (usually text message) summary associated with the result. |
payload |
Any
|
Actual result. May be data in any format. |
impl_schemas |
Optional[str]
|
A string listing |
Source code in lute/tasks/dataclasses.py
79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 |
|
TaskStatus
Bases: Enum
Possible Task statuses.
Source code in lute/tasks/dataclasses.py
46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 |
|
CANCELLED = 5
class-attribute
instance-attribute
Task was cancelled prior to completion or failure.
COMPLETED = 2
class-attribute
instance-attribute
Task has completed without fatal errors.
FAILED = 3
class-attribute
instance-attribute
Task encountered a fatal error.
PENDING = 0
class-attribute
instance-attribute
Task has yet to run. Is Queued, or waiting for prior tasks.
RUNNING = 1
class-attribute
instance-attribute
Task is in the process of execution.
STOPPED = 4
class-attribute
instance-attribute
Task was, potentially temporarily, stopped/suspended.
TIMEDOUT = 6
class-attribute
instance-attribute
Task did not reach completion due to timeout.