From 31c123fc10a170c33abba9a54bbf7bfcedee2017 Mon Sep 17 00:00:00 2001 From: Aleksandra Apolinarska Date: Wed, 10 Apr 2024 14:58:39 +0200 Subject: [PATCH] #2 unify/correct component_id names --- src/aixd_grasshopper/components/aixd_DatasetCreate/code.py | 2 +- src/aixd_grasshopper/components/aixd_DatasetLoad/code.py | 2 +- src/aixd_grasshopper/components/aixd_DatasetSummary/code.py | 2 +- src/aixd_grasshopper/components/aixd_Generator/code.py | 2 +- src/aixd_grasshopper/components/aixd_ModelDims/code.py | 2 +- src/aixd_grasshopper/components/aixd_ModelLoad/code.py | 2 +- src/aixd_grasshopper/components/aixd_ModelSetup/code.py | 2 +- src/aixd_grasshopper/components/aixd_ModelSummary/code.py | 2 +- src/aixd_grasshopper/components/aixd_ModelTrain/code.py | 2 +- src/aixd_grasshopper/components/aixd_PlotContours/code.py | 2 +- src/aixd_grasshopper/components/aixd_PlotCorrelations/code.py | 2 +- src/aixd_grasshopper/components/aixd_PlotDistributions/code.py | 2 +- src/aixd_grasshopper/components/aixd_ProjectSetup/code.py | 2 +- 13 files changed, 13 insertions(+), 13 deletions(-) diff --git a/src/aixd_grasshopper/components/aixd_DatasetCreate/code.py b/src/aixd_grasshopper/components/aixd_DatasetCreate/code.py index 3329be0..a63dd02 100644 --- a/src/aixd_grasshopper/components/aixd_DatasetCreate/code.py +++ b/src/aixd_grasshopper/components/aixd_DatasetCreate/code.py @@ -3,7 +3,7 @@ from aixd_grasshopper.gh_ui_helper import session_id, component_id from scriptcontext import sticky as st -cid = component_id(session_id(), ghenv.Component, "create_dataset_object") +cid = component_id(session_id(), ghenv.Component, "DatasetCreate") design_parameters = [x.data for x in design_parameters] diff --git a/src/aixd_grasshopper/components/aixd_DatasetLoad/code.py b/src/aixd_grasshopper/components/aixd_DatasetLoad/code.py index 7dcf9e4..5ed3053 100644 --- a/src/aixd_grasshopper/components/aixd_DatasetLoad/code.py +++ b/src/aixd_grasshopper/components/aixd_DatasetLoad/code.py @@ -3,7 +3,7 @@ from aixd_grasshopper.gh_ui_helper import session_id, component_id from scriptcontext import sticky as st -cid = component_id(session_id(), ghenv.Component, "create_dataset_object") +cid = component_id(session_id(), ghenv.Component, "DatasetLoad") if load: st[cid] = load_dataset(session_id()) diff --git a/src/aixd_grasshopper/components/aixd_DatasetSummary/code.py b/src/aixd_grasshopper/components/aixd_DatasetSummary/code.py index a415115..7a4664e 100644 --- a/src/aixd_grasshopper/components/aixd_DatasetSummary/code.py +++ b/src/aixd_grasshopper/components/aixd_DatasetSummary/code.py @@ -3,7 +3,7 @@ from aixd_grasshopper.gh_ui_helper import session_id, component_id from scriptcontext import sticky as st -cid = component_id(session_id(), ghenv.Component, "dataset_summary") +cid = component_id(session_id(), ghenv.Component, "DatasetSummary") if get: st[cid] = dataset_summary(session_id()) diff --git a/src/aixd_grasshopper/components/aixd_Generator/code.py b/src/aixd_grasshopper/components/aixd_Generator/code.py index 82940be..50aac37 100644 --- a/src/aixd_grasshopper/components/aixd_Generator/code.py +++ b/src/aixd_grasshopper/components/aixd_Generator/code.py @@ -40,7 +40,7 @@ def __repr__(self): from aixd_grasshopper.gh_ui_helper import session_id, component_id from scriptcontext import sticky as st -cid = component_id(session_id(), ghenv.Component, "run_generation") +cid = component_id(session_id(), ghenv.Component, "Generator") if run and request_ok: diff --git a/src/aixd_grasshopper/components/aixd_ModelDims/code.py b/src/aixd_grasshopper/components/aixd_ModelDims/code.py index e9974a7..d75c13c 100644 --- a/src/aixd_grasshopper/components/aixd_ModelDims/code.py +++ b/src/aixd_grasshopper/components/aixd_ModelDims/code.py @@ -3,7 +3,7 @@ from aixd_grasshopper.gh_ui_helper import session_id, component_id from scriptcontext import sticky as st -cid = component_id(session_id(), ghenv.Component, "model_dims") +cid = component_id(session_id(), ghenv.Component, "ModelDims") if get: st[cid] = model_input_output_dimensions(session_id()) diff --git a/src/aixd_grasshopper/components/aixd_ModelLoad/code.py b/src/aixd_grasshopper/components/aixd_ModelLoad/code.py index 3956781..1a5d883 100644 --- a/src/aixd_grasshopper/components/aixd_ModelLoad/code.py +++ b/src/aixd_grasshopper/components/aixd_ModelLoad/code.py @@ -3,7 +3,7 @@ from aixd_grasshopper.gh_ui_helper import session_id, component_id from scriptcontext import sticky as st -cid = component_id(session_id(), ghenv.Component, "model_load") +cid = component_id(session_id(), ghenv.Component, "ModelLoad") if not checkpoint_path: checkpoint_path = "" diff --git a/src/aixd_grasshopper/components/aixd_ModelSetup/code.py b/src/aixd_grasshopper/components/aixd_ModelSetup/code.py index a6e4687..06eb9be 100644 --- a/src/aixd_grasshopper/components/aixd_ModelSetup/code.py +++ b/src/aixd_grasshopper/components/aixd_ModelSetup/code.py @@ -5,7 +5,7 @@ from aixd_grasshopper.gh_ui_helper import component_id from aixd_grasshopper.gh_ui_helper import session_id -cid = component_id(session_id(), ghenv.Component, "model_setup") +cid = component_id(session_id(), ghenv.Component, "ModelSetup") settings = { "inputML": inputML, diff --git a/src/aixd_grasshopper/components/aixd_ModelSummary/code.py b/src/aixd_grasshopper/components/aixd_ModelSummary/code.py index ec7e68b..93d1388 100644 --- a/src/aixd_grasshopper/components/aixd_ModelSummary/code.py +++ b/src/aixd_grasshopper/components/aixd_ModelSummary/code.py @@ -5,7 +5,7 @@ from aixd_grasshopper.gh_ui_helper import component_id from aixd_grasshopper.gh_ui_helper import session_id -cid = component_id(session_id(), ghenv.Component, "model_summary") +cid = component_id(session_id(), ghenv.Component, "ModelSummary") if not max_depth: diff --git a/src/aixd_grasshopper/components/aixd_ModelTrain/code.py b/src/aixd_grasshopper/components/aixd_ModelTrain/code.py index e585ba8..c2e8422 100644 --- a/src/aixd_grasshopper/components/aixd_ModelTrain/code.py +++ b/src/aixd_grasshopper/components/aixd_ModelTrain/code.py @@ -7,7 +7,7 @@ from aixd_grasshopper.gh_ui_helper import component_id from aixd_grasshopper.gh_ui_helper import session_id -cid = component_id(session_id(), ghenv.Component, "model_train") +cid = component_id(session_id(), ghenv.Component, "ModelTrain") if not epochs or epochs < 1: diff --git a/src/aixd_grasshopper/components/aixd_PlotContours/code.py b/src/aixd_grasshopper/components/aixd_PlotContours/code.py index e92d1eb..98901f0 100644 --- a/src/aixd_grasshopper/components/aixd_PlotContours/code.py +++ b/src/aixd_grasshopper/components/aixd_PlotContours/code.py @@ -6,7 +6,7 @@ from aixd_grasshopper.gh_ui_helper import convert_str_to_bitmap from aixd_grasshopper.gh_ui_helper import session_id -cid = component_id(session_id(), ghenv.Component, "create_dataset_object") +cid = component_id(session_id(), ghenv.Component, "PlotContours") if plot: diff --git a/src/aixd_grasshopper/components/aixd_PlotCorrelations/code.py b/src/aixd_grasshopper/components/aixd_PlotCorrelations/code.py index fec564d..a32a92c 100644 --- a/src/aixd_grasshopper/components/aixd_PlotCorrelations/code.py +++ b/src/aixd_grasshopper/components/aixd_PlotCorrelations/code.py @@ -6,7 +6,7 @@ from aixd_grasshopper.gh_ui_helper import convert_str_to_bitmap from aixd_grasshopper.gh_ui_helper import session_id -cid = component_id(session_id(), ghenv.Component, "create_dataset_object") +cid = component_id(session_id(), ghenv.Component, "PlotCorrelations") if plot: diff --git a/src/aixd_grasshopper/components/aixd_PlotDistributions/code.py b/src/aixd_grasshopper/components/aixd_PlotDistributions/code.py index 6e09617..fadd476 100644 --- a/src/aixd_grasshopper/components/aixd_PlotDistributions/code.py +++ b/src/aixd_grasshopper/components/aixd_PlotDistributions/code.py @@ -6,7 +6,7 @@ from aixd_grasshopper.gh_ui_helper import convert_str_to_bitmap from aixd_grasshopper.gh_ui_helper import session_id -cid = component_id(session_id(), ghenv.Component, "create_dataset_object") +cid = component_id(session_id(), ghenv.Component, "PlotDistributions") if plot: diff --git a/src/aixd_grasshopper/components/aixd_ProjectSetup/code.py b/src/aixd_grasshopper/components/aixd_ProjectSetup/code.py index 73b3dd4..8466155 100644 --- a/src/aixd_grasshopper/components/aixd_ProjectSetup/code.py +++ b/src/aixd_grasshopper/components/aixd_ProjectSetup/code.py @@ -10,7 +10,7 @@ print("The path {} does not exist and will be now created.".format(complete_path)) os.mkdir(complete_path) - cid = component_id(session_id(), ghenv.Component, "project_setup") + cid = component_id(session_id(), ghenv.Component, "ProjectSetup") if set: clear_sticky(ghenv, st)