output
Classes:
-
Frequency–Time span over which the results are assessed.
-
MCAllAreasDataType–Type of synthetic output files generated by the simulation for each area.
-
MCAllLinksDataType–Type of synthetic output files generated by the simulation for each area.
-
MCIndAreasDataType–Type of files generated by the simulation for each area and each Monte-Carlo year.
-
MCIndLinksDataType–Type of output files generated by the simulation for each link and each Monte-Carlo year.
-
Output–Output of an Antares Simulator simulation with or without Antares Xpansion.
-
XpansionOutputAntares–Output of Xpansion investment module.
-
XpansionOutputCandidate–Xpansion output candidate.
-
XpansionOutputCandidateInvest–Xpansion output candidate investment.
-
XpansionOutputCandidateSensitivity–Xpansion output candidate sensitivity study.
-
XpansionOutputIteration–Xpansion output for a given iteration.
-
XpansionOutputOptions–Options of Xpansion output.
-
XpansionOutputSensitivitySolution–Xpansion output sensitivity solution.
-
XpansionOutputSolution–Xpansion output solution.
-
XpansionResult–Xpansion results.
-
XpansionSensitivityResult–Xpansion sensitivity results.
Frequency
Time span over which the results are assessed.
Attributes:
-
HOURLY–Hourly detail.
-
DAILY–Daily bundle.
-
WEEKLY–Weekly bundle.
-
MONTHLY–Monthly bundle.
-
ANNUAL–Annual bundle.
MCAllAreasDataType
Type of synthetic output files generated by the simulation for each area.
Attributes:
-
VALUES–General values of variables (price, load, generation, etc.). Files of this type have the same size for all areas. In the UI, it corresponds to displaying General values.
-
DETAILS–Values regarding dispatchable thermal generating plants. File sizes differ by area. In the UI, it corresponds to displaying Thermal plants.
-
DETAILS_ST_STORAGE–Values regarding the different short-term storages of each area. The sizes of these files differ from one area to another. In the UI, it corresponds to displaying ST storages.
-
DETAILS_RES–Values regarding the different renewable clusters of each area. The sizes of these files differ from one area to another. In the UI, it corresponds to displaying Ren. clusters.
-
ID–Identifier (number) of the Monte-Carlo years for which were observed the extreme values of the different variables presented in the
valuesfiles. In the UI, it corresponds to displaying RecordYear.
MCAllLinksDataType
Type of synthetic output files generated by the simulation for each area.
Attributes:
-
VALUES–values of different variables (flow, congestion rent) the list of which is common to all interconnections. The files of type
valueshave therefore the same size everywhere. In the UI, it corresponds to displaying General values. -
ID–Identifier (number) of the Monte-Carlo years for which were observed the extreme values of the different variables presented in the
valuesfiles. In the UI, it corresponds to displaying RecordYear.
MCIndAreasDataType
Type of files generated by the simulation for each area and each Monte-Carlo year.
Attributes:
-
VALUES–General values of variables (price, load, generation, etc.). Files of this type have the same size for all areas. In the UI, it corresponds to displaying General values.
-
DETAILS–Values regarding dispatchable thermal generating plants. File sizes differ by area. In the UI, it corresponds to displaying Thermal plants.
-
DETAILS_ST_STORAGE–Values regarding the different short-term storages of each area. The sizes of these files differ from one area to another. In the UI, it corresponds to displaying ST storages.
-
DETAILS_RES–Values regarding the different renewable clusters of each area. The sizes of these files differ from one area to another. In the UI, it corresponds to displaying Ren. clusters.
MCIndLinksDataType
Type of output files generated by the simulation for each link and each Monte-Carlo year.
Attributes:
-
VALUES–values of different variables (flow, congestion rent) the list of which is common to all interconnections. The files of type
valueshave therefore the same size everywhere. In the UI, it corresponds to displaying General values.
Output
Output of an Antares Simulator simulation with or without Antares Xpansion.
See also the user documentation for more insights and explanations on outputs.
Methods:
-
aggregate_mc_all_areas–Get an aggregation of synthetic results for specific areas.
-
aggregate_mc_all_links–Get an aggregation of synthetic results for specific links.
-
aggregate_mc_ind_areas–Get an aggregation of individual results for specific areas.
-
aggregate_mc_ind_links–Get an aggregation of individual results for specific links.
-
get_binding_constraint_ts_numbers–Get binding constraint time series numbers for a given constraint group.
-
get_hydro_ts_numbers–Get hydro time series numbers for a given area.
-
get_link_ts_numbers–Get link time series numbers for a given link.
-
get_load_ts_numbers–Get load time series numbers for a given area.
-
get_mc_all_area–Get synthetic output data from a simulation for a specific area.
-
get_mc_all_link–Get synthetic output data from a simulation for a specific link.
-
get_mc_ind_area–Get output data for a single Monte-Carlo year and a specific area.
-
get_mc_ind_link–Get output data for a single Monte-Carlo year and a specific link.
-
get_solar_ts_numbers–Get solar time series numbers.
-
get_st_storage_additional_constraints_numbers–Get short-term storage additional constraints time series numbers for a given constraint.
-
get_st_storage_inflows_numbers–Get short-term storage inflows time series numbers for a given st-storage.
-
get_thermal_ts_numbers–Get thermal time series numbers for a given thermal cluster.
-
get_wind_ts_numbers–Get wind time series numbers for a given area.
-
get_xpansion_result–Get xpansion result.
-
get_xpansion_sensitivity_result–Get xpansion sensitivity results.
Attributes:
Source code in src/antares/craft/model/output.py
aggregate_mc_all_areas
aggregate_mc_all_areas(
data_type: MCAllAreasDataType,
frequency: Frequency,
areas_ids: Optional[list[str]] = None,
columns_names: Optional[list[str]] = None,
) -> DataFrame
Get an aggregation of synthetic results for specific areas.
Given the parameters, it will aggregate data from files such as:
mc-all/<mc_year>/areas/<area>/<data_type>-<frequency>
generated by Antares Simulator.
Parameters:
-
(data_typeMCAllAreasDataType) –Whether "VALUES", "DETAILS", "DETAILS_ST_STORAGE", "DETAILS_RES" or "ID", corresponding to the nature of the result.
-
(frequencyFrequency) –Whether "HOURLY", "DAILY", "WEEKLY", "MONTHLY", "ANNUAL", corresponding to the time step between each values in the output.
-
(areas_idsOptional[list[str]], default:None) –List of area IDs to fetch. If not indicated, all area IDs are aggregated.
-
(columns_namesOptional[list[str]], default:None) –List of the column names to fetch (apart from those automatically generated by the aggregation see below). If not indicated, all columns are taken into account for the aggregation.
Returns:
-
DataFrame–A dataframe aggregating all the data.
It contains at least the columns:
area,timeIdandclusterif thedata_typeis set to "DETAILS", "DETAILS_RES" or "DETAILS_ST_STORAGES".Those results are not multi indexed columns, the statistical metrics is appended to the column name such as "EXP", "STD", "MAX" and "MIN".
Source code in src/antares/craft/model/output.py
aggregate_mc_all_links
aggregate_mc_all_links(
data_type: MCAllLinksDataType,
frequency: Frequency,
links_ids: Optional[list[tuple[str, str]]] = None,
columns_names: Optional[list[str]] = None,
) -> DataFrame
Get an aggregation of synthetic results for specific links.
Given the parameters, it will aggregate data from files such as:
mc-all/<mc_year>/links/<area_from> - <area_to>/<data_type>-<frequency>
generated by Antares Simulator.
Parameters:
-
(data_typeMCAllLinksDataType) –Whether "VALUES" or "ID", corresponding to the nature of the result.
-
(frequencyFrequency) –Whether "HOURLY", "DAILY", "WEEKLY", "MONTHLY" or "ANNUAL", corresponding to the time step between each values in the output.
-
(links_idsOptional[list[tuple[str, str]]], default:None) –List of tuples ("area_from", "area_to") to fetch. If not indicated, all link IDs are aggregated.
-
(columns_namesOptional[list[str]], default:None) –List of the column names to fetch (apart from those automatically generated by the aggregation see below). If not indicated, all columns are taken into account for the aggregation.
Returns:
-
DataFrame–A dataframe aggregating all the data with at least the columns:
linkandtimeId.Those results are not multi indexed columns, the statistical metrics is appended to the column name such as "EXP", "STD", "MAX" and "MIN".
Source code in src/antares/craft/model/output.py
aggregate_mc_ind_areas
aggregate_mc_ind_areas(
data_type: MCIndAreasDataType,
frequency: Frequency,
mc_years: Optional[list[int]] = None,
areas_ids: Optional[list[str]] = None,
columns_names: Optional[list[str]] = None,
) -> DataFrame
Get an aggregation of individual results for specific areas.
Given the parameters, it will aggregate data from files such as:
mc-ind/<mc_year>/areas/<area>/<data_type>-<frequency>
generated by Antares Simulator.
Parameters:
-
(data_typeMCIndAreasDataType) –Whether "VALUES", "DETAILS", "DETAILS_ST_STORAGE" or "DETAILS_RES", corresponding to the nature of the result.
-
(frequencyFrequency) –Whether "HOURLY", "DAILY", "WEEKLY", "MONTHLY", "ANNUAL", corresponding to the time step between each values in the output.
-
(mc_yearsOptional[list[int]], default:None) –List of the Monte-Carlo years index to fetch. If not indicated, all Monte-Carlo years are aggregated.
-
(areas_idsOptional[list[str]], default:None) –List of the area IDs to fetch. If not indicated, all area IDs are aggregated.
-
(columns_namesOptional[list[str]], default:None) –List of the column names to fetch (apart from those automatically generated by the aggregation see below). If not indicated, all columns are taken in the aggregation.
Returns:
-
DataFrame–A dataframe aggregating all the data with at least the columns:
area,mcYear,timeIdandclusterifdata_typeis not "VALUES".
Source code in src/antares/craft/model/output.py
aggregate_mc_ind_links
aggregate_mc_ind_links(
data_type: MCIndLinksDataType,
frequency: Frequency,
mc_years: Optional[list[int]] = None,
links_ids: Optional[list[tuple[str, str]]] = None,
columns_names: Optional[list[str]] = None,
) -> DataFrame
Get an aggregation of individual results for specific links.
Given the parameters, it will aggregate data from files such as:
mc-ind/<mc_year>/links/<area_from> - <area_to>/<data_type>-<frequency>
generated by Antares Simulator.
Parameters:
-
(data_typeMCIndLinksDataType) –Here the nature of the results can only be "VALUES".
-
(frequencyFrequency) –Whether "HOURLY", "DAILY", "WEEKLY", "MONTHLY" or "ANNUAL", corresponding to the time step between each values in the output.
-
(mc_yearsOptional[list[int]], default:None) –List of the Monte-Carlo years index to fetch. If not indicated, all Monte-Carlo years are aggregated.
-
(links_idsOptional[list[tuple[str, str]]], default:None) –List of tuples ("area_from", "area_to") to fetch. If not indicated, all link IDs are aggregated.
-
(columns_namesOptional[list[str]], default:None) –List of the column names to fetch (apart from those automatically generated by the aggregation see below). If not indicated, all columns are taken into account for the aggregation.
Returns:
-
DataFrame–A dataframe aggregating all the data with at least the columns:
link,mcYearandtimeId.
Source code in src/antares/craft/model/output.py
get_binding_constraint_ts_numbers
Get binding constraint time series numbers for a given constraint group.
Returns:
Source code in src/antares/craft/model/output.py
get_hydro_ts_numbers
Get hydro time series numbers for a given area.
Returns:
Source code in src/antares/craft/model/output.py
get_link_ts_numbers
Get link time series numbers for a given link.
Returns:
Source code in src/antares/craft/model/output.py
get_load_ts_numbers
Get load time series numbers for a given area.
Returns:
Source code in src/antares/craft/model/output.py
get_mc_all_area
Get synthetic output data from a simulation for a specific area.
It will collect data from the file:
mc-all/areas/<area>/<data_type>-<frequency>
generated by Antares Simulator.
Parameters:
-
(frequencyFrequency) –Whether "HOURLY", "DAILY", "WEEKLY", "MONTHLY" or "ANNUAL", corresponding to the time step between each values in the output.
-
(data_typeMCAllAreasDataType) –Whether "VALUES", "DETAILS", "DETAILS_ST_STORAGE", "DETAILS_RES", "ID", corresponding to the nature of the result.
-
(areastr) –The area ID.
Returns:
-
DataFrame–A dataframe with all the synthetic results for an area.
The columns are multi-indexed with:
- output name
- unit
- statistical metric ("EXP", "std", "min", "max")
Source code in src/antares/craft/model/output.py
get_mc_all_link
get_mc_all_link(
frequency: Frequency, data_type: MCAllLinksDataType, area_from: str, area_to: str
) -> DataFrame
Get synthetic output data from a simulation for a specific link.
It will collect data from the file:
mc-all/links/<area_from> - <area_to>/<data_type>-<frequency>
generated by Antares Simulator.
Parameters:
-
(frequencyFrequency) –Whether "HOURLY", "DAILY", "WEEKLY", "MONTHLY" or "ANNUAL", corresponding to the time step between each values in the output.
-
(data_typeMCAllLinksDataType) –Whether "VALUES", "ID", corresponding to the nature of the result.
-
(area_fromstr) –Link starting point ID (first in alphabetical order).
-
(area_tostr) –Link ending point ID (second in alphabetical order).
Returns:
-
DataFrame–A dataframe with all the synthetic results for a link.
The columns are multi-indexed with:
- output name
- unit
- statistical metric ("EXP", "std", "min" or "max")
Source code in src/antares/craft/model/output.py
get_mc_ind_area
get_mc_ind_area(
mc_year: int, frequency: Frequency, data_type: MCIndAreasDataType, area: str
) -> DataFrame
Get output data for a single Monte-Carlo year and a specific area.
It will collect data from the file:
mc-ind/<mc_year>/areas/<area>/<data_type>-<frequency>
generated by Antares Simulator.
Parameters:
-
(mc_yearint) –Monte-Carlo year index.
-
(frequencyFrequency) –Whether "HOURLY", "DAILY", "WEEKLY", "MONTHLY" or "ANNUAL", corresponding to the time step between each values in the output.
-
(data_typeMCIndAreasDataType) –Whether "VALUES", "DETAILS", "DETAILS_ST_STORAGE", "DETAILS_RES", "ID", corresponding to the nature of the result.
-
(areastr) –The area ID.
Returns:
-
DataFrame–A dataframe with all the results for an individual Monte-Carlo year.
The columns are multi-indexed with:
- output name
- unit
For homogeneity with
get_mc_all_<area/link>methods, there is actually a last index that is an empty string as there is no statistical metric applied on the column.
Source code in src/antares/craft/model/output.py
get_mc_ind_link
get_mc_ind_link(
mc_year: int,
frequency: Frequency,
data_type: MCIndLinksDataType,
area_from: str,
area_to: str,
) -> DataFrame
Get output data for a single Monte-Carlo year and a specific link.
It will collect data from the file:
mc-ind/<mc_year>/links/<area_from> - <area_to>/<data_type>-<frequency>
generated by Antares Simulator.
Parameters:
-
(mc_yearint) –Monte-Carlo year index.
-
(frequencyFrequency) –Whether "HOURLY", "DAILY", "WEEKLY", "MONTHLY" or "ANNUAL", corresponding to the time step between each values in the output.
-
(data_typeMCIndLinksDataType) –Only possibility for the nature of the results which is "VALUES".
-
(area_fromstr) –Link starting point ID (first in alphabetical order).
-
(area_tostr) –Link ending point ID (second in alphabetical order).
Returns:
-
DataFrame–A dataframe with all the results for an individual Monte-Carlo year.
The columns are multi-indexed with:
- output name
- unit
For homogeneity with
get_mc_all_<area/link>methods, there is actually a last index that is an empty string as there is no statistical metric applied on the column.
Source code in src/antares/craft/model/output.py
get_solar_ts_numbers
Get solar time series numbers.
Returns:
Source code in src/antares/craft/model/output.py
get_st_storage_additional_constraints_numbers
get_st_storage_additional_constraints_numbers(
area_id: str, st_storage_id: str, constraint_id: str
) -> dict[int, int]
Get short-term storage additional constraints time series numbers for a given constraint.
Returns:
Source code in src/antares/craft/model/output.py
get_st_storage_inflows_numbers
Get short-term storage inflows time series numbers for a given st-storage.
Returns:
Source code in src/antares/craft/model/output.py
get_thermal_ts_numbers
Get thermal time series numbers for a given thermal cluster.
Returns:
Source code in src/antares/craft/model/output.py
get_wind_ts_numbers
Get wind time series numbers for a given area.
Returns:
Source code in src/antares/craft/model/output.py
get_xpansion_result
get_xpansion_result() -> XpansionResult
get_xpansion_sensitivity_result
get_xpansion_sensitivity_result() -> XpansionSensitivityResult
Get xpansion sensitivity results.
Returns:
-
XpansionSensitivityResult–Xpansion sensitivity results.
XpansionOutputAntares
dataclass
XpansionOutputAntares(version: str)
Output of Xpansion investment module.
Attributes:
-
version(str) –The version of the module used in the simulation.
XpansionOutputCandidate
dataclass
XpansionOutputCandidate(
solution: float,
max: float,
min: float,
iterations: list[XpansionOutputCandidateInvest],
)
Xpansion output candidate.
Attributes:
-
solution(float) –Invested capacity at the end of the algorithm.
-
max(float) –Maximum possible investment (in MW).
-
min(float) –Minimum possible investment (in MW).
-
iterations(list[XpansionOutputCandidateInvest]) –List of the output candidate investment for each iteration.
XpansionOutputCandidateInvest
dataclass
XpansionOutputCandidateInvest(invest: float)
Xpansion output candidate investment.
Attributes:
-
invest(float) –Amount of investment for a given candidate.
XpansionOutputCandidateSensitivity
dataclass
XpansionOutputCandidateSensitivity(
lb: float,
ub: float,
solution_max: XpansionOutputCandidateInvest,
solution_min: XpansionOutputCandidateInvest,
)
Xpansion output candidate sensitivity study.
Attributes:
-
lb(float) –Minimum possible invested capacity.
-
ub(float) –Maximum possible invested capacity.
-
solution_max(XpansionOutputCandidateInvest) –Maximum invested capacity in a near-optimal solution.
-
solution_min(XpansionOutputCandidateInvest) –Minimum invested capacity in a near-optimal solution.
XpansionOutputIteration
dataclass
XpansionOutputIteration(
best_ub: float,
cumulative_number_of_subproblem_resolutions: int,
investment_cost: float,
lb: float,
master_duration: float,
operational_cost: float,
optimality_gap: float,
overall_cost: float,
relative_gap: float,
subproblem_duration: float,
ub: float,
)
Xpansion output for a given iteration.
Attributes:
-
best_ub(float) –Best upper bound on the optimal cost.
-
cumulative_number_of_subproblem_resolutions(int) –Cumulative number of subproblems solved from the beginning of the Benders algorithm.
-
investment_cost(float) –Investment cost of the solution at the current iteration.
-
lb(float) –Lower bound on the optimal cost: this is the solution of the master problem as it is a relaxation of the investment problem.
-
master_duration(float) –Duration of the master problem resolution.
-
operational_cost(float) –Expectation of the yearly operational cost over all MC years of the linear relaxation of an Antares simulation for the system with the current iteration investment level.
-
optimality_gap(float) –Absolute gap between the lb and the best_ub (
(best_ub - lb)). -
overall_cost(float) –Sum of
investment costandoperational_cost. -
relative_gap(float) –At each iteration, the algorithm computes upper and lower bounds on the optimal cost. The algorithm stops as soon as the quantity
(best_ub - lb) / max(|best_ub|, |lb|)falls below relative_gap. For a relative gap \(\alpha\), the cost of the solution returned by the algorithm satisfies: $\(\frac{{\scriptstyle\texttt{xpansion solution cost}} - {\scriptstyle\texttt{optimal cost}}}{{\scriptstyle\texttt{optimal cost}}} < \alpha\)$. -
subproblem_duration(float) –Wall time for the resolution of all weekly Antares subproblems at the current iteration.
-
ub(float) –Overall cost of the solution of the current iteration. This may be greater than
best_ubif a previous iteration led to a better solution.
XpansionOutputOptions
dataclass
Options of Xpansion output.
Attributes:
-
log_level(int) –Solver's log severity in {0, 1, 2}.
-
master_name(str) –Name of the master problem file (automatically generated).
-
problem_format(str) –- MPS: Problems in MPS text format.
- OPTIMIZED: Problems in binary SVF format.
-
solver_name(str) –Solver used for the resolution of the optimization problem.
XpansionOutputSensitivitySolution
dataclass
XpansionOutputSensitivitySolution(
objective: float, problem_type: str, status: int, system_cost: float
)
Xpansion output sensitivity solution.
Attributes:
-
objective(float) –Objective value of the solution of the sensitivity analysis.
-
problem_type(str) –- "capex": Find a near-optimal solution with min or max capex.
- "investment
": Find a near-optimal solution that minimizes or maximizes the investment for a given asset.
-
status(int) –Problem status.
-
system_cost(float) –System cost with the solution of the sensitivity analysis.
XpansionOutputSolution
dataclass
XpansionOutputSolution(
investment_cost: float,
iteration: int,
operational_cost: float,
optimality_gap: float,
overall_cost: float,
problem_status: str,
relative_gap: float,
stopping_criterion: str,
)
Xpansion output solution.
Attributes:
-
investment_cost(float) –Optimal investment cost found by the algorithm.
-
iteration(int) –Corresponding iteration for the best solution.
-
operational_cost(float) –Expectation of the yearly operational cost over all MC years of the linear relaxation of an Antares simulation for the system with the best investment.
-
optimality_gap(float) –Absolute gap between the lb and the best_ub (
(best_ub - lb)). -
overall_cost(float) –Sum of investment cost and
operational_cost. -
problem_status(str) –Problem status.
-
relative_gap(float) –At each iteration, the algorithm computes upper and lower bounds on the optimal cost. The algorithm stops as soon as the quantity
(best_ub - lb) / max(|best_ub|, |lb|)falls below relative_gap. For a relative gap \(\alpha\), the cost of the solution returned by the algorithm satisfies: $\(\frac{{\scriptstyle\texttt{xpansion solution cost}} - {\scriptstyle\texttt{optimal cost}}}{{\scriptstyle\texttt{optimal cost}}} < \alpha\)$. -
stopping_criterion(str) –Stopping criterion for the optimization problem.
XpansionResult
dataclass
XpansionResult(
antares: XpansionOutputAntares,
antares_xpansion: XpansionOutputAntares,
begin: datetime,
end: datetime,
iterations: dict[int, XpansionOutputIteration],
nb_weeks: int,
options: XpansionOutputOptions,
run_duration: float,
solution: XpansionOutputSolution,
candidates: dict[str, XpansionOutputCandidate],
)
Xpansion results.
Attributes:
-
antares(XpansionOutputAntares) –Antares version information.
-
antares_xpansion(XpansionOutputAntares) –Antares-Xpansion version information.
-
begin(datetime) –Timestamp of the start of the problem resolution.
-
end(datetime) –Timestamp of the end of the problem resolution.
-
iterations(dict[int, XpansionOutputIteration]) –Dictionary of all Benders iteration outputs.
-
nb_weeks(int) –Number of subproblems (= number of MC years × number of weeks solved per year).
-
options(XpansionOutputOptions) –Options for Xpansion module.
-
run_duration(float) –Duration of the problem resolution.
-
solution(XpansionOutputSolution) –Final optimal solution.
-
candidates(dict[str, XpansionOutputCandidate]) –Dictionary of all candidates.
XpansionSensitivityResult
dataclass
XpansionSensitivityResult(
antares: XpansionOutputAntares,
antares_xpansion: XpansionOutputAntares,
best_benders_cost: float,
epsilon: float,
candidates: dict[str, XpansionOutputCandidateSensitivity],
solution_max: XpansionOutputSensitivitySolution,
solution_min: XpansionOutputSensitivitySolution,
)
Xpansion sensitivity results.
Attributes:
-
antares(XpansionOutputAntares) –Antares version information.
-
antares_xpansion(XpansionOutputAntares) –Antares-Xpansion version information.
-
best_benders_cost(float) –Optimal objective value of the investment problem before the sensitivity analysis.
-
epsilon(float) –Allowed gap with
best_benders_costto consider that a solution is near-optimal (i.e. will be considered in the sensitivity analysis). -
candidates(dict[str, XpansionOutputCandidateSensitivity]) –Dictionary of candidate solutions for the sensitivity analysis.
-
solution_max(XpansionOutputSensitivitySolution) –Solution of the sensitivity analysis that maximises the objective.
-
solution_min(XpansionOutputSensitivitySolution) –Solution of the sensitivity analysis that minimises the objective.