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

usage of intensity within random.py distributions? #113

Open
jGaboardi opened this issue Aug 9, 2023 · 2 comments
Open

usage of intensity within random.py distributions? #113

jGaboardi opened this issue Aug 9, 2023 · 2 comments

Comments

@jGaboardi
Copy link
Member

Within random.parse_size_and_intensity() the intensity variable is returned when called within each available distribution (poisson, normal, cluster_poisson, and cluster_normal). However, intensity does not appear to used outside parse_size_and_intensity().

Does intensity actually need to be returned from parse_size_and_intensity()?

@ljwolf
Copy link
Member

ljwolf commented Aug 10, 2023

Intensity and the first element of the "Size" tuple give the same information. Like, sampling a unit square at intensity 2 should be the same as sampling two points from it.

The intensity is returned from the parse function just in case future functions find it easier to work with that than with the sizes. Right now, though, we're always using the sizes, either inferred from intensity or given by the user.

That make sense?

@jGaboardi
Copy link
Member Author

jGaboardi commented Aug 10, 2023

Yes, that makes sense.

The intensity is returned from the parse function just in case future functions find it easier to work with that than with the sizes. Right now, though, we're always using the sizes, either inferred from intensity or given by the user.

Would you be against me putting in a PR that adds some information to the docstring to remind us (me) for future reference?

@ljwolf Thoughts in this?

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

No branches or pull requests

2 participants