Skip to content
Snippets Groups Projects
Commit 2e2c982a authored by Raphael's avatar Raphael
Browse files

fix depreciation warning

parent a7b3b586
No related branches found
No related tags found
2 merge requests!21fix depreciation warning,!13Draft: Develop
...@@ -358,11 +358,11 @@ class AISTrajectory(AISPoints): ...@@ -358,11 +358,11 @@ class AISTrajectory(AISPoints):
elif type(features) is list: elif type(features) is list:
features_vectors = self.df[features].to_numpy() features_vectors = self.df[features].to_numpy()
for c in features_vectors.T: for c in features_vectors.T:
bounds.append((0, max(c))) bounds.append([0, max(c)])
elif type(features) is str: elif type(features) is str:
features_vectors = self.df[[features]].to_numpy() features_vectors = self.df[[features]].to_numpy()
for c in features_vectors.T: for c in features_vectors.T:
bounds.append((0, max(c))) bounds.append([0, max(c)])
elif type(features) is dict: elif type(features) is dict:
bounds = list(features.values()) bounds = list(features.values())
features_vectors = self.df[features.keys()].to_numpy() features_vectors = self.df[features.keys()].to_numpy()
...@@ -383,6 +383,6 @@ class AISTrajectory(AISPoints): ...@@ -383,6 +383,6 @@ class AISTrajectory(AISPoints):
generate_links(data, positions, height, width, lower_lat, upper_lat, lower_lon, upper_lon) generate_links(data, positions, height, width, lower_lat, upper_lat, lower_lon, upper_lon)
else: else:
generate_points_with_features(data, positions, features_vectors, bounds, node_size, height, width, generate_points_with_features(data, positions, features_vectors, np.array(bounds), node_size, height, width,
lower_lat, upper_lat, lower_lon, upper_lon, link) lower_lat, upper_lat, lower_lon, upper_lon, link)
return data return data
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment