Skip to content
This repository has been archived by the owner on Nov 7, 2024. It is now read-only.

Commit

Permalink
GO FORMAT YOURSELF (black)
Browse files Browse the repository at this point in the history
  • Loading branch information
cow-bot committed Oct 4, 2022
1 parent cf0fa6b commit 88a7cf3
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 5 deletions.
16 changes: 12 additions & 4 deletions nexus_constructor/instrument_view/gnomon.py
Original file line number Diff line number Diff line change
Expand Up @@ -211,7 +211,9 @@ def create_gnomon_cones(self):
cone_transformation.setMatrix(matrix)

create_qentity(
[cone_mesh, cone_transformation, material], self.gnomon_root_entity, False
[cone_mesh, cone_transformation, material],
self.gnomon_root_entity,
False,
)

def create_gnomon_cylinders(self):
Expand All @@ -234,7 +236,9 @@ def create_gnomon_cylinders(self):
axis_transformation.setMatrix(matrix)

create_qentity(
[axis_mesh, axis_transformation, material], self.gnomon_root_entity, False
[axis_mesh, axis_transformation, material],
self.gnomon_root_entity,
False,
)

@staticmethod
Expand Down Expand Up @@ -366,7 +370,9 @@ def setup_beam_cylinder(self):
QColor("blue"), QColor("lightblue"), self.gnomon_root_entity, alpha=0.5
)
create_qentity(
[cylinder_mesh, beam_material, cylinder_transform], self.gnomon_root_entity, False
[cylinder_mesh, beam_material, cylinder_transform],
self.gnomon_root_entity,
False,
)

@staticmethod
Expand Down Expand Up @@ -435,4 +441,6 @@ def setup_neutrons(self):
QColor("black"), QColor("grey"), self.gnomon_root_entity
)

create_qentity([mesh, neutron_material, transform], self.gnomon_root_entity, False)
create_qentity(
[mesh, neutron_material, transform], self.gnomon_root_entity, False
)
2 changes: 1 addition & 1 deletion tests/geometry/test_disk_chopper_geometry_creator.py
Original file line number Diff line number Diff line change
Expand Up @@ -508,7 +508,7 @@ def test_GIVEN_chopper_details_WHEN_creating_disk_chopper_mesh_THEN_points_not_i
centre_to_bottom_of_slit = chopper_details.radius - chopper_details.slit_height

for point in geometry_creator.points[2:-2]:
distance_from_centre = np.sqrt(point.x ** 2 + point.y ** 2)
distance_from_centre = np.sqrt(point.x**2 + point.y**2)
assert np.isclose(distance_from_centre, chopper_details.radius) or np.isclose(
distance_from_centre, centre_to_bottom_of_slit
)
Expand Down

0 comments on commit 88a7cf3

Please sign in to comment.