TrackingTaskKind
RL4CRN.utils.default_tasks.TrackingTaskKind
TrackingTaskKind
Bases: TaskKindBase
Deterministic tracking with named-expression targets (or constant).
pretty_help(*, width=100, bullet='-', return_str=False)
classmethod
Pretty-print the task-kind help specification in a Markdown-like list format.
This uses cls.help() (a static method implemented by each TaskKind).
The expected shape is:
{
"required": {<key>: <description>, ...},
"optional": {<key>: <description>, ...},
"notes": <string or list of strings>
}
| PARAMETER | DESCRIPTION |
|---|---|
width
|
Maximum line width for wrapping descriptions.
TYPE:
|
bullet
|
Bullet marker to use for list items (default "-").
TYPE:
|
return_str
|
If True, return the formatted string instead of printing.
TYPE:
|
| RETURNS | DESCRIPTION |
|---|---|
Optional[str]
|
If return_str=True, returns the formatted help string. Otherwise None. |
build_time_horizon(task)
Build or reuse the time horizon.
| PARAMETER | DESCRIPTION |
|---|---|
task
|
TaskSpec instance.
TYPE:
|
| RETURNS | DESCRIPTION |
|---|---|
ndarray
|
Time grid array of shape (n_t,) float32. |
build_u_list(task, overrides)
Build or override the u_list for evaluation.
Precedence
overrides['u_list'] overrides['u_spec'] task.u_list (if user provided explicit list) task.u_spec (special tags only) TaskKind.default_u_list(task) # kind-specific semantics
| PARAMETER | DESCRIPTION |
|---|---|
task
|
TaskSpec instance.
TYPE:
|
overrides
|
Override dictionary.
TYPE:
|
| RETURNS | DESCRIPTION |
|---|---|
List[ndarray]
|
List of input vectors (float32 arrays), each shape (p,). |
build_ic(task, overrides)
Build the IC object from spec or override.
| PARAMETER | DESCRIPTION |
|---|---|
task
|
TaskSpec instance.
TYPE:
|
overrides
|
Override dictionary, may contain 'ic_spec'.
TYPE:
|
| RETURNS | DESCRIPTION |
|---|---|
Any
|
RL4CRN IC object. |