odys.results.dispatch¶
Typed dispatch result containers: GeneratorDispatch, BatteryStorageDispatch, ElectricVehicleDispatch, ChargerDispatch, MarketDispatch, and FlexibleLoadDispatch. Each is a Dispatch (storage and electric vehicles through BatteryDispatch): select one entity with dispatch["name"], iterate over the entities, read each series as a pandas.Series property, or get everything with .to_dataframe() and .to_dataset().
See Reading results in the User Guide.
Typed dispatch results for assets and markets.
BatteryDispatch
¶
Bases: Dispatch
Dispatch results of battery-bearing entities: net power, state of charge and charge mode.
Source code in src/odys/results/dispatch.py
109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 | |
BatteryStorageDispatch
¶
Bases: BatteryDispatch
Dispatch results for battery storages in the portfolio.
Source code in src/odys/results/dispatch.py
130 131 132 133 134 | |
ChargerDispatch
¶
Bases: Dispatch
Dispatch results for chargers in the portfolio.
Source code in src/odys/results/dispatch.py
144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 | |
Dispatch
¶
Dispatch results of every entity of one type, indexed along that type's dimension.
Wraps one dataset holding the type's series. dispatch[name] selects one entity,
iterating yields one dispatch per entity, and subclasses expose each series as a
typed property.
Source code in src/odys/results/dispatch.py
10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 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 77 78 79 | |
dimension
property
¶
Return the dimension the entities are indexed along.
__contains__(key)
¶
Check whether an entity exists by name.
Source code in src/odys/results/dispatch.py
54 55 56 | |
__getitem__(key)
¶
Return the dispatch of one entity.
Source code in src/odys/results/dispatch.py
41 42 43 | |
__init__(data, dimension)
¶
Initialize from the series of the entities and the dimension they are indexed along.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
data
|
Dataset
|
One data variable per series, indexed along |
required |
dimension
|
str
|
The entity axis, such as "generator". |
required |
Source code in src/odys/results/dispatch.py
22 23 24 25 26 27 28 29 30 | |
__iter__()
¶
Iterate over the dispatch of each entity.
Source code in src/odys/results/dispatch.py
45 46 47 48 | |
__len__()
¶
Return the number of entities.
Source code in src/odys/results/dispatch.py
50 51 52 | |
__repr__()
¶
Return the type and the entity names.
Source code in src/odys/results/dispatch.py
77 78 79 | |
to_dataframe()
¶
Return the dispatch results as a pandas DataFrame, one row per label of the dimensions every series has.
A series with more dimensions, such as a charger's assignment to each vehicle, gets one
column per label of the extra dimensions (assignment[ev_1]), so no value is repeated.
Source code in src/odys/results/dispatch.py
66 67 68 69 70 71 72 73 74 75 | |
to_dataset()
¶
Return the dispatch results as an xarray Dataset (a copy, so editing it leaves the results unchanged).
Source code in src/odys/results/dispatch.py
61 62 63 64 | |
ElectricVehicleDispatch
¶
Bases: BatteryDispatch
Dispatch results for electric vehicles in the portfolio.
Source code in src/odys/results/dispatch.py
137 138 139 140 141 | |
FlexibleLoadDispatch
¶
Bases: Dispatch
Dispatch results for flexible loads in the portfolio.
Source code in src/odys/results/dispatch.py
183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 | |
GeneratorDispatch
¶
Bases: Dispatch
Dispatch results for generators in the portfolio.
Source code in src/odys/results/dispatch.py
82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 | |
MarketDispatch
¶
Bases: Dispatch
Dispatch results for markets in the portfolio.
Source code in src/odys/results/dispatch.py
161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 | |