ethos_penalps.process_chain#

Module Contents#

Classes#

ProcessChain

The Process Chain is a collector class for sequentially depending process steps.

ProcessChainFactor

The Process Chain is a collector class for sequentially depending process steps.

Attributes#

logger

ethos_penalps.process_chain.logger#
class ethos_penalps.process_chain.ProcessChain(process_chain_identifier: ethos_penalps.data_classes.ProcessChainIdentifier, production_plan: ethos_penalps.production_plan.ProductionPlan, load_profile_handler: ethos_penalps.load_profile_calculator.LoadProfileHandler, time_data: ethos_penalps.time_data.TimeData = TimeData(), location: str = '')#

The Process Chain is a collector class for sequentially depending process steps. When an enterprise is fully defined the simulation can be started with create_production_plan. Also contains methods for report generation of the enterprise definition and report generation

get_process_node_dict_without_sink_and_source() dict[str, ethos_penalps.process_nodes.process_node.ProcessNode]#
create_failed_report()#
pickle_dump_production_plan(file_name: str = 'production_plan', subdirectory_name: str = 'production_plan', add_time_stamp_to_filename: bool = True)#
pickle_load_production_plan(path_to_pickle_file: str)#
initialize_production_plan()#

Collects steps that are necessary to conduct before each simulation. Creates empty entries for each process node and stream in the production plan. Collects the energy data from streams

collect_stream_energy_data()#

Collects the energy data from streams into the load profile handler. This allows calculation of the energy data from a central object

collect_process_state_energy_data()#
add_process_node(process_node_to_add: ethos_penalps.process_nodes.process_step.ProcessStep | ethos_penalps.process_nodes.source.Source | ethos_penalps.process_nodes.sink.Sink | ethos_penalps.process_nodes.process_chain_storage.ProcessChainStorage)#

Adds a process node object to the process_node_dict of EnterpriseStructure to consider the node during the simulation

Parameters:

process_node_to_add (ProcessStep | Source | Sink) – A ProcessStep, Source or Sink object which inherited from process node

Raises:

Exception – _description_

get_process_node(process_node_name: str) ethos_penalps.process_nodes.process_node.ProcessNode#

Returns a process node object based on its name

Parameters:

process_node_name (str) – Name of the process node.

Returns:

_description_

Return type:

ProcessNode

create_process_step(name: str) ethos_penalps.process_nodes.process_step.ProcessStep#

Creates a process step.

Parameters:

name (str) – _description_

Returns:

_description_

Return type:

ProcessStep

get_sink() ethos_penalps.process_nodes.sink.Sink | ethos_penalps.process_nodes.process_chain_storage.ProcessChainStorage#

Returns a Sink

Raises:

Exception – _description_

Returns:

_description_

Return type:

Sink

create_process_chain_production_plan(max_number_of_iterations: float | None = None)#

Creates a production plan to produce all orders in the Sink object. Each process step between the Source and Sink object is considered. Process step can create a node operation for the upstream or downstream node. These operations are used creates a network of so called production and temporal branches. These are used to ensure that all process steps work in temporal and logically coherent way to fulfill an order in the Sink. When a valid production plan entry is created the related energy consumption for the time period is created and stored in the LoadProfileHandler.

get_node_from_node_operation(node_operation: ethos_penalps.node_operations.NodeOperation) ethos_penalps.process_nodes.process_node.ProcessNode | None#

Returns a target ProcessNode object of a NodeOperation Object.

Parameters:

node_operation (NodeOperation) – _description_

Raises:

Exception – _description_

Returns:

_description_

Return type:

ProcessNode | None

add_sink(sink: ethos_penalps.process_nodes.sink.Sink | ethos_penalps.process_nodes.process_chain_storage.ProcessChainStorage)#
add_source(source: ethos_penalps.process_nodes.source.Source | ethos_penalps.process_nodes.process_chain_storage.ProcessChainStorage)#
get_main_sink() ethos_penalps.process_nodes.sink.Sink#
get_list_of_process_step_names(include_sink: bool = False, include_source: bool = False) list[str]#

Returns a list of the names of the main object node chain.

Returns:

_description_

Return type:

list[str]

class ethos_penalps.process_chain.ProcessChainFactor(process_chain_identifier: ethos_penalps.data_classes.ProcessChainIdentifier, production_plan: ethos_penalps.production_plan.ProductionPlan, load_profile_handler: ethos_penalps.load_profile_calculator.LoadProfileHandler, time_data: ethos_penalps.time_data.TimeData = TimeData(), location: str = '')#

Bases: ProcessChain

The Process Chain is a collector class for sequentially depending process steps. When an enterprise is fully defined the simulation can be started with create_production_plan. Also contains methods for report generation of the enterprise definition and report generation

create_replicas()#