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

ValueError when time is floating point in _select_lp #76

Open
ozzdemir opened this issue Jun 22, 2021 · 1 comment
Open

ValueError when time is floating point in _select_lp #76

ozzdemir opened this issue Jun 22, 2021 · 1 comment

Comments

@ozzdemir
Copy link

Hi, when I gave floating point time instances, random.randint() gives Value error. Is there a particular reason for using random.randint() instead of random.uniform() ? [I locally replaced it with random.uniform(), and it worked with floating time also].

new_t0 = random.randint(t0, tend - lp_len)

Note that I did not give lp_frame explicitly, so it took the time from "ideal". (If the choice is related to performance, maybe rounding can be made?)

Thanks in advance

@krzysztofarendt
Copy link
Member

Hi, this is probably a bug. Could you make a PR with a fix including a simple unit test for this case?
https://jarv.is/notes/how-to-pull-request-fork-github/

If not, I will try to find some time to do it, but I cannot promise any deadline. I have limited time for maintaining this project.

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