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

Dead segments argument in psf_utils.fake_generatePupil not correctly handled #3

Open
krachyon opened this issue Apr 8, 2022 · 0 comments

Comments

@krachyon
Copy link
Contributor

krachyon commented Apr 8, 2022

It seems that dead segments are not calculated correctly. Instead of setting exactly N=deadSegments elements to refl=0, this

refl[(rng.random(deadSegments)*nseg).astype(int)]
is just a very convoluted way of saying

refl[rng.integers(0,nseg,deadSegments)]

but allows for a an alive segment to be killed multiple times. What about

refl[rng.choice(range(nseg), deadSegments)]?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: 📋 Backlog
Development

No branches or pull requests

1 participant