Skip to content

Commit

Permalink
pylintify
Browse files Browse the repository at this point in the history
  • Loading branch information
JanCaha committed Jul 25, 2024
1 parent f406340 commit 6b44a9f
Showing 1 changed file with 10 additions and 10 deletions.
20 changes: 10 additions & 10 deletions los_tools/classes/classes_los.py
Original file line number Diff line number Diff line change
Expand Up @@ -74,10 +74,10 @@ def __parse_points(self, points: List[List[float]]) -> None:
target_distance = calculate_distance(first_point_x, first_point_y, self.target_x, self.target_y)
sampling_distance = calculate_distance(points[0][0], points[0][1], points[1][0], points[1][1])

for i in range(0, len(points)):
point_x = points[i][0]
point_y = points[i][1]
point_z = points[i][2]
for i, point in enumerate(points):
point_x = point[0]
point_y = point[1]
point_z = point[2]

distance = calculate_distance(first_point_x, first_point_y, point_x, point_y)

Expand Down Expand Up @@ -137,12 +137,12 @@ def __parse_points(self, points: List[List[float]]) -> None:

def __str__(self):
string = ""
for i in range(0, len(self.points)):
for i, point in enumerate(self.points):
string += "{} - {} {} {} (prev. {}) - vis. {} hor. {} \n".format(
i,
self.points[i][self.DISTANCE],
self.points[i][self.Z],
self.points[i][self.VERTICAL_ANGLE],
point[self.DISTANCE],
point[self.Z],
point[self.VERTICAL_ANGLE],
self.previous_max_angle[i],
self.visible[i],
self.horizon[i],
Expand Down Expand Up @@ -171,8 +171,8 @@ def get_geom_at_index(self, index: int) -> QgsPoint:
def get_horizons(self) -> List[QgsPoint]:
points: List[QgsPoint] = []

for i in range(0, len(self.horizon)):
if self.horizon[i]:
for i, horizon in enumerate(self.horizon):
if horizon:
points.append(self.get_geom_at_index(i))

return points
Expand Down

0 comments on commit 6b44a9f

Please sign in to comment.