Skip to content

Commit

Permalink
fix: failing tests
Browse files Browse the repository at this point in the history
kapil-agnihotri committed Sep 10, 2024
1 parent 5790d7d commit 943f2c6
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions mcda/mcda_ranking_run.py
Original file line number Diff line number Diff line change
@@ -22,8 +22,8 @@
logger = logging.getLogger("ProMCDA")

# randomly assign seed if not specified as environment variable
RANDOM_SEED = os.environ.get('random_seed') if os.environ.get('random_seed') else 67
NUM_CORES = os.environ.get('num_cores') if os.environ.get('num_cores') else 1
RANDOM_SEED = int(os.environ.get('RANDOM_SEED')) if os.environ.get('RANDOM_SEED') else 67
NUM_CORES = int(os.environ.get('NUM_CORES')) if os.environ.get('NUM_CORES') else 1


# noinspection PyTypeChecker
4 changes: 2 additions & 2 deletions mcda/mcda_run.py
Original file line number Diff line number Diff line change
@@ -63,8 +63,8 @@ def config_dict_to_configuration_model(input_config):
elif config.robustness["robustness_on"] == "yes" and config.robustness["on_indicators"] == "yes":
robustness = "indicators"
input_json = input_matrix.to_json()
os.environ['NUM_CORES'] = input_config["monte_carlo_sampling"]["num_cores"]
os.environ['RANDOM_SEED'] = input_config["monte_carlo_sampling"]["random_seed"]
os.environ['NUM_CORES'] = str(input_config["monte_carlo_sampling"]["num_cores"])
os.environ['RANDOM_SEED'] = str(input_config["monte_carlo_sampling"]["random_seed"])
ranking_input_config = {
"inputMatrix": input_matrix,
"weights": input_config["robustness"]["given_weights"],

0 comments on commit 943f2c6

Please sign in to comment.