Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix: Agents not moving due to FileNotFoundError (original author: @liaopeiyuan) #17

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

kuanyi-ng
Copy link

@kuanyi-ng kuanyi-ng commented Aug 10, 2023

Summary

Agents do not move after simulation (e.g., run 1) because of the following error:

FileNotFoundError: [Errno 2] No such file or directory: '{sim_folder}/movement/0.json'

📝 I am submitting this PR to address an error that has been fixed by the original author: @liaopeiyuan.
@liaopeiyuan deserves credit for identifying and resolving the issue. original commit
📝 Initially mentioned here: #5 (comment)

@@ -398,6 +398,9 @@ def start_server(self, int_counter):
# "persona": {"Klaus Mueller": {"movement": [38, 12]}},
# "meta": {curr_time: <datetime>}}
curr_move_file = f"{sim_folder}/movement/{self.step}.json"
# if the folder doesn't exist, we create it first.
if not os.path.exists(os.path.dirname(curr_move_file)):

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Its ok, i get this error, when trying to execute test-simulation.

jackboyla pushed a commit to jackboyla/generative_agents that referenced this pull request Dec 14, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants