Antares Xpansion
Investment simulations for Antares studies
Loading...
Searching...
No Matches
antares_xpansion.config_loader.ConfigLoader Class Reference

Classes

class  InvalidSimulationName
 
class  MissingAntaresOutput
 
class  MissingFile
 
class  MissingSimulationName
 
class  NotAnXpansionOutputDir
 

Public Member Functions

 __init__ (self, XpansionConfig config)
 
 check_candidates_file_format (self)
 
 check_settings_file_format (self)
 
 antares_output (self)
 
 exe_path (self, exe)
 
 data_dir (self)
 
 weight_file_name (self)
 
 general_data (self)
 
 candidates_ini_filepath (self)
 
 capacity_file (self, filename)
 
 json_sensitivity_in_path (self)
 
 weights_file_path (self)
 
 get_absolute_optimality_gap (self)
 
 get_relative_optimality_gap (self)
 
 get_relaxed_optimality_gap (self)
 
 get_max_iterations (self)
 
 get_master_formulation (self)
 
 get_separation (self)
 
 get_batch_size (self)
 
 additional_constraints (self)
 
 simulation_lp_path (self)
 
Path xpansion_simulation_output (self)
 
Path simulation_output_path (self)
 
 benders_pre_actions (self)
 
 save_launcher_options (self)
 
 launcher_options_file_path (self)
 
 create_expansion_dir (self)
 
 expansion_dir (self)
 
 options_file_path (self)
 
 options_file_name (self)
 
 is_zip (self, study)
 
 update_last_study_with_sensitivity_results (self)
 
 is_antares_study_output (self, Path study)
 
Path last_modified_study (self, Path root_dir)
 
 is_accurate (self)
 
 is_relaxed (self)
 
bool keep_mps (self)
 
 antares_exe (self)
 
 lp_namer_exe (self)
 
 benders_exe (self)
 
 merge_mps_exe (self)
 
 study_update_exe (self)
 
 sensitivity_exe (self)
 
 full_run_exe (self)
 
 antares_archive_updater_exe (self)
 
 method (self)
 
 n_mpi (self)
 
 step (self)
 
 simulation_name (self)
 
 antares_n_cpu (self)
 
 json_file_path (self)
 
 json_name (self)
 
 last_iteration_json_file_path (self)
 
 last_iteration_json_file_name (self)
 
 json_sensitivity_out_path (self)
 
 structure_file_path (self)
 
 last_master_file_path (self)
 
 last_master_basis_path (self)
 
 oversubscribe (self)
 
 allow_run_as_root (self)
 
 timelimit (self)
 
 log_level (self)
 
Path sensitivity_log_file (self)
 
 check_NTC_column_constraints (self, antares_version)
 
 mpi_exe (self)
 

Public Attributes

 platform
 
 logger
 
 candidates_list
 
 active_years
 
 options
 

Protected Member Functions

 _set_simulation_name (self)
 
 _restore_launcher_options (self)
 
 _verify_settings_ini_file_exists (self)
 
 _get_options_from_settings_inifile (self)
 
 _get_settings_ini_filepath (self)
 
 _get_path_from_file_in_xpansion_dir (self, filename)
 
 _get_weight_file_path_in_weights_dir (self, filename)
 
 _get_constraints_file_path_in_constraints_dir (self, filename)
 
 _simulation_lp_path (self)
 
 _verify_additional_constraints_file (self)
 
 _verify_solver (self)
 
 _create_sensitivity_dir (self)
 
 _sensitivity_dir (self)
 
 _set_options_for_benders_solver (self)
 
 _set_last_simulation_name (self)
 
 _set_xpansion_simulation_name (self)
 

Protected Attributes

 _config
 
 _last_study
 
 _xpansion_simulation_name
 

Detailed Description

Class to control the execution of the optimization session

Constructor & Destructor Documentation

◆ __init__()

antares_xpansion.config_loader.ConfigLoader.__init__ (   self,
XpansionConfig  config 
)
Initialise driver with a given antaresXpansion configuration,
the system platform and parses the arguments
:param config: configuration to use for the optimization
:type config: XpansionConfig object

