Skip to content

Commit

Permalink
1. changed version to 1.0.0; modified trainer output table name error
Browse files Browse the repository at this point in the history
  • Loading branch information
h-mole committed Mar 5, 2024
1 parent a7ba9a1 commit 3fd429c
Show file tree
Hide file tree
Showing 6 changed files with 8 additions and 28 deletions.
2 changes: 1 addition & 1 deletion Melodie/data_collector.py
Original file line number Diff line number Diff line change
Expand Up @@ -410,7 +410,7 @@ def save(self):
_t = time.time()
self._write_list_to_table(
connection.get_engine(),
"Result_" + underline_to_camel(container_name),
"Result_Simulator_" + underline_to_camel(container_name),
self.agent_properties_dict[container_name],
)
write_db_time += time.time() - _t
Expand Down
2 changes: 1 addition & 1 deletion Melodie/trainer.py
Original file line number Diff line number Diff line change
Expand Up @@ -409,7 +409,7 @@ def calc_cov_df(
container_agent_record_list.append(cov_records)
self.manager._write_to_table(
"csv",
f"Result_Trainer_{underline_to_camel(container_name)}",
f"Result_Trainer_{underline_to_camel(container_name)}_Cov",
pd.DataFrame(container_agent_record_list),
)
env_record = {}
Expand Down
2 changes: 1 addition & 1 deletion Melodie/version.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
0.9.0
1.0.0
6 changes: 4 additions & 2 deletions MelodieInfra/config/config.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ def __init__(
visualizer_entry: str = "",
data_output_type: Literal["csv", "sqlite"] = "csv",
database_config: Optional["DBConfigTypes"] = None,
input_cache: bool = False,
**kwargs,
):
self.project_name = project_name
Expand All @@ -40,7 +41,8 @@ def __init__(

if database_config is None:
self.database_config = SQLiteDBConfig(
os.path.join(self.output_folder, self.project_name + SQLITE_FILE_SUFFIX)
os.path.join(self.output_folder,
self.project_name + SQLITE_FILE_SUFFIX)
)
else:
assert isinstance(database_config, BaseMelodieDBConfig), (
Expand All @@ -55,7 +57,7 @@ def __init__(
)
self.visualizer_entry = visualizer_entry
self.visualizer_tmpdir = os.path.join(self.temp_folder, "visualizer")
self.input_dataframe_cache = kwargs.get("input_dataframe_cache", False)
self.input_dataframe_cache = input_cache
self.init_temp_folders()

self.setup()
Expand Down
2 changes: 1 addition & 1 deletion MelodieInfra/db/db.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ class DBConn:

table_dtypes: Dict[str, TABLE_DTYPES] = {}
existing_connections: Dict[str, "DBConn"] = {}
ENVIRONMENT_RESULT_TABLE = "Result_Environment"
ENVIRONMENT_RESULT_TABLE = "Result_Simulator_Environment"

def __init__(
self,
Expand Down
22 changes: 0 additions & 22 deletions temp.md

This file was deleted.

0 comments on commit 3fd429c

Please sign in to comment.