cosmotech.coal.csm.engine¶
engine
¶
apply_simple_csv_parameter_to_simulator(simulator, parameter_name, target_attribute_name, csv_id_column='id', csv_value_column='value')
¶
Accelerator used to apply CSV parameters directly to a simulator Will raise a ValueError if the parameter does not exist If an entity is not found, will skip the row in the CSV
Parameters:
Name | Type | Description | Default |
---|---|---|---|
simulator
|
The simulator object to which the parameter will be applied |
required | |
parameter_name
|
str
|
The name of the parameter fetched from the API |
required |
target_attribute_name
|
str
|
Target attribute of the entities listed in the CSV |
required |
csv_id_column
|
str
|
Column in the CSV file used for the entity ID |
'id'
|
csv_value_column
|
str
|
Column in the CSV file used for the attribute value to change |
'value'
|
Returns:
Type | Description |
---|---|
None |
Source code in cosmotech/coal/csm/engine/__init__.py
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 |
|