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

Adding Abstract DiscreteSpaceDF #30

Merged
merged 26 commits into from
Jul 23, 2024
Merged

Adding Abstract DiscreteSpaceDF #30

merged 26 commits into from
Jul 23, 2024

Conversation

adamamer20
Copy link
Collaborator

@adamamer20 adamamer20 commented Jul 20, 2024

This PR adds an abstract class to define the interface for Discrete Spaces (Grids and Networks).

Some points to consider:

  • A default capacity can be set in the __init__, which can be overriden by a capacity set in set_cells. There might be some performance benefits if only a default capacity was allowed (I think we can consider changing it after we have the concrete implementation)
  • Distinction between "empty" and "free" cells. Empty cells are cells were no agent is currently present, free cells are cells where some agents may be present but there is some remaining capacity.

@adamamer20 adamamer20 requested a review from rht July 20, 2024 09:19
@adamamer20 adamamer20 self-assigned this Jul 20, 2024
@adamamer20 adamamer20 added the enhancement Improvements to existing features or performance. label Jul 20, 2024
@adamamer20 adamamer20 added this to the 1.0.0 Alpha Release milestone Jul 20, 2024
mesa_frames/abstract/space.py Outdated Show resolved Hide resolved
mesa_frames/abstract/space.py Outdated Show resolved Hide resolved
@adamamer20 adamamer20 changed the title Adding DiscreteSpaceDF Adding Abstract DiscreteSpaceDF Jul 21, 2024
@adamamer20
Copy link
Collaborator Author

Sorry for the delay, I've been a bit busy the last few days

@rht rht merged commit e5f9802 into main Jul 23, 2024
6 checks passed
@rht rht deleted the abstract-discrete-space branch July 23, 2024 08:35
This was linked to issues Jul 24, 2024
@adamamer20 adamamer20 restored the abstract-discrete-space branch July 24, 2024 10:54
@adamamer20 adamamer20 deleted the abstract-discrete-space branch July 24, 2024 10:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement Improvements to existing features or performance.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Refactoring mesa.space Abstract DiscreteSpaceDF
2 participants