Skip to content

Commit

Permalink
Fix another use of inequality on Shape
Browse files Browse the repository at this point in the history
  • Loading branch information
manopapad committed Feb 24, 2023
1 parent ed7d6b6 commit 91576e1
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion legate/core/partition.py
Original file line number Diff line number Diff line change
Expand Up @@ -238,7 +238,9 @@ def is_disjoint_for(self, launch_domain: Optional[Rect]) -> bool:
)

def has_color(self, color: Shape) -> bool:
return color >= 0 and color < self._color_shape
return all(a >= 0 for a in color) and all(
a < b for (a, b) in zip(color, self._color_shape)
)

@lru_cache
def get_subregion_size(self, extents: Shape, color: Shape) -> Shape:
Expand Down

0 comments on commit 91576e1

Please sign in to comment.