Member Function Documentation

◆ _get_settings_ini_filepath()

antares_xpansion.config_loader.ConfigLoader._get_settings_ini_filepath (   self)
protected
returns path to setting ini file

◆ _set_last_simulation_name()

antares_xpansion.config_loader.ConfigLoader._set_last_simulation_name (   self)
protected
return last simulation name

◆ _set_options_for_benders_solver()

antares_xpansion.config_loader.ConfigLoader._set_options_for_benders_solver (   self)
protected
generates a default option file for the solver

◆ additional_constraints()

antares_xpansion.config_loader.ConfigLoader.additional_constraints (   self)
returns path to additional constraints file

◆ antares_output()

antares_xpansion.config_loader.ConfigLoader.antares_output (   self)
returns path to antares output data directory

◆ candidates_ini_filepath()

antares_xpansion.config_loader.ConfigLoader.candidates_ini_filepath (   self)
returns path to candidates ini file

◆ capacity_file()

antares_xpansion.config_loader.ConfigLoader.capacity_file (   self,
  filename 
)
returns path to input capacity file

◆ data_dir()

antares_xpansion.config_loader.ConfigLoader.data_dir (   self)
returns path to the data directory

◆ exe_path()

antares_xpansion.config_loader.ConfigLoader.exe_path (   self,
  exe 
)
prefixes the input exe with the install directory containing the binaries

:param exe: executable name

:return: path to specified executable

◆ general_data()

antares_xpansion.config_loader.ConfigLoader.general_data (   self)
returns path to general data ini file

◆ get_absolute_optimality_gap()

antares_xpansion.config_loader.ConfigLoader.get_absolute_optimality_gap (   self)
returns the absolute optimality gap read from the settings file
:return: gap value or 0 if the gap is negative

◆ get_batch_size()

antares_xpansion.config_loader.ConfigLoader.get_batch_size (   self)
return the batch_size read from the settings file

◆ get_master_formulation()

antares_xpansion.config_loader.ConfigLoader.get_master_formulation (   self)
return master formulation read from the settings file

◆ get_max_iterations()

antares_xpansion.config_loader.ConfigLoader.get_max_iterations (   self)
prints and returns the maximum iterations read from the settings file

:return: max iterations value or -1 if the parameter is set to +Inf or +infini

◆ get_relative_optimality_gap()

antares_xpansion.config_loader.ConfigLoader.get_relative_optimality_gap (   self)
returns the relative optimality gap read from the settings file
:return: gap value or 1e-12 if the value is set to a lower value than 1e-12

◆ get_relaxed_optimality_gap()

antares_xpansion.config_loader.ConfigLoader.get_relaxed_optimality_gap (   self)
returns the relaxed optimality gap read from the settings file
:return: gap value or 1e-12 if the value is set to a lower value than 1e-12

◆ get_separation()

antares_xpansion.config_loader.ConfigLoader.get_separation (   self)
return the separation parameter read from the settings file

◆ is_accurate()

antares_xpansion.config_loader.ConfigLoader.is_accurate (   self)
indicates if method to use is accurate by reading the uc_type in the settings file

◆ is_relaxed()

antares_xpansion.config_loader.ConfigLoader.is_relaxed (   self)
indicates if method to use is relaxed by reading the relaxation_type
from the settings file

◆ json_sensitivity_in_path()

antares_xpansion.config_loader.ConfigLoader.json_sensitivity_in_path (   self)
returns path to sensitivity input file

◆ log_level()

antares_xpansion.config_loader.ConfigLoader.log_level (   self)
returns the log_level read from the settings file
:return: log_level value

◆ timelimit()

antares_xpansion.config_loader.ConfigLoader.timelimit (   self)
returns the timelimit read from the settings file
:return: timelimit value or 0 if the gap is negative

◆ weights_file_path()

antares_xpansion.config_loader.ConfigLoader.weights_file_path (   self)
returns the path to a yearly-weights file

:return: path to input yearly-weights file

The documentation for this class was generated from the following file: