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

Small bug relating to PR #101 #102

Closed
TomGeorge1234 opened this issue Feb 1, 2024 · 1 comment
Closed

Small bug relating to PR #101 #102

TomGeorge1234 opened this issue Feb 1, 2024 · 1 comment
Assignees

Comments

@TomGeorge1234
Copy link
Collaborator

@colleenjg relating to PR #101

Sorry! After giving it the all clear I ran the tests and spotted an extra warning. If I just initialise a population of BVCs

Env = Environment()
Ag = Agent(Env)
BVCs = BoundaryVectorCells(Ag,params={'n':11})

it warns

UserWarning: Ignoring 'n' parameter value (11) that was passed, and setting number of BoundaryVectorCells neurons to 11, inferred from the cell arrangement parameter.

Sorry, I can dig into this in the morning but it might be quicker for you to solve.

@TomGeorge1234 TomGeorge1234 self-assigned this Feb 1, 2024
@colleenjg
Copy link
Contributor

Oh yes! That's because I was relying on the non-equality to raise the warning. I removed it quickly after our discussion without realizing that the decision to create the warning fully depends on it. And I didn't rerun my test code 😬

I'll fix it! Thanks for noticing it!

colleenjg added a commit to colleenjg/RatInABox that referenced this issue Feb 2, 2024
…atInABox-Lab#102.

Reintroduced an equality check for raising a warning if value of self.n was passed, but is reset internally in a VectorCells class.
Equality is checked if `cell_arrangement` does not end in `"manifold"` (i.e., `"diverging_manifold"` or `"uniform_manifold"`.
If `cell_arrangement` is `"random"` or a callable function, a warning is only raised if the value of self.n would actually change.
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

No branches or pull requests

2 participants