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
Overlaps() commutativity and atomic intervals #13
Comments
Thanks for reporting those bugs! I'll have a look in a few minutes. The second bug (about unions) seems similar to the one I went into yesterday (see #12). |
Bug should be fixed in the master branch, but I need to do more tests before releasing a change. |
Thanks. I installed with pip from git as you suggest, and it seems to work. I look forward to the official release! |
I hope to release 1.9.0 within the next few days, but I still have to do more tests with a completely new feature (an dict-like data structure that allows to store and query data along with intervals). I'll update this thread as soon as 1.9.0 will be available on PyPI ;) |
Release 1.9.0 is now available on PyPI. |
Thank you so much. The [1, 3] | [5, 7] = 1 Their sum would be a single [1, 2) | [5, 6) = 1 Regards, Marc |
Thanks for your feedback! I'll think about this. I cannot add support for "+", "-", "*", etc. because it is tightly coupled with numbers, and this library does not make any assumption on what are used as bounds in intervals. However, I can imagine a rather generic |
The |
Yes, on the values, not on the keys. I'll open a new issue for this feature, so I won't forget about it :-D (I don't think I'll have time to work on this in the next few days) |
Just to be sure, when you wrote "apply to the values (the range) not the keys (the domain)", you mean the converse? (keys are intervals/ranges, values are what are stored along with intervals), right? |
FYI, |
Release 1.10.0 is now available on PyPI. |
Thank you! I’ll take a look at it as soon as I have a little time…
Marc
-=-
393A -- Ground System Architecture & Systems Engineering
+1 818 393-7786
« Il semble que la perfection soit atteinte non quand il n'y a plus rien à ajouter, mais quand il n'y a plus rien à retrancher. »
"It seems that perfection is attained not when there is nothing more to add, but when there is nothing more to remove."
Antoine de Saint Exupéry, 1939
On 2019-09-26, at 00:43, Alexandre Decan <notifications@github.com<mailto:notifications@github.com>> wrote:
Release 1.10.0 is now available on PyPI.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub<#13>, or mute the thread<https://github.com/notifications/unsubscribe-auth/AB5YEAES3YE7HSZAXSBGLILQLRRYXANCNFSM4IV42WSA>.
|
The overlaps() function seems to have some problem with commutativity and atomic intervals.
This example has a problem:
I.closed(1,1).overlaps(I.openclosed(1,2))
False
(correct)I.openclosed(1,2).overlaps(I.closed(1,1))
True
(should be False)But, this example succeeds:
I.closed(0,1).overlaps(I.openclosed(1,2))
False
(correct)I.openclosed(1,2).overlaps(I.closed(0,1))
False
(correct)There is a similar problem with union.
This example has a problem:
I.closed(1,1) | I.openclosed(1,2)
(1,2]
(should be [1,2])I.openclosed(1,2) | I.closed(1,1)
(1,2]
(should be [1,2])But, this example succeeds:
I.closed(0,1) | I.openclosed(1,2)
[0,2]
(correct)I.openclosed(1,2) | I.closed(0,1)
[0,2]
(correct)The text was updated successfully, but these errors were encountered: