Skip to content

Color_patches example array refactor#403

Open
ShreyasN707 wants to merge 3 commits intomesa:mainfrom
ShreyasN707:color-patches-array-refactor
Open

Color_patches example array refactor#403
ShreyasN707 wants to merge 3 commits intomesa:mainfrom
ShreyasN707:color-patches-array-refactor

Conversation

@ShreyasN707
Copy link
Contributor

This PR refactors the color_patches example to store environment state in a NumPy array on the model instead of within individual agents.
This PR follows issue : #366 and follows other prs: #382 , #375

Refactor Checklist

  • Refactor preserves original model behavior (no logic changes)
  • Environment state moved from agents to model (NumPy array)
  • Uses current Mesa patterns and APIs
  • Improves separation between agents and environment state
  • No unnecessary complexity introduced
  • Changes are minimal and focused on the refactor

@Nandha-kumar-S
Copy link
Contributor

hi @ShreyasN707 just a quick heads up, PR #346 was recently merged, which updated the color_patches example to the new SolaraViz / AgentPortrayalStyle API and refactored the grid access. You'll likely run into some merge conflicts in app.py and model.py. Since your NumPy refactor is a great addition, I wanted to let you know so you can align it with the new visualization changes whenever you're ready to rebase, Thanks

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.

2 participants