gearmaster 0.1.0__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of gearmaster might be problematic. Click here for more details.
- GM_Visual/INSTALLATION.md +158 -0
- GM_Visual/__init__.py +35 -0
- GM_Visual/core.py +32 -0
- GM_Visual/docs/README.md +57 -0
- GM_Visual/docs/canvas.md +210 -0
- GM_Visual/docs/core/config_manager.md +425 -0
- GM_Visual/docs/core/execution_engine.md +521 -0
- GM_Visual/docs/core/installation_manager.md +467 -0
- GM_Visual/docs/core/node_base.md +749 -0
- GM_Visual/docs/core/pin_system.md +566 -0
- GM_Visual/docs/core/project_manager.md +613 -0
- GM_Visual/docs/import_context_solution.md +272 -0
- GM_Visual/docs/logging_system.md +254 -0
- GM_Visual/docs/node_creation_guide_for_ai.md +1194 -0
- GM_Visual/docs/nodes/data/core/file_pointer.md +249 -0
- GM_Visual/docs/nodes/data/core/folder_pointer.md +321 -0
- GM_Visual/docs/nodes/demo/basic/fake_node.md +141 -0
- GM_Visual/docs/nodes/demo/math/constant_int.md +36 -0
- GM_Visual/docs/nodes/demo/math/int_display.md +38 -0
- GM_Visual/docs/nodes/demo/math/sum_demo.md +39 -0
- GM_Visual/docs/nodes/signals/creation/time_series_generator.md +204 -0
- GM_Visual/docs/nodes/signals/display/dftb_display.md +270 -0
- GM_Visual/docs/nodes/signals/display/dftm_display.md +235 -0
- GM_Visual/docs/nodes/signals/display/metadata_display.md +324 -0
- GM_Visual/docs/nodes/signals/dsp/filter_butterworth.md +405 -0
- GM_Visual/docs/nodes/signals/dsp/frequency_spectrum.md +322 -0
- GM_Visual/docs/nodes/signals/input/signal_load.md +387 -0
- GM_Visual/docs/nodes/utils/annotations/picture_node.md +198 -0
- GM_Visual/docs/nodes/utils/annotations/sticky_node.md +255 -0
- GM_Visual/docs/templates/node_documentation_template.md +28 -0
- GM_Visual/docs/workflow_execution_logic.md +1639 -0
- GM_Visual/examples/basics/example_basic_constant_and_list_creation_and_display.gmv +356 -0
- GM_Visual/examples/manual_test_execution_engine.py +258 -0
- GM_Visual/examples/signals/example_convert_timeseries_to_table_and_plot.gmv +115 -0
- GM_Visual/examples/signals/example_timeseries_creation_and_plot.gmv +219 -0
- GM_Visual/help/README.txt +34 -0
- GM_Visual/help/assets/css/style.css +308 -0
- GM_Visual/help/index.html +83 -0
- GM_Visual/help/topics/00-about-gearmaster-visual.html +95 -0
- GM_Visual/help/topics/01-getting-started.html +46 -0
- GM_Visual/help/topics/02-installation.html +86 -0
- GM_Visual/help/topics/03-canvas-basics.html +131 -0
- GM_Visual/help/topics/04-working-with-nodes.html +88 -0
- GM_Visual/help/topics/05-connecting-nodes.html +112 -0
- GM_Visual/help/topics/06-execution.html +109 -0
- GM_Visual/help/topics/07-node-states.html +154 -0
- GM_Visual/help/topics/08-pins-io.html +214 -0
- GM_Visual/help/topics/09-custom-nodes.html +195 -0
- GM_Visual/install.py +268 -0
- GM_Visual/main.py +1271 -0
- GM_Visual/requirements.txt +20 -0
- GM_Visual/src/__init__.py +24 -0
- GM_Visual/src/canvas/__init__.py +50 -0
- GM_Visual/src/canvas/canvas_connections.py +536 -0
- GM_Visual/src/canvas/canvas_events.py +1844 -0
- GM_Visual/src/canvas/canvas_execution.py +189 -0
- GM_Visual/src/canvas/canvas_navigation.py +358 -0
- GM_Visual/src/canvas/canvas_node.py +1547 -0
- GM_Visual/src/canvas/canvas_terminal.py +596 -0
- GM_Visual/src/canvas/canvas_ui.py +1133 -0
- GM_Visual/src/core/__init__.py +51 -0
- GM_Visual/src/core/config_manager.py +511 -0
- GM_Visual/src/core/execution_engine.py +706 -0
- GM_Visual/src/core/help_server.py +197 -0
- GM_Visual/src/core/installation_manager.py +527 -0
- GM_Visual/src/core/node_base.py +570 -0
- GM_Visual/src/core/pin_system.py +302 -0
- GM_Visual/src/core/project_manager.py +815 -0
- GM_Visual/src/main_canvas.py +567 -0
- GM_Visual/src/nodes/__init__.py +24 -0
- GM_Visual/src/nodes/basics/__init__.py +19 -0
- GM_Visual/src/nodes/basics/creation/__init__.py +19 -0
- GM_Visual/src/nodes/basics/creation/constant.py +302 -0
- GM_Visual/src/nodes/basics/creation/constant_gui.py +262 -0
- GM_Visual/src/nodes/basics/creation/list.py +278 -0
- GM_Visual/src/nodes/basics/creation/list_gui.py +359 -0
- GM_Visual/src/nodes/basics/display/__init__.py +11 -0
- GM_Visual/src/nodes/basics/display/value_display.py +244 -0
- GM_Visual/src/nodes/basics/display/value_display_gui.py +54 -0
- GM_Visual/src/nodes/data/__init__.py +12 -0
- GM_Visual/src/nodes/data/core/__init__.py +10 -0
- GM_Visual/src/nodes/data/core/file_pointer_node.py +370 -0
- GM_Visual/src/nodes/data/core/folder_pointer_node.py +375 -0
- GM_Visual/src/nodes/demo/__init__.py +18 -0
- GM_Visual/src/nodes/demo/basic/__init__.py +23 -0
- GM_Visual/src/nodes/demo/basic/fake_node.py +328 -0
- GM_Visual/src/nodes/demo/basic/fake_node_gui.py +647 -0
- GM_Visual/src/nodes/demo/math/__init__.py +14 -0
- GM_Visual/src/nodes/fea/__init__.py +28 -0
- GM_Visual/src/nodes/fea/welded_joints/__init__.py +11 -0
- GM_Visual/src/nodes/fea/welded_joints/mesh_weldpath_finder_shell.py +302 -0
- GM_Visual/src/nodes/fea/welded_joints/mesh_weldpath_finder_shell_gui.py +237 -0
- GM_Visual/src/nodes/fea/welded_joints/welded_joint_analysis_shell.py +391 -0
- GM_Visual/src/nodes/fea/welded_joints/welded_joint_analysis_shell_gui.py +268 -0
- GM_Visual/src/nodes/gui/__init__.py +24 -0
- GM_Visual/src/nodes/gui/base_node_gui.py +168 -0
- GM_Visual/src/nodes/materials/library/__init__.py +22 -0
- GM_Visual/src/nodes/materials/library/material_library.py +283 -0
- GM_Visual/src/nodes/materials/library/material_library_gui.py +461 -0
- GM_Visual/src/nodes/pyansys_dpf/__init__.py +36 -0
- GM_Visual/src/nodes/pyansys_dpf/basic/__init__.py +22 -0
- GM_Visual/src/nodes/pyansys_dpf/basic/ansys_dpf_model.py +326 -0
- GM_Visual/src/nodes/pyansys_dpf/basic/ansys_dpf_plotter.py +267 -0
- GM_Visual/src/nodes/pyansys_dpf/basic/ansys_dpf_plotter_gui.py +456 -0
- GM_Visual/src/nodes/pyansys_dpf/math/scale.py +278 -0
- GM_Visual/src/nodes/pyansys_dpf/math/scale_gui.py +234 -0
- GM_Visual/src/nodes/pyansys_dpf/results/ansys_dpf_results_stress.py +291 -0
- GM_Visual/src/nodes/pyansys_dpf/results/ansys_dpf_results_stress_gui.py +216 -0
- GM_Visual/src/nodes/pyansys_dpf/scoping/__init__.py +19 -0
- GM_Visual/src/nodes/pyansys_dpf/scoping/ansys_dpf_on_named_selection.py +279 -0
- GM_Visual/src/nodes/pyansys_dpf/scoping/ansys_dpf_on_named_selection_gui.py +358 -0
- GM_Visual/src/nodes/pyansys_dpf/scoping/ansys_dpf_time_freq_scoping.py +238 -0
- GM_Visual/src/nodes/pyansys_dpf/scoping/ansys_dpf_time_freq_scoping_gui.py +205 -0
- GM_Visual/src/nodes/pyansys_dpf/serialization/__init__.py +27 -0
- GM_Visual/src/nodes/pyansys_dpf/serialization/ansys_dpf_csv_to_field.py +197 -0
- GM_Visual/src/nodes/pyansys_dpf/serialization/ansys_dpf_field_to_csv.py +346 -0
- GM_Visual/src/nodes/pyansys_dpf/serialization/ansys_dpf_field_to_csv_gui.py +162 -0
- GM_Visual/src/nodes/signals/__init__.py +26 -0
- GM_Visual/src/nodes/signals/combination_node.py +183 -0
- GM_Visual/src/nodes/signals/creation/__init__.py +19 -0
- GM_Visual/src/nodes/signals/creation/time_series_generator.py +674 -0
- GM_Visual/src/nodes/signals/creation/time_series_generator_gui.py +707 -0
- GM_Visual/src/nodes/signals/display/__init__.py +22 -0
- GM_Visual/src/nodes/signals/display/dftb_display.py +215 -0
- GM_Visual/src/nodes/signals/display/dftm_display.py +174 -0
- GM_Visual/src/nodes/signals/display/metadata_display.py +192 -0
- GM_Visual/src/nodes/signals/dsp/__init__.py +25 -0
- GM_Visual/src/nodes/signals/dsp/dftm_statistics_advanced.py +419 -0
- GM_Visual/src/nodes/signals/dsp/dftm_statistics_advanced_gui.py +254 -0
- GM_Visual/src/nodes/signals/dsp/filter_butterworth.py +273 -0
- GM_Visual/src/nodes/signals/dsp/filter_butterworth_gui.py +335 -0
- GM_Visual/src/nodes/signals/dsp/frequency_spectrum.py +333 -0
- GM_Visual/src/nodes/signals/dsp/frequency_spectrum_gui.py +361 -0
- GM_Visual/src/nodes/signals/input/__init__.py +13 -0
- GM_Visual/src/nodes/signals/input/ncode_csv_ts_load_node.py +214 -0
- GM_Visual/src/nodes/signals/input/signal_load.py +481 -0
- GM_Visual/src/nodes/signals/input/signal_load_gui.py +247 -0
- GM_Visual/src/nodes/signals/output/__init__.py +18 -0
- GM_Visual/src/nodes/signals/output/signal_save.py +326 -0
- GM_Visual/src/nodes/signals/output/signal_save_gui.py +202 -0
- GM_Visual/src/nodes/signals/utils/__init__.py +18 -0
- GM_Visual/src/nodes/signals/utils/dataframe_combination.py +295 -0
- GM_Visual/src/nodes/signals/utils/dataframe_combination_gui.py +263 -0
- GM_Visual/src/nodes/signals/utils/dataframe_split.py +348 -0
- GM_Visual/src/nodes/signals/utils/dataframe_split_gui.py +238 -0
- GM_Visual/src/nodes/signals/utils/timeseries_to_table.py +267 -0
- GM_Visual/src/nodes/utils/__init__.py +29 -0
- GM_Visual/src/nodes/utils/annotations/__init__.py +20 -0
- GM_Visual/src/nodes/utils/annotations/picture_node.py +470 -0
- GM_Visual/src/nodes/utils/annotations/sticky_node.py +222 -0
- GM_Visual/src/nodes/utils/annotations/sticky_node_gui.py +274 -0
- GM_Visual/src/nodes_assets/icons/_placeholder.png +0 -0
- GM_Visual/src/nodes_assets/icons/icon_time_series_generator.png +0 -0
- GM_Visual/src/pin_connection.py +52 -0
- GM_Visual/src/settings/__init__.py +26 -0
- GM_Visual/src/settings/custom_settings.py +172 -0
- GM_Visual/src/settings/custom_settings_gui.py +483 -0
- GM_Visual/src/ui/about_dialog.py +131 -0
- GM_Visual/src/ui/documentation_panel.py +254 -0
- GM_Visual/src/ui/html_documentation_viewer.py +383 -0
- GM_Visual/src/ui/node_info_dialog.py +301 -0
- GM_Visual/src/utils/__init__.py +26 -0
- GM_Visual/src/utils/gm_logger.py +213 -0
- GM_Visual/src/utils/import_context.py +86 -0
- GM_Visual/src/utils/path_validator.py +243 -0
- GM_Visual/src/version.py +38 -0
- GM_Visual/tests/__init__.py +22 -0
- GM_Visual/tests/debug_cascade_graph.py +125 -0
- GM_Visual/tests/debug_on_property_changed.py +82 -0
- GM_Visual/tests/test_cascade_dirty_propagation.py +319 -0
- GM_Visual/tests/test_core/conftest.py +23 -0
- GM_Visual/tests/test_core/diagnostic_execution.py +185 -0
- GM_Visual/tests/test_core/test_canvas_cascade.py +163 -0
- GM_Visual/tests/test_core/test_canvas_execution.py +93 -0
- GM_Visual/tests/test_core/test_cascade_execution.py +207 -0
- GM_Visual/tests/test_core/test_complete_system.py +172 -0
- GM_Visual/tests/test_core/test_core_basic.py +129 -0
- GM_Visual/tests/test_core/test_executed_state.py +377 -0
- GM_Visual/tests/test_core/test_execution_dependencies.py +182 -0
- GM_Visual/tests/test_core/test_execution_logic.py +123 -0
- GM_Visual/tests/test_core/test_node_addition.py +107 -0
- GM_Visual/tests/test_core/test_property_pin_dynamic.py +191 -0
- GM_Visual/tests/test_fake_node.py +112 -0
- GM_Visual/tests/test_nodes/test_ansys_dpf_plotter.py +103 -0
- GM_Visual/tests/test_nodes/test_ansys_dpf_results_stress.py +367 -0
- GM_Visual/tests/test_nodes/test_constant_node.py +375 -0
- GM_Visual/tests/test_nodes/test_demo_nodes.py +98 -0
- GM_Visual/tests/test_nodes/test_file_pointer_node.py +231 -0
- GM_Visual/tests/test_nodes/test_folder_pointer_node.py +207 -0
- GM_Visual/tests/test_nodes/test_list_node.py +225 -0
- GM_Visual/tests/test_nodes/test_scale_node.py +368 -0
- GM_Visual/tests/test_nodes/test_value_display_node.py +284 -0
- GM_modules/Cad/__init__.py +25 -0
- GM_modules/Data/GM_DataManager.py +1860 -0
- GM_modules/Data/__init__.py +23 -0
- GM_modules/Data/test/__init__.py +11 -0
- GM_modules/Data/test/__tester_GM_DataManager.py +17 -0
- GM_modules/Data/test/_test_MC_load_ncode_csv.py +50 -0
- GM_modules/Data/test/_test_gmdm_mc.py +17 -0
- GM_modules/Data/test/source_MC_load_ncode_csv.csv +217360 -0
- GM_modules/Data/test/source_ncode_TS_to_CSV_2022.csv +1046 -0
- GM_modules/Data/test/test_gmdm_db.py +192 -0
- GM_modules/Data/test/test_gmdm_ds.py +159 -0
- GM_modules/Data/test/test_gmdm_mc.py +30 -0
- GM_modules/Data/test/test_gmdm_md.py +39 -0
- GM_modules/Data/utils.py +166 -0
- GM_modules/Fea/__init__.py +28 -0
- GM_modules/Fea/core.py +310 -0
- GM_modules/Fea/docs/DOC_MeshEnergyComponents.md +631 -0
- GM_modules/Fea/mesh_energy_components.py +2048 -0
- GM_modules/Fea/mesh_welded_joint.py +1280 -0
- GM_modules/Fea/mesh_weldpath_finder.py +1797 -0
- GM_modules/Fea/test_/README_test_usage.md +62 -0
- GM_modules/Fea/test_/__init__.py +11 -0
- GM_modules/Fea/test_/_test_vtk_visualization.py +83 -0
- GM_modules/Fea/test_/_test_weldpath_finder_shell.rst +0 -0
- GM_modules/Fea/test_/_test_weldpath_finder_shell_15000.rst +0 -0
- GM_modules/Fea/test_/_test_weldpath_finder_shell_4000.rst +0 -0
- GM_modules/Fea/test_/_test_weldpath_finder_shell_complexity2.rst +0 -0
- GM_modules/Fea/test_/_test_weldpath_finder_shell_complexity3.rst +0 -0
- GM_modules/Fea/test_/demo_weldpath_shell_NS_001.rst +0 -0
- GM_modules/Fea/test_/demo_weldpath_shell_NS_001_ENFO.txt +14148 -0
- GM_modules/Fea/test_/demo_weldpath_shell_NS_001_ENMO.txt +14148 -0
- GM_modules/Fea/test_/pytest.ini +42 -0
- GM_modules/Fea/test_/run_tests.py +208 -0
- GM_modules/Fea/test_/source_circular_tube_NS.rst +0 -0
- GM_modules/Fea/test_/test_gm_ansy_dpf.py +62 -0
- GM_modules/Fea/test_/test_group_subgroup.rst +0 -0
- GM_modules/Fea/test_/test_mesh_energy_components.py +152 -0
- GM_modules/Fea/test_/test_meshenergycomponents_basic00.py +182 -0
- GM_modules/Fea/test_/test_meshenergycomponents_basic01.py +114 -0
- GM_modules/Fea/test_/test_meshenergycomponents_basic02.py +120 -0
- GM_modules/Fea/test_/test_meshenergycomponents_weldpath_00.py +120 -0
- GM_modules/Fea/test_/test_welded_joint.py +76 -0
- GM_modules/Fea/test_/test_weldpath_finder_shell.py +105 -0
- GM_modules/Fea/test_/test_weldpath_from_NS.py +47 -0
- GM_modules/Fea/test_/test_weldpath_shell_NS.rst +0 -0
- GM_modules/GUIs/GM_GUIManager.py +114 -0
- GM_modules/GUIs/GM_GUI_core.py +99 -0
- GM_modules/GUIs/N_Hcyl_GUI.py +253 -0
- GM_modules/GUIs/__init__.py +23 -0
- GM_modules/Hydraulic/Hydraulic.py +18 -0
- GM_modules/Hydraulic/__init__.py +26 -0
- GM_modules/Materials/__init__.py +23 -0
- GM_modules/Materials/material_library.py +116 -0
- GM_modules/Materials/materials.py +243 -0
- GM_modules/Materials/test/test_material.py +324 -0
- GM_modules/Materials/test/test_material_library.py +371 -0
- GM_modules/Mechanical/Fasteners.py +197 -0
- GM_modules/Mechanical/__init__.py +26 -0
- GM_modules/Meshless/__init__.py +24 -0
- GM_modules/Signals/__init__.py +27 -0
- GM_modules/Signals/docs/README.md +29 -0
- GM_modules/Signals/docs/apps/creation/time_series_generator.md +393 -0
- GM_modules/Signals/docs/apps/display/METADATA_DISPLAY_GUIDE.md +297 -0
- GM_modules/Signals/docs/apps/dsp/ButterworthFilter.md +219 -0
- GM_modules/Signals/docs/apps/dsp/frequency_spectrum.md +313 -0
- GM_modules/Signals/docs/apps/input/dftm_load_system.md +595 -0
- GM_modules/Signals/docs/apps/output/dftm_save_system.md +298 -0
- GM_modules/Signals/docs/apps/utils/dataframe_combination.md +211 -0
- GM_modules/Signals/docs/core/dataframe_table.md +620 -0
- GM_modules/Signals/docs/core/dataframe_time.md +440 -0
- GM_modules/Signals/docs/core/dataseries_time.md +364 -0
- GM_modules/Signals/docs/core/dataset_table.md +552 -0
- GM_modules/Signals/docs/core/format_table.md +229 -0
- GM_modules/Signals/docs/core/format_timeseries.md +224 -0
- GM_modules/Signals/docs/core/formats.md +119 -0
- GM_modules/Signals/docs/core/gm_data_types_for_ai.md +195 -0
- GM_modules/Signals/docs/source_metadata_guide.md +347 -0
- GM_modules/Signals/examples/dataframe_combination_example.py +199 -0
- GM_modules/Signals/examples/demo_dftm_advanced_statistics.py +214 -0
- GM_modules/Signals/examples/demo_filter_butterworth.py +286 -0
- GM_modules/Signals/examples/demo_frequency_spectrum.py +205 -0
- GM_modules/Signals/examples/demo_metadata_display.py +312 -0
- GM_modules/Signals/examples/demo_metadata_display_from_ts_generator.py +149 -0
- GM_modules/Signals/examples/demo_source_metadata.py +178 -0
- GM_modules/Signals/examples/demo_timeseries_to_table.py +218 -0
- GM_modules/Signals/requirements_signals.txt +14 -0
- GM_modules/Signals/src/__init__.py +12 -0
- GM_modules/Signals/src/apps/__init__.py +14 -0
- GM_modules/Signals/src/apps/creation/__init__.py +14 -0
- GM_modules/Signals/src/apps/creation/time_series_generator.py +407 -0
- GM_modules/Signals/src/apps/display/__init__.py +15 -0
- GM_modules/Signals/src/apps/display/dftb_display.py +505 -0
- GM_modules/Signals/src/apps/display/dftm_display.py +505 -0
- GM_modules/Signals/src/apps/display/metadata_display.py +463 -0
- GM_modules/Signals/src/apps/display/test_/test_dftm_display.py +569 -0
- GM_modules/Signals/src/apps/dsp/__init__.py +14 -0
- GM_modules/Signals/src/apps/dsp/dftm_statistics_advanced.py +172 -0
- GM_modules/Signals/src/apps/dsp/filter_butterworth.py +279 -0
- GM_modules/Signals/src/apps/dsp/frequency_spectrum.py +711 -0
- GM_modules/Signals/src/apps/dsp/test_/__init__.py +11 -0
- GM_modules/Signals/src/apps/dsp/test_/test_butterworth_filter.py +875 -0
- GM_modules/Signals/src/apps/dsp/test_/test_frequency_spectrum.py +423 -0
- GM_modules/Signals/src/apps/input/__init__.py +11 -0
- GM_modules/Signals/src/apps/input/dftb_load.py +632 -0
- GM_modules/Signals/src/apps/input/dftm_load.py +622 -0
- GM_modules/Signals/src/apps/input/ncode_csv_ts_load.py +276 -0
- GM_modules/Signals/src/apps/input/test_/source_ncode_csv_ts.csv +144008 -0
- GM_modules/Signals/src/apps/input/test_/test_dftb_load.py +479 -0
- GM_modules/Signals/src/apps/input/test_/test_dftm_load.py +461 -0
- GM_modules/Signals/src/apps/input/test_/test_ncode_csv_ts_load.py +277 -0
- GM_modules/Signals/src/apps/output/__init__.py +14 -0
- GM_modules/Signals/src/apps/output/dftb_out.py +360 -0
- GM_modules/Signals/src/apps/output/dftm_out.py +317 -0
- GM_modules/Signals/src/apps/output/test_/test_dftb_out.py +388 -0
- GM_modules/Signals/src/apps/output/test_/test_dftm_out.py +308 -0
- GM_modules/Signals/src/apps/utils/__init__.py +14 -0
- GM_modules/Signals/src/apps/utils/dataframe_combination.py +189 -0
- GM_modules/Signals/src/apps/utils/dataframe_split.py +364 -0
- GM_modules/Signals/src/apps/utils/test_/test_dataframe_split.py +234 -0
- GM_modules/Signals/src/apps/utils/timeseries_to_table.py +301 -0
- GM_modules/Signals/src/core/__init__.py +24 -0
- GM_modules/Signals/src/core/dataframe_table.py +285 -0
- GM_modules/Signals/src/core/dataframe_time.py +180 -0
- GM_modules/Signals/src/core/dataseries_time.py +150 -0
- GM_modules/Signals/src/core/dataset_table.py +244 -0
- GM_modules/Signals/src/core/metadata_dftb.py +53 -0
- GM_modules/Signals/src/core/metadata_dftm.py +38 -0
- GM_modules/Signals/src/core/metadata_dstb.py +92 -0
- GM_modules/Signals/src/core/metadata_dstm.py +94 -0
- GM_modules/Signals/src/core/metadata_source_info.py +156 -0
- GM_modules/Signals/tests/conftest.py +22 -0
- GM_modules/Signals/tests/test_converter_with_generator.py +266 -0
- GM_modules/Signals/tests/test_dataframe_combination.py +303 -0
- GM_modules/Signals/tests/test_debug_types.py +51 -0
- GM_modules/Signals/tests/test_dftb_creation-save-load.py +201 -0
- GM_modules/Signals/tests/test_dftm.py +308 -0
- GM_modules/Signals/tests/test_dftm_creation-save-load.py +154 -0
- GM_modules/Signals/tests/test_dftm_statistics_advanced.py +287 -0
- GM_modules/Signals/tests/test_dstm.py +117 -0
- GM_modules/Signals/tests/test_filter_butterworth.py +342 -0
- GM_modules/Signals/tests/test_generator_debug.py +49 -0
- GM_modules/Signals/tests/test_metadata_display_unified.py +629 -0
- GM_modules/Signals/tests/test_simple_converter.py +171 -0
- GM_modules/Signals/tests/test_time_series_generator.py +356 -0
- GM_modules/Signals/tests/test_timeseries_to_table.py +293 -0
- GM_modules/Structures/SWA_Core.py +558 -0
- GM_modules/Structures/SWA_Prep.py +348 -0
- GM_modules/Structures/SWA_pyAnsys.py +92 -0
- GM_modules/Structures/__init__.py +29 -0
- GM_modules/Structures/_cross_Sections_tester.py +18 -0
- GM_modules/Structures/_out/node_data_path.csv +46 -0
- GM_modules/Structures/_out/weldline_stresses.csv +7 -0
- GM_modules/Structures/core.py +77 -0
- GM_modules/Structures/cross_sections.py +193 -0
- GM_modules/Structures/json2asg.py +76 -0
- GM_modules/__init__.py +43 -0
- GM_modules/pyAnsys/DPF/GM_dpf_core.py +174 -0
- GM_modules/pyAnsys/DPF/gm_ansys_dpf.py +693 -0
- GM_modules/pyAnsys/DPF/test/ansys_dpf_core_vs_post_benchmark.py +148 -0
- GM_modules/pyAnsys/DPF/test/demo_simple_joint_shell.rst +0 -0
- GM_modules/pyAnsys/DPF/test/test_GmAnsysDPF_basics.py +59 -0
- GM_modules/pyAnsys/__init__.py +24 -0
- gearmaster-0.1.0.dist-info/METADATA +460 -0
- gearmaster-0.1.0.dist-info/RECORD +368 -0
- gearmaster-0.1.0.dist-info/WHEEL +5 -0
- gearmaster-0.1.0.dist-info/licenses/LICENSE +675 -0
- gearmaster-0.1.0.dist-info/top_level.txt +4 -0
- scripts/prepare_release.ps1 +145 -0
- standard/API.md +21 -0
- standard/CODE_STRUCTURE.md +222 -0
- standard/DOCUMENTATION.md +335 -0
- standard/FORMATTING.md +365 -0
- standard/NAMING_CONVENTIONS.md +232 -0
- standard/README.md +36 -0
- standard/TESTING.md +396 -0
- standard/VERSIONING.md +189 -0
|
@@ -0,0 +1,158 @@
|
|
|
1
|
+
# GM_Visual Installation Guide
|
|
2
|
+
|
|
3
|
+
## Quick Start
|
|
4
|
+
|
|
5
|
+
After cloning the repository, run the installation script:
|
|
6
|
+
|
|
7
|
+
```bash
|
|
8
|
+
cd GM_Visual
|
|
9
|
+
python install.py
|
|
10
|
+
```
|
|
11
|
+
|
|
12
|
+
This will:
|
|
13
|
+
- ✅ Create configuration directory in `%APPDATA%\GM_Visual`
|
|
14
|
+
- ✅ Create default configuration files
|
|
15
|
+
- ✅ Create desktop shortcut (optional)
|
|
16
|
+
- ✅ Create Start Menu shortcut (optional)
|
|
17
|
+
|
|
18
|
+
## Installation Commands
|
|
19
|
+
|
|
20
|
+
### Install
|
|
21
|
+
```bash
|
|
22
|
+
python install.py install
|
|
23
|
+
```
|
|
24
|
+
Installs GM_Visual with interactive prompts for shortcut creation.
|
|
25
|
+
|
|
26
|
+
### Verify Installation
|
|
27
|
+
```bash
|
|
28
|
+
python install.py verify
|
|
29
|
+
```
|
|
30
|
+
Checks if installation is valid and reports any issues.
|
|
31
|
+
|
|
32
|
+
### Repair Installation
|
|
33
|
+
```bash
|
|
34
|
+
python install.py repair
|
|
35
|
+
```
|
|
36
|
+
Fixes corrupted or missing configuration files.
|
|
37
|
+
|
|
38
|
+
### Show Installation Info
|
|
39
|
+
```bash
|
|
40
|
+
python install.py info
|
|
41
|
+
```
|
|
42
|
+
Displays current installation status and details.
|
|
43
|
+
|
|
44
|
+
### Uninstall
|
|
45
|
+
```bash
|
|
46
|
+
python install.py uninstall
|
|
47
|
+
```
|
|
48
|
+
Removes all configuration files and shortcuts.
|
|
49
|
+
|
|
50
|
+
## What Gets Installed?
|
|
51
|
+
|
|
52
|
+
### Configuration Directory
|
|
53
|
+
Location: `C:\Users\{username}\AppData\Roaming\GM_Visual\`
|
|
54
|
+
|
|
55
|
+
Files created:
|
|
56
|
+
- **config.json** - Application settings (theme, grid, auto-save)
|
|
57
|
+
- **recent_files.json** - Recently opened workflows
|
|
58
|
+
- **workspace.json** - Window position, last directory
|
|
59
|
+
- **logs/** - Application logs directory
|
|
60
|
+
|
|
61
|
+
### Shortcuts (Optional)
|
|
62
|
+
- Desktop shortcut: `GM Visual.lnk`
|
|
63
|
+
- Start Menu: `Programs\GM Visual\GM Visual.lnk`
|
|
64
|
+
|
|
65
|
+
## Auto-Installation
|
|
66
|
+
|
|
67
|
+
When you run `python main.py` for the first time without installation, GM_Visual will:
|
|
68
|
+
1. Detect missing installation
|
|
69
|
+
2. Prompt you to install
|
|
70
|
+
3. Create configuration directory
|
|
71
|
+
4. Continue launching
|
|
72
|
+
|
|
73
|
+
You can skip this prompt and run `python install.py` manually later.
|
|
74
|
+
|
|
75
|
+
## Requirements
|
|
76
|
+
|
|
77
|
+
### Python Packages
|
|
78
|
+
All listed in `requirements.txt` - install with:
|
|
79
|
+
```bash
|
|
80
|
+
pip install -r requirements.txt
|
|
81
|
+
```
|
|
82
|
+
|
|
83
|
+
### For Shortcuts (Windows only)
|
|
84
|
+
```bash
|
|
85
|
+
pip install pywin32
|
|
86
|
+
```
|
|
87
|
+
|
|
88
|
+
If `pywin32` is not installed, shortcuts will be skipped but the app will still work.
|
|
89
|
+
|
|
90
|
+
## Manual Configuration
|
|
91
|
+
|
|
92
|
+
If you prefer not to use the installer, you can manually create:
|
|
93
|
+
|
|
94
|
+
```
|
|
95
|
+
%APPDATA%\GM_Visual\
|
|
96
|
+
├── config.json
|
|
97
|
+
├── recent_files.json
|
|
98
|
+
├── workspace.json
|
|
99
|
+
└── logs\
|
|
100
|
+
```
|
|
101
|
+
|
|
102
|
+
Example `config.json`:
|
|
103
|
+
```json
|
|
104
|
+
{
|
|
105
|
+
"version": "1.0.0",
|
|
106
|
+
"theme": "dark",
|
|
107
|
+
"auto_save_interval": 300,
|
|
108
|
+
"grid_snap": true,
|
|
109
|
+
"grid_size": 20
|
|
110
|
+
}
|
|
111
|
+
```
|
|
112
|
+
|
|
113
|
+
## Troubleshooting
|
|
114
|
+
|
|
115
|
+
### "GM_Visual is not installed" Warning
|
|
116
|
+
Run: `python install.py install`
|
|
117
|
+
|
|
118
|
+
### Installation Corruption
|
|
119
|
+
Run: `python install.py repair`
|
|
120
|
+
|
|
121
|
+
### Shortcuts Not Created
|
|
122
|
+
Ensure `pywin32` is installed:
|
|
123
|
+
```bash
|
|
124
|
+
pip install pywin32
|
|
125
|
+
```
|
|
126
|
+
|
|
127
|
+
Then repair:
|
|
128
|
+
```bash
|
|
129
|
+
python install.py repair
|
|
130
|
+
```
|
|
131
|
+
|
|
132
|
+
### Permission Errors
|
|
133
|
+
The installer only writes to `%APPDATA%`, which doesn't require admin privileges.
|
|
134
|
+
If you get permission errors, check your user account permissions.
|
|
135
|
+
|
|
136
|
+
## Uninstallation
|
|
137
|
+
|
|
138
|
+
To completely remove GM_Visual:
|
|
139
|
+
|
|
140
|
+
1. Uninstall via script (removes config + shortcuts):
|
|
141
|
+
```bash
|
|
142
|
+
python install.py uninstall
|
|
143
|
+
```
|
|
144
|
+
|
|
145
|
+
2. Delete the repository folder:
|
|
146
|
+
```bash
|
|
147
|
+
rmdir /s GM_Visual
|
|
148
|
+
```
|
|
149
|
+
|
|
150
|
+
## Distribution
|
|
151
|
+
|
|
152
|
+
When distributing GM_Visual to other users:
|
|
153
|
+
|
|
154
|
+
1. **Include install.py** in the repository
|
|
155
|
+
2. Instruct users to run `python install.py` after clone
|
|
156
|
+
3. Alternatively, they can just run `python main.py` and accept the auto-install prompt
|
|
157
|
+
|
|
158
|
+
The installation is user-specific and doesn't require administrator privileges.
|
GM_Visual/__init__.py
ADDED
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
"""
|
|
2
|
+
GM_Visual - Visual Programming System for GearMaster
|
|
3
|
+
|
|
4
|
+
A node-based visual programming interface for visual engineering workflows.
|
|
5
|
+
Provides drag-and-drop node canvas, project management, and integration with
|
|
6
|
+
GM_modules for signal processing, CAD operations, and simulation workflows.
|
|
7
|
+
|
|
8
|
+
Key Components:
|
|
9
|
+
- Canvas: Node-based visual programming interface
|
|
10
|
+
- Nodes: Computational nodes providing various functionalities
|
|
11
|
+
- Core: Engine and execution system
|
|
12
|
+
- Settings: User preferences and configuration management
|
|
13
|
+
- Utils: Shared utilities and helpers
|
|
14
|
+
|
|
15
|
+
Dependencies:
|
|
16
|
+
Internal:
|
|
17
|
+
- GearMaster.GM_modules (All modules integrated as nodes)
|
|
18
|
+
External:
|
|
19
|
+
- customtkinter (Modern GUI framework)
|
|
20
|
+
- tkinter (Standard Python GUI)
|
|
21
|
+
- Pillow (Image processing)
|
|
22
|
+
|
|
23
|
+
Author: Simone Lucertini
|
|
24
|
+
"""
|
|
25
|
+
|
|
26
|
+
from importlib.metadata import version, PackageNotFoundError
|
|
27
|
+
|
|
28
|
+
try:
|
|
29
|
+
__version__ = version("gearmaster")
|
|
30
|
+
except PackageNotFoundError:
|
|
31
|
+
__version__ = "0.0.0+unknown"
|
|
32
|
+
|
|
33
|
+
__author__ = "Simone Lucertini"
|
|
34
|
+
|
|
35
|
+
# Main API exports will be added here
|
GM_Visual/core.py
ADDED
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
"""
|
|
2
|
+
Core module for GM_Visual
|
|
3
|
+
Centralizes all core imports for the visual programming system.
|
|
4
|
+
|
|
5
|
+
Dependencies:
|
|
6
|
+
Internal: See module imports
|
|
7
|
+
External: See requirements and imports
|
|
8
|
+
|
|
9
|
+
Author: Simone Lucertini
|
|
10
|
+
Last Update: 2026-02-06
|
|
11
|
+
"""
|
|
12
|
+
|
|
13
|
+
# Import the base node architecture
|
|
14
|
+
from src.core.node_base import NodeBase, NodeState
|
|
15
|
+
from src.core.pin_system import Pin, PinType, PinDirection
|
|
16
|
+
|
|
17
|
+
# Import the execution engine (versione completa)
|
|
18
|
+
from src.core.execution_engine import ExecutionEngine
|
|
19
|
+
|
|
20
|
+
# Import connection management
|
|
21
|
+
from src.pin_connection import PinConnection
|
|
22
|
+
|
|
23
|
+
# Re-export everything for convenience
|
|
24
|
+
__all__ = [
|
|
25
|
+
'NodeBase',
|
|
26
|
+
'Pin',
|
|
27
|
+
'PinType',
|
|
28
|
+
'PinDirection',
|
|
29
|
+
'NodeState',
|
|
30
|
+
'ExecutionEngine',
|
|
31
|
+
'PinConnection'
|
|
32
|
+
]
|
GM_Visual/docs/README.md
ADDED
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
# GM_Visual - Visual Programming System
|
|
2
|
+
|
|
3
|
+
A node-based visual programming interface for the GearMaster ecosystem, enabling intuitive workflow creation for signal processing, analysis, and simulation tasks.
|
|
4
|
+
|
|
5
|
+
## Overview
|
|
6
|
+
|
|
7
|
+
GM_Visual provides a drag-and-drop interface for creating complex workflows using nodes that represent operations from the GearMaster library ecosystem. Built with CustomTkinter for a modern, responsive user interface.
|
|
8
|
+
|
|
9
|
+
## Features
|
|
10
|
+
|
|
11
|
+
- **Node-based Workflow**: Drag-and-drop interface for creating processing pipelines
|
|
12
|
+
- **Type Safety**: Automatic validation of node connections
|
|
13
|
+
- **Real-time Execution**: Interactive execution with dependency resolution
|
|
14
|
+
- **Modular Design**: Extensible architecture for adding new node types
|
|
15
|
+
- **Visual Feedback**: Clear indication of node states (dirty/clean/error/processing)
|
|
16
|
+
|
|
17
|
+
## Architecture
|
|
18
|
+
|
|
19
|
+
```
|
|
20
|
+
GM_Visual/
|
|
21
|
+
├── src/core/ # Core engine (nodes, pins, execution)
|
|
22
|
+
├── src/nodes/ # Node implementations by module
|
|
23
|
+
│ ├── signals/ # Signal processing nodes
|
|
24
|
+
│ └── utils/ # Utility nodes
|
|
25
|
+
├── docs/ # Documentation
|
|
26
|
+
├── tests/ # Unit tests
|
|
27
|
+
└── examples/ # Example workflows
|
|
28
|
+
```
|
|
29
|
+
|
|
30
|
+
## Quick Start
|
|
31
|
+
|
|
32
|
+
*(Documentation will be expanded as development progresses)*
|
|
33
|
+
|
|
34
|
+
## Node Categories
|
|
35
|
+
|
|
36
|
+
### Signals Module
|
|
37
|
+
- **Creation**: Time series generators, synthetic signals
|
|
38
|
+
- **DSP**: Filters, frequency analysis, transformations
|
|
39
|
+
- **Display**: Visualization, metadata display
|
|
40
|
+
- **Input**: Data loading and import
|
|
41
|
+
|
|
42
|
+
### Utilities
|
|
43
|
+
- **Combination**: Data merging and manipulation
|
|
44
|
+
- **Math**: Mathematical operations
|
|
45
|
+
- **I/O**: File operations
|
|
46
|
+
|
|
47
|
+
## Development Status
|
|
48
|
+
|
|
49
|
+
🚧 **In Development** - Initial implementation phase
|
|
50
|
+
|
|
51
|
+
## Requirements
|
|
52
|
+
|
|
53
|
+
See `requirements.txt` for full dependency list.
|
|
54
|
+
|
|
55
|
+
## License
|
|
56
|
+
|
|
57
|
+
Part of the GearMaster project.
|
GM_Visual/docs/canvas.md
ADDED
|
@@ -0,0 +1,210 @@
|
|
|
1
|
+
# GM_Visual Canvas System Documentation
|
|
2
|
+
|
|
3
|
+
## Overview
|
|
4
|
+
|
|
5
|
+
The `canvas.py` file implements the main canvas system for the GM_Visual visual programming interface. It provides a comprehensive drag-and-drop canvas with zoom, pan, and connection capabilities for building node-based workflows.
|
|
6
|
+
|
|
7
|
+
## Key Features
|
|
8
|
+
|
|
9
|
+
- **Visual Node Management**: Handles creation, positioning, and interaction with visual nodes
|
|
10
|
+
- **Connection System**: Manages pin-to-pin connections between nodes with curved Bézier lines
|
|
11
|
+
- **Zoom and Pan**: Full canvas navigation with mouse wheel and keyboard shortcuts
|
|
12
|
+
- **Context Menus**: Right-click menus for nodes, pins, and canvas operations
|
|
13
|
+
- **Execution Engine Integration**: Connects visual interface with the underlying execution engine
|
|
14
|
+
- **Terminal Integration**: Built-in terminal for debugging and command execution
|
|
15
|
+
- **Node Library**: Dynamic loading and display of available node types
|
|
16
|
+
|
|
17
|
+
## Architecture
|
|
18
|
+
|
|
19
|
+
### Core Classes
|
|
20
|
+
|
|
21
|
+
#### ExecutionState
|
|
22
|
+
Defines the execution states for nodes:
|
|
23
|
+
- `NEEDS_EXECUTION`: Node is dirty and needs execution (Orange)
|
|
24
|
+
- `RUNNING`: Node is currently executing (Gold/Yellow with spinner)
|
|
25
|
+
- `SUCCESS`: Node executed successfully (Green)
|
|
26
|
+
- `ERROR`: Node execution failed (Red)
|
|
27
|
+
- `DISABLED`: Node cannot execute due to missing required inputs (Gray)
|
|
28
|
+
|
|
29
|
+
#### ExecutionColors
|
|
30
|
+
Color mappings for execution states, providing visual feedback for node status.
|
|
31
|
+
|
|
32
|
+
#### DebugOutputCapture
|
|
33
|
+
Custom output capture system that redirects debug messages to the terminal with color coding.
|
|
34
|
+
|
|
35
|
+
#### CanvasNode
|
|
36
|
+
Represents a visual node on the canvas with the following responsibilities:
|
|
37
|
+
- Visual rendering of node background, title, pins, and execution button
|
|
38
|
+
- Pin interaction and connection management
|
|
39
|
+
- Execution state visualization and animation
|
|
40
|
+
- Value display for nodes with dynamic output
|
|
41
|
+
|
|
42
|
+
#### NodeCanvas
|
|
43
|
+
Main canvas class that manages the entire visual programming interface:
|
|
44
|
+
- Canvas widget management and event handling
|
|
45
|
+
- Node and connection lifecycle management
|
|
46
|
+
- Zoom, pan, and navigation controls
|
|
47
|
+
- Context menu system
|
|
48
|
+
- Terminal integration
|
|
49
|
+
- Node library interface
|
|
50
|
+
|
|
51
|
+
## Key Methods
|
|
52
|
+
|
|
53
|
+
### NodeCanvas Class
|
|
54
|
+
|
|
55
|
+
#### Initialization and Setup
|
|
56
|
+
- `__init__(parent, app=None)`: Initializes the canvas with all UI components, accepting a parent widget and optional reference to main application
|
|
57
|
+
- `_create_ui()`: Creates the main UI layout with canvas, panels, and terminal
|
|
58
|
+
- `_setup_bindings()`: Configures mouse and keyboard event bindings
|
|
59
|
+
- `_setup_tab_contents()`: Initializes the node library interface
|
|
60
|
+
|
|
61
|
+
#### Node Management
|
|
62
|
+
- `add_node_to_canvas()`: Adds a new node to the canvas at specified coordinates
|
|
63
|
+
- `_remove_node_visual_elements()`: Removes all visual elements of a node
|
|
64
|
+
- `update_node_pins()`: Updates pin visualization when node configuration changes
|
|
65
|
+
|
|
66
|
+
#### Connection System
|
|
67
|
+
- `create_connection()`: Creates a visual connection between two node pins
|
|
68
|
+
- `clear_connections()`: Removes all connection lines from the canvas
|
|
69
|
+
- `update_node_connections()`: Updates connection positions when nodes move
|
|
70
|
+
- `update_all_connections()`: Refreshes all connection visualizations
|
|
71
|
+
|
|
72
|
+
#### Event Handling
|
|
73
|
+
- `on_left_click()`, `on_left_drag()`, `on_left_release()`: Handle node selection and dragging
|
|
74
|
+
- `on_right_click()`: Display context menus for nodes, pins, and canvas
|
|
75
|
+
- `on_mouse_wheel()`: Handle zoom operations
|
|
76
|
+
- `on_middle_click()`, `on_middle_drag()`, `on_middle_release()`: Handle panning
|
|
77
|
+
|
|
78
|
+
#### Canvas Operations
|
|
79
|
+
- `clear_canvas()`: Safely removes all nodes and connections from the canvas by first disconnecting each node individually, then clearing visual elements and forcing canvas update
|
|
80
|
+
- `canvas_to_world()`, `world_to_canvas()`: Coordinate system conversions
|
|
81
|
+
- `update_status()`: Updates the status bar message
|
|
82
|
+
|
|
83
|
+
#### Terminal Integration
|
|
84
|
+
- `append_to_terminal()`: Adds messages to the integrated terminal
|
|
85
|
+
- `execute_terminal_command()`: Processes terminal commands
|
|
86
|
+
- `_create_terminal_ui()`: Sets up the terminal interface
|
|
87
|
+
|
|
88
|
+
### CanvasNode Class
|
|
89
|
+
|
|
90
|
+
#### Visual Rendering
|
|
91
|
+
- `_create_visual_elements()`: Creates all visual components of the node
|
|
92
|
+
- `update_visual()`: Updates node appearance based on state changes
|
|
93
|
+
- `update_value_display()`: Shows dynamic values for certain node types
|
|
94
|
+
|
|
95
|
+
#### Interaction
|
|
96
|
+
- `contains_point()`: Checks if a coordinate is within the node bounds
|
|
97
|
+
- `get_pin_position()`: Returns the screen position of a specific pin
|
|
98
|
+
- `get_pin_at_point()`: Identifies which pin is at a given coordinate
|
|
99
|
+
|
|
100
|
+
#### Execution
|
|
101
|
+
- `update_execution_state()`: Changes the visual execution state
|
|
102
|
+
- `_start_spinner_animation()`, `_stop_spinner_animation()`: Manages execution animation
|
|
103
|
+
- `has_all_required_pins_connected()`: Validates execution prerequisites
|
|
104
|
+
|
|
105
|
+
## Connection System
|
|
106
|
+
|
|
107
|
+
The connection system uses a dual-structure approach:
|
|
108
|
+
|
|
109
|
+
1. **Visual Connections** (`visual_connections`): Store visual connection information including line IDs, node references, and pin names
|
|
110
|
+
2. **Legacy Connections** (`connections`): Maintain backward compatibility with older connection structures
|
|
111
|
+
|
|
112
|
+
Connections are rendered as curved Bézier lines with color coding based on pin types. The system supports:
|
|
113
|
+
- Dynamic connection creation during drag operations
|
|
114
|
+
- Automatic connection updates when nodes move
|
|
115
|
+
- Context menu disconnection options
|
|
116
|
+
- Visual feedback during connection creation
|
|
117
|
+
|
|
118
|
+
## Node Library System
|
|
119
|
+
|
|
120
|
+
The right panel contains a dynamic node library with:
|
|
121
|
+
- Category-based organization (Signals, Utils, Demo, etc.)
|
|
122
|
+
- Subcategory browsing
|
|
123
|
+
- Drag-and-drop node creation
|
|
124
|
+
- Search functionality (planned for future implementation)
|
|
125
|
+
|
|
126
|
+
## Terminal System
|
|
127
|
+
|
|
128
|
+
Integrated terminal provides:
|
|
129
|
+
- Command execution with output capture
|
|
130
|
+
- Debug mode toggle for controlling message visibility
|
|
131
|
+
- Command history navigation
|
|
132
|
+
- Color-coded output (info, warning, error, system messages)
|
|
133
|
+
|
|
134
|
+
## Zoom and Navigation
|
|
135
|
+
|
|
136
|
+
Supports multiple zoom methods:
|
|
137
|
+
- Mouse wheel zooming centered on cursor
|
|
138
|
+
- Keyboard shortcuts (Ctrl+0 for fit all, Ctrl+1 for reset)
|
|
139
|
+
- Zoom box selection (planned)
|
|
140
|
+
- Pan with middle mouse button
|
|
141
|
+
|
|
142
|
+
## Context Menus
|
|
143
|
+
|
|
144
|
+
Three types of context menus:
|
|
145
|
+
1. **Canvas Menu**: Clear all nodes, general canvas operations
|
|
146
|
+
2. **Node Menu**: Node-specific operations (properties, delete, disconnect)
|
|
147
|
+
3. **Pin Menu**: Pin-specific operations (disconnect individual connections)
|
|
148
|
+
|
|
149
|
+
## Error Handling
|
|
150
|
+
|
|
151
|
+
Comprehensive error handling throughout:
|
|
152
|
+
- Try-catch blocks for canvas operations
|
|
153
|
+
- Graceful degradation when operations fail
|
|
154
|
+
- Debug logging for troubleshooting
|
|
155
|
+
- User-friendly error messages
|
|
156
|
+
|
|
157
|
+
## Performance Optimizations
|
|
158
|
+
|
|
159
|
+
- Connection update throttling (16ms delay for ~60fps)
|
|
160
|
+
- Lazy loading of node icons
|
|
161
|
+
- Efficient canvas coordinate conversions
|
|
162
|
+
- Minimal redraw operations during interactions
|
|
163
|
+
|
|
164
|
+
## Integration Points
|
|
165
|
+
|
|
166
|
+
- **Execution Engine**: Connects visual interface with computation backend
|
|
167
|
+
- **Node System**: Interfaces with the modular node architecture
|
|
168
|
+
- **Documentation System**: Integrates help and documentation display
|
|
169
|
+
- **File System**: Supports project save/load operations
|
|
170
|
+
|
|
171
|
+
## Future Enhancements
|
|
172
|
+
|
|
173
|
+
Planned improvements include:
|
|
174
|
+
- Advanced zoom operations (fit selection, zoom box)
|
|
175
|
+
- Enhanced search functionality in node library
|
|
176
|
+
- Improved connection routing algorithms
|
|
177
|
+
- Performance optimizations for large node graphs
|
|
178
|
+
- Extended keyboard shortcuts and accessibility features
|
|
179
|
+
|
|
180
|
+
## Dependencies
|
|
181
|
+
|
|
182
|
+
- `tkinter`: Core GUI framework
|
|
183
|
+
- `customtkinter`: Modern Tkinter theming
|
|
184
|
+
- `typing`: Type hints for better code documentation
|
|
185
|
+
- `math`: Mathematical operations for Bézier curves and transformations
|
|
186
|
+
- `threading`, `queue`: Terminal command execution
|
|
187
|
+
- `subprocess`: System command execution
|
|
188
|
+
- `importlib`: Dynamic node loading
|
|
189
|
+
- `PIL` (optional): Node icon loading
|
|
190
|
+
|
|
191
|
+
## File Structure
|
|
192
|
+
|
|
193
|
+
```
|
|
194
|
+
canvas.py
|
|
195
|
+
├── ExecutionState (enum)
|
|
196
|
+
├── ExecutionColors (dict)
|
|
197
|
+
├── DebugOutputCapture (class)
|
|
198
|
+
├── CanvasNode (class)
|
|
199
|
+
│ ├── Visual rendering methods
|
|
200
|
+
│ ├── Interaction handlers
|
|
201
|
+
│ └── Execution management
|
|
202
|
+
└── NodeCanvas (class)
|
|
203
|
+
├── UI setup methods
|
|
204
|
+
├── Event handlers
|
|
205
|
+
├── Connection management
|
|
206
|
+
├── Terminal integration
|
|
207
|
+
└── Node library interface
|
|
208
|
+
```
|
|
209
|
+
|
|
210
|
+
This documentation provides a comprehensive overview of the canvas system's architecture, functionality, and implementation details.
|