Skip to content

Commit

Permalink
removed unnecessary param name check when setting up the agents' params
Browse files Browse the repository at this point in the history
  • Loading branch information
SongminYu committed Jan 22, 2024
1 parent 5ac95f4 commit 4e31cc7
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion MelodieInfra/core/agent.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,8 @@ def set_params(self, params: Dict[str, Any]):
# assert (
# paramName in self.__dict__.keys()
# ), f"param named {paramName}, value {paramValue} not in Agent.params:{self.__dict__.keys()}"
setattr(self, paramName, paramValue)
if paramName in self.__dict__.keys():
setattr(self, paramName, paramValue)

def to_dict(self, properties: List[str] = None) -> Dict:
"""
Expand Down

0 comments on commit 4e31cc7

Please sign in to comment.