Configurable spatial connectivity feature - #307
Merged
anyaevostinar merged 125 commits intoJul 10, 2026
Conversation
…rmatting in SpatialStructure.h. Add example spatial structure files.
…atial structure setup code into smaller helper functions for each spatial structure mode.
…incorporating spatial structure into SymWorld
…on to sgp world, more spacing consistency fixes
…m backend. Move corresponding setup code into helper functions.
…ake cure updates config a size_t instead of int
…wo examples in tests
…unctions for unit testing, continue updating tests to work with spatial structure changes
…e spatial structure updates
| } | ||
|
|
||
| TEST_CASE("SetupSymbionts with tag matching on", "[default]"){ | ||
| // NOTE: This test is a little bit frustrating to maintain if we change calls to |
Owner
There was a problem hiding this comment.
Looks good, let's remove this comment
| config.PGG(1); | ||
| config.MUTATION_SIZE(0.05); | ||
| config.UPDATES(2000); | ||
| // @AML: These world size parameters weren't taking effect in the original test |
Owner
There was a problem hiding this comment.
Awesome, thanks! We can remove this comment now
| cfg.MUTATION_SIZE(0); | ||
| } | ||
|
|
||
| // Wrapper for Symbumlation world classes intended to expose protected |
anyaevostinar
requested changes
Jul 8, 2026
anyaevostinar
left a comment
Owner
There was a problem hiding this comment.
Whew, some things to change and some questions
…ni/SymbulationEmp into spatial-struct-lalejini
… accomodate change
Removed commented-out debug output for new host position.
anyaevostinar
approved these changes
Jul 10, 2026
anyaevostinar
left a comment
Owner
There was a problem hiding this comment.
Yey, looks good, thank you!!!!
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The main feature added by this pull request is the ability to load any graph structure (either in a matrix format or in a csv, one row per edge) to define the population's structure (i.e, which individuals neighbor each other). This feature is implemented in default mode, so it should work for all currently implemented downstream modes.
Adding arbitrary spatial structure configuration required a few fundamental tweaks to basic setup, such as requiring that spatial structure be configured before initializing the population. This motivated shifting SetupHosts and SetupSymbionts to protected functions that should be called only from the World's Setup function.
Other less major changes:
) {, etc.). Mainly in files that were already being touched by this pull request.source/test/test_utils.h. E.g., a world wrapper for exposing public functions to tests.source/utils.hActive TODOS before merging:
Questions / notes to reviewer(s)