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

fix tree merging for multiple params #92

Merged
merged 6 commits into from
Jan 23, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions MANIFEST.in
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
include requirements.txt
5 changes: 2 additions & 3 deletions polytope/datacube/index_tree.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

from sortedcontainers import SortedList

from .datacube_axis import IntDatacubeAxis
from .datacube_axis import IntDatacubeAxis, UnsliceableDatacubeAxis


class DatacubePath(OrderedDict):
Expand Down Expand Up @@ -85,7 +85,7 @@ def __eq__(self, other):
if other.value == self.value:
return True
else:
if isinstance(self.value, str):
if isinstance(self.axis, UnsliceableDatacubeAxis):
return False
else:
if other.value - 2 * other.axis.tol <= self.value <= other.value + 2 * other.axis.tol:
Expand All @@ -94,7 +94,6 @@ def __eq__(self, other):
return True
else:
return False
# return (self.axis.name, self.value) == (other.axis.name, other.value)

def __lt__(self, other):
return (self.axis.name, self.value) < (other.axis.name, other.value)
Expand Down
4 changes: 2 additions & 2 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
io.open("polytope/version.py", encoding="utf_8_sig").read(),
).group(1)

with open('requirements.txt') as f:
with open("requirements.txt") as f:
requirements = f.read().splitlines()

setup(
Expand All @@ -25,5 +25,5 @@
packages=find_packages(),
zip_safe=False,
include_package_data=True,
install_requires=requirements
install_requires=requirements,
)
Loading