Loading raps/run_sim.py +1 −10 Original line number Diff line number Diff line Loading @@ -13,7 +13,7 @@ from raps.ui import LayoutManager from raps.plotting import Plotter from raps.engine import Engine from raps.multi_part_engine import MultiPartEngine from raps.utils import write_dict_to_file, pydantic_add_args, SubParsers, yaml_dump from raps.utils import write_dict_to_file, pydantic_add_args, SubParsers, yaml_dump, read_yaml from raps.stats import ( get_engine_stats, get_job_stats, Loading @@ -25,15 +25,6 @@ from raps.stats import ( from raps.sim_config import SingleSimConfig, MultiPartSimConfig, SIM_SHORTCUTS def read_yaml(config_file: str): if config_file == "-": return yaml.safe_load(sys.stdin.read()) elif config_file: return yaml.safe_load(Path(config_file).read_text()) else: return {} def run_sim_add_parser(subparsers: SubParsers): parser = subparsers.add_parser("run", description=""" Run single-partition (homogeneous) systems. Supports synthetic workload generation or Loading raps/utils.py +10 −0 Original line number Diff line number Diff line Loading @@ -750,6 +750,16 @@ def yaml_dump(data): ) def read_yaml(config_file: str): """ Parses yaml file. Pass "-" to read from stdin """ if config_file == "-": return yaml.safe_load(sys.stdin.read()) elif config_file: return yaml.safe_load(Path(config_file).read_text()) else: return {} class WorkloadData(RAPSBaseModel): """ Represents a workload, a list of jobs with some metadata. Returned by dataloaders load_data() Loading Loading
raps/run_sim.py +1 −10 Original line number Diff line number Diff line Loading @@ -13,7 +13,7 @@ from raps.ui import LayoutManager from raps.plotting import Plotter from raps.engine import Engine from raps.multi_part_engine import MultiPartEngine from raps.utils import write_dict_to_file, pydantic_add_args, SubParsers, yaml_dump from raps.utils import write_dict_to_file, pydantic_add_args, SubParsers, yaml_dump, read_yaml from raps.stats import ( get_engine_stats, get_job_stats, Loading @@ -25,15 +25,6 @@ from raps.stats import ( from raps.sim_config import SingleSimConfig, MultiPartSimConfig, SIM_SHORTCUTS def read_yaml(config_file: str): if config_file == "-": return yaml.safe_load(sys.stdin.read()) elif config_file: return yaml.safe_load(Path(config_file).read_text()) else: return {} def run_sim_add_parser(subparsers: SubParsers): parser = subparsers.add_parser("run", description=""" Run single-partition (homogeneous) systems. Supports synthetic workload generation or Loading
raps/utils.py +10 −0 Original line number Diff line number Diff line Loading @@ -750,6 +750,16 @@ def yaml_dump(data): ) def read_yaml(config_file: str): """ Parses yaml file. Pass "-" to read from stdin """ if config_file == "-": return yaml.safe_load(sys.stdin.read()) elif config_file: return yaml.safe_load(Path(config_file).read_text()) else: return {} class WorkloadData(RAPSBaseModel): """ Represents a workload, a list of jobs with some metadata. Returned by dataloaders load_data() Loading