Enhancements to SimulationTester and Main Function with Config Flexibility#48
Open
weihangzheng wants to merge 3 commits intomainfrom
Open
Enhancements to SimulationTester and Main Function with Config Flexibility#48weihangzheng wants to merge 3 commits intomainfrom
weihangzheng wants to merge 3 commits intomainfrom
Conversation
Thanoshan
requested changes
Jan 21, 2024
Collaborator
There was a problem hiding this comment.
Heads up here, this looks like its cloning the Config module that we already have in NEPIADA. This isn't ideal, since if we add a config parameter to that file, we would have to make changes here to keep things in sync. Instead I would recommend importing the Config module, and setting the values in a function here, and return a "Config" type module as the return parameter.
Collaborator
Author
There was a problem hiding this comment.
@Thanoshan I used json here addressed like you mentioned on Discord
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Enhancements to SimulationTester and Main Function with Config Flexibility
Description
This pull request introduces several enhancements to the
SimulationTesterclass and themainfunction used in the simulation framework. The key changes are as follows:1. SimulationTester Class Enhancements:
run_multiple_simulationsmethod.config_fileparameter in both the__init__method andrun_simulationmethod of theSimulationTesterclass. This allows users to specify a json file for the simulation, enhancing flexibility and customization of the simulation runs.print_resultsmethod to not only print the simulation results to the console but also write them to a CSV file. This file is stored in a directory specified byconfig.simulation_dir.2. Main Function Modification:
mainfunction to support dynamic import of theBaselineConfigclass based on an optionalconfig_fileparameter. This change allows the function to adapt to different configuration needs, improving the usability of the simulation framework for various scenarios.These enhancements aim to increase the versatility and user-friendliness of the simulation framework, providing more options for configuration and output handling.
Additional Notes
baseline_runand other dependent functions/modules are compatible with these enhancements.