From 2e041f9fd5132105c2f03e902b06915f1f4f3eb9 Mon Sep 17 00:00:00 2001 From: foefl Date: Fri, 20 Jun 2025 09:05:02 +0200 Subject: [PATCH] add option to enable-disable edge rescaling --- lang_main_config.toml | 5 +++-- src/lang_main/constants.py | 1 + src/lang_main/lang_main_config.toml | 1 + 3 files changed, 5 insertions(+), 2 deletions(-) diff --git a/lang_main_config.toml b/lang_main_config.toml index 757166e..7fdd216 100644 --- a/lang_main_config.toml +++ b/lang_main_config.toml @@ -1,8 +1,8 @@ # d-opt -- lang_main: config file [paths] -inputs = '../data/in/' -results = '../data/out/' +inputs = './lang-main/data/tests/in/' +results = './lang-main/data/tests/out/' models = './lang-models' graph_export_filename = 'EXPORT-TokenGraph' @@ -35,6 +35,7 @@ threshold_amount_characters = 5 threshold_similarity = 0.92 [graph_postprocessing] +enable_edge_rescaling = true max_edge_number = -1 [time_analysis.uniqueness] diff --git a/src/lang_main/constants.py b/src/lang_main/constants.py index f805f6e..fd9ffe8 100644 --- a/src/lang_main/constants.py +++ b/src/lang_main/constants.py @@ -149,6 +149,7 @@ THRESHOLD_SIMILARITY: Final[float] = threshold_similarity # ** token analysis # ** graph postprocessing +ENABLE_EDGE_RESCALING: Final[bool] = CONFIG['graph_postprocessing']['enable_edge_rescaling'] EDGE_WEIGHT_DECIMALS: Final[int] = 6 max_edge_number: int | None = None max_edge_number_cfg: int = CONFIG['graph_postprocessing']['max_edge_number'] diff --git a/src/lang_main/lang_main_config.toml b/src/lang_main/lang_main_config.toml index 757166e..c79ee0e 100644 --- a/src/lang_main/lang_main_config.toml +++ b/src/lang_main/lang_main_config.toml @@ -35,6 +35,7 @@ threshold_amount_characters = 5 threshold_similarity = 0.92 [graph_postprocessing] +enable_edge_rescaling = true max_edge_number = -1 [time_analysis.uniqueness]