Skip to content

Commit

Permalink
🎨
Browse files Browse the repository at this point in the history
  • Loading branch information
arafune committed Feb 28, 2024
1 parent 217f4a8 commit 05f3f1c
Show file tree
Hide file tree
Showing 7 changed files with 11 additions and 9 deletions.
2 changes: 1 addition & 1 deletion README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ Details can be found on `the documentation site`_.
Suggested steps
---------------

1. install `rye <https://rye-up.com>`.
1. install `rye <https://rye-up.com>`__.
2. Clone or duplicate the folder structure in this repository.
3. `rye sync`
4. Activate `arpes` environment.
Expand Down
1 change: 0 additions & 1 deletion pytest-config/pytest-coverage-codecov.ini
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ addopts =
--doctest-modules
--cov arpes
--cov-report=xml
--ignore=arpes/analysis/fft.py

norecursedirs =
.git
Expand Down
1 change: 0 additions & 1 deletion pytest-config/pytest-coverage.ini
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ addopts =
--cov arpes
--cov-report=term
--cov-report=html
--ignore=arpes/analysis/fft.py

norecursedirs =
.git
Expand Down
1 change: 0 additions & 1 deletion pytest-config/pytest.ini
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@ addopts =
-l
--failed-first
--doctest-modules
--ignore=arpes/analysis/fft.py

norecursedirs =
.git
Expand Down
7 changes: 5 additions & 2 deletions src/arpes/utilities/geometry.py
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ def polyhedron_intersect_plane(
plane_point: Any point on the plane
epsilon: Used to determine precision for non-intersection
"""
collected_points = []
collected_points: list[NDArray[np.float_]] = []

def add_point(c: NDArray[np.float_]) -> None:
already_collected = False
Expand All @@ -123,7 +123,10 @@ def add_point(c: NDArray[np.float_]) -> None:
b,
epsilon=epsilon,
)
if segment_contains_point(a, b, intersection, epsilon=epsilon):
if (
segment_contains_point(a, b, intersection, epsilon=epsilon)
and intersection is not None
):
add_point(intersection)

points = ConvexHull(collected_points, qhull_options="Qc QJ").points
Expand Down
2 changes: 1 addition & 1 deletion src/arpes/utilities/qt/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ def wrapped_handler(
data: XrTypes,
*,
detached: bool = False,
**kwargs: Incomplete,
**kwargs: P.kwargs,
) -> None:
if not detached:
return tool_handler(data, **kwargs)
Expand Down
6 changes: 4 additions & 2 deletions src/arpes/xarray_extensions.py
Original file line number Diff line number Diff line change
Expand Up @@ -317,8 +317,10 @@ def is_slit_vertical(self) -> bool:
angle_tolerance = 1.0
if self.angle_unit.startswith("Deg") or self.angle_unit.startswith("deg"):
return float(np.abs(self.lookup_offset_coord("alpha") - 90.0)) < angle_tolerance
return float(np.abs(self.lookup_offset_coord("alpha") - np.pi / 2)) < np.deg2rad(
angle_tolerance,
return float(np.abs(self.lookup_offset_coord("alpha") - np.pi / 2)) < float(
np.deg2rad(
angle_tolerance,
),
)

@property
Expand Down

0 comments on commit 05f3f1c

Please sign in to comment.