<commit_before>#pragma once
#include "User_Space_Includes.h"

namespace Scenario_Components
{
	namespace Types
	{
	}

	namespace Concepts
	{
	}
	
	namespace Prototypes
	{
		prototype struct Scenario_Prototype
		{
			tag_as_prototype;

			enum Assignment_Simulation_Mode_Keys
			{
				ONE_SHOT_ASSIGNMENT_SIMULATION_MODE=0,
				ITERATIVE_ASSIGNMENT_SIMULATION_MODE,
			};

			feature_accessor(current_simulation_interval_index, none, none);
			feature_accessor(simulation_interval_length, none, none);
			feature_accessor(assignment_interval_length, none, none);
			feature_accessor(current_time, none, none);

			feature_accessor(planning_horizon, none, none);
			feature_accessor(simulation_start_time, none, none);
			feature_accessor(simulation_end_time, none, none);
			
			feature_accessor(num_simulation_intervals, none, none);
			feature_accessor(num_assignment_intervals, none, none);
			feature_accessor(num_simulation_intervals_per_assignment_interval, none, none);

			feature_accessor(assignment_mode, none, none);

			feature_accessor(iseed, none, none);

			feature_accessor(output_writer, none, none);

			feature_accessor(network_cumulative_loaded_vehicles, none, none);
			feature_accessor(network_cumulative_departed_vehicles, none, none);
			feature_accessor(network_in_network_vehicles, none, none);
			feature_accessor(network_cumulative_arrived_vehicles, none, none);

			feature_prototype void read_scenario_data()
			{
				simulation_interval_length<int>(6); //6 seconds
				assignment_interval_length<int>(50*simulation_interval_length<int>()); // 5 minutes
				planning_horizon<int>(6000*simulation_interval_length<int>()); // 1 hour
				
				simulation_start_time<int>(0);
				simulation_end_time<int>(planning_horizon<int>()+simulation_start_time<int>());
				
				num_simulation_intervals<int>(planning_horizon<int>()/simulation_interval_length<int>());
				num_assignment_intervals<int>(planning_horizon<int>()/assignment_interval_length<int>());
				num_simulation_intervals_per_assignment_interval<int>(assignment_interval_length<int>()/simulation_interval_length<int>());
				
				assignment_mode<Assignment_Simulation_Mode_Keys>(ONE_SHOT_ASSIGNMENT_SIMULATION_MODE);
				<commit_msg>using json reader now<commit_after>#pragma once
#include "Scenario_Manager\cfg_reader.h"
#include "User_Space_Includes.h"


namespace Scenario_Components
{
	namespace Types
	{
	}

	namespace Concepts
	{
	}
	
	namespace Prototypes
	{
		prototype struct Scenario_Prototype
		{
			tag_as_prototype;

			enum Assignment_Simulation_Mode_Keys
			{
				ONE_SHOT_ASSIGNMENT_SIMULATION_MODE=0,
				ITERATIVE_ASSIGNMENT_SIMULATION_MODE,
			};

			feature_accessor(current_simulation_interval_index, none, none);
			feature_accessor(simulation_interval_length, none, none);
			feature_accessor(assignment_interval_length, none, none);
			feature_accessor(current_time, none, none);

			feature_accessor(planning_horizon, none, none);
			feature_accessor(simulation_start_time, none, none);
			feature_accessor(simulation_end_time, none, none);
			
			feature_accessor(num_simulation_intervals, none, none);
			feature_accessor(num_assignment_intervals, none, none);
			feature_accessor(num_simulation_intervals_per_assignment_interval, none, none);

			feature_accessor(assignment_mode, none, none);

			feature_accessor(iseed, none, none);

			feature_accessor(output_writer, none, none);

			feature_accessor(network_cumulative_loaded_vehicles, none, none);
			feature_accessor(network_cumulative_departed_vehicles, none, none);
			feature_accessor(network_in_network_vehicles, none, none);
			feature_accessor(network_cumulative_arrived_vehicles, none, none);

			feature_prototype void read_scenario_data()
			{
				CfgReader cfgReader;
				cfgReader.initialize("scenario.json");
				cfgReader.getParameter("simulation_interval_length", simulation_interval_length<int*>());
				//simulation_interval_length<int>(6); //6 seconds
				
				
				int assignment_intervals;
				cfgReader.getParameter("intervals_per_assignment", &assignment_intervals);
				assignment_interval_length<int>(assignment_intervals*simulation_interval_length<int>());
				//assignment_interval_length<int>(50*simulation_interval_length<int>()); // 5 minutes
				int planning_intervals;
				cfgReader.getParameter("planning_intervals", &planning_intervals);
				planning_horizon<int>(planning_intervals*simulation_interval_length<int>());
				//planning_horizon<int>(6000*simulation_interval_length<int>()); // 1 hour
				
				simulation_start_time<int>(0);
				simulation_end_time<int>(planning_horizon<int>()+simulation_start_time<int>());
				
				num_simulation_intervals<int>(planning_horizon<int>()/simulation_interval_length<int>());
				num_assignment_intervals<int>(planning_horizon<int>()/assignment_interval_length<int>());
				num_simulation_intervals_per_assignment_interval<int>(assignment_interval_length<int>()/simulation_interval_length<int>());
				
				assignment_mode<Assignment_Simulation_Mode_Keys>(ONE_SHOT_ASSIGNMENT_SIMULATION_MODE);
				
{'fraction_non_alphanumeric': 0.0957573354480571, 'fraction_numerical': 0.004758128469468675, 'mean_word_length': 7.097913322632424, 'pattern_counts': {'":': 0, '<': 46, '<?xml version=': 0, '>': 46, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3604308', 'n_tokens_mistral': 1894, 'n_tokens_neox': 1616, 'n_words': 198}