diff --git a/centerline_width/centerline.py b/centerline_width/centerline.py index a3065a5..004b6bd 100644 --- a/centerline_width/centerline.py +++ b/centerline_width/centerline.py @@ -1,7 +1,6 @@ # Built-in Python functions import math import logging -import csv # External Python libraries import numpy as np @@ -154,7 +153,6 @@ def equalDistanceCenterline(centerline_coordinates=None, if centerline_coordinates is None: return None - centerline_line = LineString(centerline_coordinates) equal_distance_between_centerline_coordinates = [] geodesic = pyproj.Geod(ellps=ellipsoid) diff --git a/centerline_width/pytests/test_errorPlotDiagrams.py b/centerline_width/pytests/test_errorPlotDiagrams.py index 81110ae..f50cf1e 100644 --- a/centerline_width/pytests/test_errorPlotDiagrams.py +++ b/centerline_width/pytests/test_errorPlotDiagrams.py @@ -385,7 +385,8 @@ def test_plotCenterlineWidth_darkModeInvalidTypes(invalid_input, error_output): @pytest.mark.parametrize("invalid_input, error_output", invalid_non_bool_options) -def test_plotCenterline_equalAxisInvalidTypes(invalid_input, error_output): +def test_plotCenterlineWidth_equalAxisInvalidTypes(invalid_input, + error_output): with pytest.raises( ValueError, match=re.escape( @@ -397,7 +398,7 @@ def test_plotCenterline_equalAxisInvalidTypes(invalid_input, error_output): @pytest.mark.parametrize("invalid_input, error_output", invalid_non_bool_options) -def test_plotCenterline_showPlotInvalidTypes(invalid_input, error_output): +def test_plotCenterlineWidth_showPlotInvalidTypes(invalid_input, error_output): with pytest.raises( ValueError, match=re.escape( diff --git a/centerline_width/relativeDistance.py b/centerline_width/relativeDistance.py index a624474..34b2e6c 100644 --- a/centerline_width/relativeDistance.py +++ b/centerline_width/relativeDistance.py @@ -65,7 +65,6 @@ def relativeCenterlineCoordinates(first_point, centerline_coordinates, def relativeRidgeCoordinates(first_point, x_ridge, y_ridge, ellipsoid): # Convert Voronoi ridges from Decimal Degree to Relative Distance - geodesic = pyproj.Geod(ellps=ellipsoid) x_relative_ridges = [] y_relative_ridges = [] @@ -89,7 +88,6 @@ def relativeRidgeCoordinates(first_point, x_ridge, y_ridge, ellipsoid): def relativeWidthCoordinates(first_point, width_dictionary, ellipsoid): # Convert width dictionary from Decimal Degree to Relative Distance - geodesic = pyproj.Geod(ellps=ellipsoid) relative_width_dictionary = {} for k, v in width_dictionary.items(): diff --git a/centerline_width/width.py b/centerline_width/width.py index 59d7c31..297aab9 100644 --- a/centerline_width/width.py +++ b/centerline_width/width.py @@ -1,5 +1,6 @@ # Built-in Python functions import logging +import csv # External Python libraries from shapely.geometry import Point, LineString @@ -101,8 +102,6 @@ def intersectsTopOrBottomOfBank(point1, point2): right_width_coordinates = {} left_width_coordinates = {} num_intersection_coordinates = {} - x = [] - y = [] min_x, min_y, max_x, max_y = river_object.bank_polygon.bounds for centerline_point, slope in centerline_slope.items():