diff --git a/cost_estimation/cost_estimation.py b/cost_estimation/cost_estimation.py index 4cd8c941b099cd7a49e51d2b9ac7929ac9bf1a50..e451c411718613c1cba2eeaca1591f91c97c3532 100644 --- a/cost_estimation/cost_estimation.py +++ b/cost_estimation/cost_estimation.py @@ -51,12 +51,13 @@ def main(): # Initialize exception string and runtime output logger. tool_name = 'cost estimation' + tool_version = '0.5.0' runtime_output = logging.getLogger('module_logger') try: """Preprocessing: Acquire necessary data and paths.""" # Run 'data_preprocessing' function from 'datapreprocessing.py'. - paths_and_names, routing_dict, runtime_output = data_preprocessing("cost_estimation_conf.xml", argv) + paths_and_names, routing_dict, runtime_output = data_preprocessing("cost_estimation_conf.xml", tool_version, argv) runtime_output.print("Cost estimation started...") """Run: Execute code depending on method layers.""" diff --git a/cost_estimation/src/datapreprocessing.py b/cost_estimation/src/datapreprocessing.py index a1399f078a41489d7893e786a86589315b4032f3..d918b2c951f4aaa44fdfd1727731163337ab1205 100644 --- a/cost_estimation/src/datapreprocessing.py +++ b/cost_estimation/src/datapreprocessing.py @@ -28,7 +28,7 @@ from datapreprocessingmodule import get_paths_and_names, read_routing_values_fro from src.readlayertext import read_energy_carrier -def data_preprocessing(module_configuration_file, argv): +def data_preprocessing(module_configuration_file, tool_version, argv): """Conduct data preprocessing. This function provides data preprocessing functionalities. It sets up the necessary data and imports relevant @@ -61,6 +61,7 @@ def data_preprocessing(module_configuration_file, argv): """Get paths, names, and xml trees for module configuration and aircraft exchange file.""" # Call 'get_paths_and_names' function to obtain various paths and names. paths_and_names, runtime_output = get_paths_and_names(module_configuration_file, argv) + paths_and_names['tool_version'] = tool_version # Note: It is the exclusive responsibility of the module manager to modify the following information! # Create layer description dictionary according to the number of individual layers. The dictionary associates # layers with their respective XML paths and expected data types according to the following scheme: diff --git a/cost_estimation/src/tube_and_wing/empirical/operating_cost_estimation_tu_berlin/general/methodhtmlreport.py b/cost_estimation/src/tube_and_wing/empirical/operating_cost_estimation_tu_berlin/general/methodhtmlreport.py index 3333e12257e66780fe5d745fc24174dc7ca399bd..46efc077080041a50cbb562c027cfebb3261f499 100644 --- a/cost_estimation/src/tube_and_wing/empirical/operating_cost_estimation_tu_berlin/general/methodhtmlreport.py +++ b/cost_estimation/src/tube_and_wing/empirical/operating_cost_estimation_tu_berlin/general/methodhtmlreport.py @@ -40,6 +40,7 @@ def method_html_report(paths_and_names, routing_dict, data_dict, method_specific """ Preparation.""" # Extract tool and project name. tool_name = paths_and_names['tool_name'] + tool_version = paths_and_names['tool_version'] report_title = (tool_name.replace('_', ' ')).capitalize() project_name = paths_and_names['name_of_project'] root_of_module_config_tree = paths_and_names['root_of_module_config_tree'] @@ -151,8 +152,13 @@ def method_html_report(paths_and_names, routing_dict, data_dict, method_specific with tag('div', klass="content"): with tag('h1'): text(f"Report - {report_title} of {project_name}") + with tag('br'): # Line break for formatting + pass + with tag('span'): + with tag('font', size="2"): + text(f"All outputs of the program '{tool_name}' were created with version {tool_version}") + with tag('div', klass="container"): - # Data on the left side. with tag('div', klass="box data"): # Add small description. diff --git a/fuselage_design/fuselage_design.py b/fuselage_design/fuselage_design.py index 88d27d3da6d86bab8d7d76e64451a702e7881352..6f8b2b67d31b14b8b4b3aa89a79ac63e419e6b55 100644 --- a/fuselage_design/fuselage_design.py +++ b/fuselage_design/fuselage_design.py @@ -50,12 +50,13 @@ def main(): # Initialize exception string and runtime output logger. tool_name = 'fuselage design' + tool_version = '0.5.0' runtime_output = logging.getLogger('module_logger') try: """Preprocessing: Acquire necessary data and paths.""" # Run 'data_preprocessing' function from 'datapreprocessing.py'. - paths_and_names, routing_dict, runtime_output = data_preprocessing('fuselage_design_conf.xml', argv) + paths_and_names, routing_dict, runtime_output = data_preprocessing('fuselage_design_conf.xml', tool_version, argv) runtime_output.print('Fuselage design started...') """Run: Execute code depending on method layers.""" diff --git a/fuselage_design/src/datapreprocessing.py b/fuselage_design/src/datapreprocessing.py index f260413c531c0640f36b7a27fdbfe61046b03ecb..b19466a99693f782a9c7b356f4a4284b70acff5c 100644 --- a/fuselage_design/src/datapreprocessing.py +++ b/fuselage_design/src/datapreprocessing.py @@ -29,7 +29,7 @@ from datapreprocessingmodule import get_paths_and_names from datapreprocessingmodule import read_routing_values_from_xml -def data_preprocessing(module_configuration_file, argv): +def data_preprocessing(module_configuration_file, tool_version, argv): """Conduct data preprocessing. This function provides data preprocessing functionalities. It sets up the necessary data and imports @@ -60,6 +60,7 @@ def data_preprocessing(module_configuration_file, argv): """Get paths, names, and xml trees for module configuration and aircraft exchange file.""" # Call 'get_paths_and_names' function to obtain various paths and names. paths_and_names, runtime_output = get_paths_and_names(module_configuration_file, argv) + paths_and_names['tool_version'] = tool_version # Note: It is the exclusive responsibility of the module manager to modify the following information! # Create layer description dictionary according to the number of individual layers. The dictionary associates # layers with their respective XML paths and expected data types according to the following scheme: diff --git a/fuselage_design/src/tube_and_wing/empirical/fuselage_design_tu_berlin/general/methodhtmlreport.py b/fuselage_design/src/tube_and_wing/empirical/fuselage_design_tu_berlin/general/methodhtmlreport.py index 92835ef9dd532eedd2ce2297d5edc9399d77c290..33fd241b9e742f816e8b268614eb39569c3081e1 100644 --- a/fuselage_design/src/tube_and_wing/empirical/fuselage_design_tu_berlin/general/methodhtmlreport.py +++ b/fuselage_design/src/tube_and_wing/empirical/fuselage_design_tu_berlin/general/methodhtmlreport.py @@ -40,6 +40,7 @@ def method_html_report(paths_and_names, routing_dict, data_dict, method_specific """ Preparation and data extraction.""" # Extract tool and project name. tool_name = paths_and_names['tool_name'] + tool_version = paths_and_names['tool_version'] report_title = (tool_name.replace('_', ' ')).capitalize() project_name = paths_and_names['name_of_project'] root_of_module_config_tree = paths_and_names['root_of_module_config_tree'] @@ -208,8 +209,13 @@ def method_html_report(paths_and_names, routing_dict, data_dict, method_specific with tag('div', klass="content"): with tag('h1'): text(f"Report - {report_title} of {project_name}") + with tag('br'): # Line break for formatting + pass + with tag('span'): + with tag('font', size="2"): + text(f"All outputs of the program '{tool_name}' were created with version {tool_version}") + with tag('div', klass="container"): - # Data on the left side. with tag('div', klass="box data"): @@ -270,14 +276,8 @@ def method_html_report(paths_and_names, routing_dict, data_dict, method_specific text("Plots") # 3D shape. with tag('h3'): - text('Fuselage 3D shape') - src_name = "../plots/fuselage_design_3D_shape.svg" - with tag('img',src=src_name, klass="image-plot", style="margin-bottom: 20px;"): - pass - # 3D shape. - with tag('h3'): - text('Fuselage isometric view') - src_name = "../plots/fuselage_design_Isometric view of fuselage shape.svg" + text('Fuselage side view') + src_name = "../plots/fuselage_design_side view of fuselage.svg" with tag('img',src=src_name, klass="image-plot", style="margin-bottom: 20px;"): pass diff --git a/fuselage_design/src/tube_and_wing/empirical/fuselage_design_tu_berlin/general/methodplot.py b/fuselage_design/src/tube_and_wing/empirical/fuselage_design_tu_berlin/general/methodplot.py index b66f7f0e394998761269b14434edb6052ded4988..7f91be6f26ef05510ca76b6aa8ad1fa53a2dc0df 100644 --- a/fuselage_design/src/tube_and_wing/empirical/fuselage_design_tu_berlin/general/methodplot.py +++ b/fuselage_design/src/tube_and_wing/empirical/fuselage_design_tu_berlin/general/methodplot.py @@ -70,7 +70,7 @@ def create_fuselage_3d_plot(paths_and_names, data_dict, plot_directory, runtime_ """ ''' Plot of front view ''' # Generate figure. - plot_title = 'Isometric view of fuselage shape' + plot_title = 'Side view of fuselage' fig = plt.figure(figsize=(12, 7.5)) ax = fig.add_subplot(111, projection='3d') diff --git a/libs b/libs index 47e224dd8c3e17185ff61f0916a7a637a72125c5..89f0b30f7835b7be4b8edef43d9eb2c1764cb6d0 160000 --- a/libs +++ b/libs @@ -1 +1 @@ -Subproject commit 47e224dd8c3e17185ff61f0916a7a637a72125c5 +Subproject commit 89f0b30f7835b7be4b8edef43d9eb2c1764cb6d0 diff --git a/tank_design/src/datapreprocessing.py b/tank_design/src/datapreprocessing.py index 04055070dd307ef78f97279aacc083199f6f1a19..38882742c9f4d4f784018cce24fc395f29143477 100644 --- a/tank_design/src/datapreprocessing.py +++ b/tank_design/src/datapreprocessing.py @@ -28,7 +28,7 @@ from datapreprocessingmodule import get_paths_and_names, read_routing_values_fro from src.readlayertext import read_energy_carrier -def data_preprocessing(module_configuration_file, argv): +def data_preprocessing(module_configuration_file, tool_version, argv): """Conduct data preprocessing. This function provides data preprocessing functionalities. It sets up the necessary data and imports relevant @@ -61,7 +61,8 @@ def data_preprocessing(module_configuration_file, argv): """Get paths, names, and xml trees for module configuration and aircraft exchange file.""" # Call 'get_paths_and_names' function to obtain various paths and names. paths_and_names, runtime_output = get_paths_and_names(module_configuration_file, argv) - + paths_and_names['tool_version'] = tool_version + """ Extract data from aircraft exchange and module configuration file.""" # Extract root and path to aircraft exchange file and write key data to aircraft exchange file. root_of_aircraft_exchange_tree = paths_and_names['root_of_aircraft_exchange_tree'] diff --git a/tank_design/src/tube_and_wing/empirical/tank_design_tu_berlin/general/methodhtmlreport.py b/tank_design/src/tube_and_wing/empirical/tank_design_tu_berlin/general/methodhtmlreport.py index e1c96f41c6c906602e8d43cbb974da9b8ba83038..a4f8daaf68ea4856c00801fd393ae5dbddda9944 100644 --- a/tank_design/src/tube_and_wing/empirical/tank_design_tu_berlin/general/methodhtmlreport.py +++ b/tank_design/src/tube_and_wing/empirical/tank_design_tu_berlin/general/methodhtmlreport.py @@ -40,6 +40,7 @@ def method_html_report(paths_and_names, routing_dict, data_dict, method_specific """ Preparation.""" # Extract tool and project name. tool_name = paths_and_names['tool_name'] + tool_version = paths_and_names['tool_version'] report_title = (tool_name.replace('_', ' ')).capitalize() project_name = paths_and_names['name_of_project'] root_of_module_config_tree = paths_and_names['root_of_module_config_tree'] @@ -106,8 +107,13 @@ def method_html_report(paths_and_names, routing_dict, data_dict, method_specific with tag('div', klass="content"): with tag('h1'): text(f"Report - {report_title} of {project_name}") + with tag('br'): # Line break for formatting + pass + with tag('span'): + with tag('font', size="2"): + text(f"All outputs of the program '{tool_name}' were created with version {tool_version}") + with tag('div', klass="container"): - # Data on the left side. with tag('div', klass="box data"): with tag('h2'): diff --git a/tank_design/tank_design.py b/tank_design/tank_design.py index 5d3ec4169dad95d8f4e4ccd0671cd0882d68acfd..3b652ebd284b1437d494829275f2da119231fa4a 100644 --- a/tank_design/tank_design.py +++ b/tank_design/tank_design.py @@ -51,12 +51,13 @@ def main(): # Initialize exception string and runtime output logger. tool_name = 'tank design' + tool_version = '0.5.0' runtime_output = logging.getLogger('module_logger') try: """Preprocessing: Acquire necessary data and paths.""" # Run 'data_preprocessing' function from 'datapreprocessing.py'. - paths_and_names, routing_dict, runtime_output = data_preprocessing('tank_design_conf.xml', argv) + paths_and_names, routing_dict, runtime_output = data_preprocessing('tank_design_conf.xml', tool_version, argv) runtime_output.print('Tank design started...') """Run: Execute code depending on method layers.""" diff --git a/weight_and_balance_analysis/src/datapreprocessing.py b/weight_and_balance_analysis/src/datapreprocessing.py index 05da58a96ddbfa24f67904c06f2c43ccaf32eaa3..afbf9f119c7a4bfe446032d4342e96fae3c71e78 100644 --- a/weight_and_balance_analysis/src/datapreprocessing.py +++ b/weight_and_balance_analysis/src/datapreprocessing.py @@ -27,7 +27,7 @@ import sys from datapreprocessingmodule import get_paths_and_names, read_routing_values_from_xml -def data_preprocessing(module_configuration_file, argv): +def data_preprocessing(module_configuration_file, tool_version, argv): """Conduct data preprocessing. This function provides data preprocessing functionalities. It sets up the necessary data and imports @@ -55,6 +55,8 @@ def data_preprocessing(module_configuration_file, argv): # Call 'get_paths_and_names' function to obtain various paths and names. paths_and_names, runtime_output = get_paths_and_names( module_configuration_file, argv) + paths_and_names['tool_version'] = tool_version + # Note: It is the exclusive responsibility of the module manager to modify the following information! # Create layer description dictionary according to the number of individual layers. # The dictionary associates layers with their respective XML paths and expected data types according to the diff --git a/weight_and_balance_analysis/src/tube_and_wing/standard/general/methodhtmlreport.py b/weight_and_balance_analysis/src/tube_and_wing/standard/general/methodhtmlreport.py index 2fa87b68fcba81f6e98b2a9085f7688ce8be9702..7a2e0152303f265924ec205ab3ed5c4cede28e54 100644 --- a/weight_and_balance_analysis/src/tube_and_wing/standard/general/methodhtmlreport.py +++ b/weight_and_balance_analysis/src/tube_and_wing/standard/general/methodhtmlreport.py @@ -38,6 +38,7 @@ def method_html_report(paths_and_names, routing_dict, data_dict, method_specific # This is just a dummy code snippet. Insert your code here. tool_name = paths_and_names['tool_name'] + tool_version = paths_and_names['tool_version'] report_title = camelcase_to_string(tool_name) project_name = paths_and_names['name_of_project'] @@ -142,6 +143,12 @@ def method_html_report(paths_and_names, routing_dict, data_dict, method_specific with tag('div', klass="content"): with tag('h1'): text(f"Report - {report_title} of {project_name}") + with tag('br'): # Line break for formatting + pass + with tag('span'): + with tag('font', size="2"): + text(f"All outputs of the program '{tool_name}' were created with version {tool_version}") + with tag('div', klass="container"): with tag('div', klass="box data"): with tag('h2'): diff --git a/weight_and_balance_analysis/weight_and_balance_analysis.py b/weight_and_balance_analysis/weight_and_balance_analysis.py index 917b06438c4ffa0fca7e43ed2931ce4b141a8e63..aebca851aa392af54181d7823903f6d25ab3efe7 100644 --- a/weight_and_balance_analysis/weight_and_balance_analysis.py +++ b/weight_and_balance_analysis/weight_and_balance_analysis.py @@ -65,12 +65,13 @@ def main(): # Initialize exception string and runtime output logger. runtime_output = logging.getLogger('module_logger') tool_name = "Weight and Balance" + tool_version = '0.5.0' try: """Preprocessing: Acquire necessary data and paths.""" # Run 'data_preprocessing' function from 'datapreprocessing.py'. paths_and_names, routing_dict, runtime_output = data_preprocessing( - module_config_file, argv) + module_config_file, tool_version, argv) runtime_output.print(f'{module_name} started...') """Run: Execute code depending on method layers."""