diff --git a/argoverse/data_loading/frame_label_accumulator.py b/argoverse/data_loading/frame_label_accumulator.py index aebfb1e7..08b2fb35 100644 --- a/argoverse/data_loading/frame_label_accumulator.py +++ b/argoverse/data_loading/frame_label_accumulator.py @@ -5,7 +5,6 @@ import glob import logging import os -import pickle as pkl import tempfile from pathlib import Path from typing import Dict, List, Optional, Tuple @@ -18,9 +17,7 @@ from argoverse.data_loading.synchronization_database import SynchronizationDB from argoverse.data_loading.trajectory_loader import TrajectoryLabel, load_json_track_labels from argoverse.utils.json_utils import read_json_file -from argoverse.utils.pkl_utils import load_pkl_dictionary, save_pkl_dictionary -from argoverse.utils.se3 import SE3 -from argoverse.utils.transform import quat2rotmat +from argoverse.utils.pkl_utils import save_pkl_dictionary logger = logging.getLogger(__name__) @@ -65,7 +62,8 @@ def __init__( log_egopose_dict_fpath = f"{tmp_dir}/log_egopose_dict_{experiment_prefix}.pkl" log_timestamp_dict_fpath = f"{tmp_dir}/log_timestamp_dict_{experiment_prefix}.pkl" - coordinate_system = "map_world_fr" + # coordinate system is the map world frame + self.per_city_traj_dict: Dict[str, List[Tuple[np.ndarray, str]]] = { "MIA": [], "PIT": [], diff --git a/argoverse/data_loading/object_label_record.py b/argoverse/data_loading/object_label_record.py index 7ac049d1..9446f4db 100644 --- a/argoverse/data_loading/object_label_record.py +++ b/argoverse/data_loading/object_label_record.py @@ -2,12 +2,10 @@ # -import copy import json import os -from typing import Any, Dict, Iterable, List, Optional, Tuple +from typing import Any, Dict, List, Optional, Tuple -import cv2 import numpy as np from argoverse.utils.calibration import CameraConfig, proj_cam_to_uv diff --git a/argoverse/data_loading/simple_track_dataloader.py b/argoverse/data_loading/simple_track_dataloader.py index 4c695991..ca2bfaba 100644 --- a/argoverse/data_loading/simple_track_dataloader.py +++ b/argoverse/data_loading/simple_track_dataloader.py @@ -1,17 +1,13 @@ # import glob -import sys from pathlib import Path from typing import Any, List, Mapping, Optional -import numpy as np - from argoverse.data_loading.pose_loader import get_city_SE3_egovehicle_at_sensor_t, read_city_name from argoverse.data_loading.synchronization_database import SynchronizationDB from argoverse.utils.json_utils import read_json_file from argoverse.utils.se3 import SE3 -from argoverse.utils.transform import quat2rotmat class SimpleArgoverseTrackingDataLoader: diff --git a/argoverse/data_loading/synchronization_database.py b/argoverse/data_loading/synchronization_database.py index f6872350..34b5889b 100644 --- a/argoverse/data_loading/synchronization_database.py +++ b/argoverse/data_loading/synchronization_database.py @@ -5,14 +5,13 @@ import glob import logging from pathlib import Path -from typing import Dict, Iterable, List, Optional, Tuple, cast +from typing import Dict, Iterable, Optional, Tuple, cast import numpy as np from typing_extensions import Final from argoverse.sensor_dataset_config import ArgoverseConfig from argoverse.utils.camera_stats import RING_CAMERA_LIST, STEREO_CAMERA_LIST -from argoverse.utils.json_utils import read_json_file from argoverse.utils.metric_time import TimeUnit, to_metric_time logger = logging.getLogger(__name__) diff --git a/argoverse/data_loading/trajectory_loader.py b/argoverse/data_loading/trajectory_loader.py index a02f4384..cc156644 100644 --- a/argoverse/data_loading/trajectory_loader.py +++ b/argoverse/data_loading/trajectory_loader.py @@ -6,7 +6,6 @@ import glob import json import logging -import sys from pathlib import Path from typing import List, NamedTuple diff --git a/argoverse/data_loading/vector_map_loader.py b/argoverse/data_loading/vector_map_loader.py index 1e0ad410..f25f8750 100644 --- a/argoverse/data_loading/vector_map_loader.py +++ b/argoverse/data_loading/vector_map_loader.py @@ -41,8 +41,6 @@ import logging import os -import pathlib -import sys import xml.etree.ElementTree as ET from typing import Any, Dict, List, Mapping, MutableMapping, Optional, Tuple, Union, cast diff --git a/argoverse/evaluation/competition_util.py b/argoverse/evaluation/competition_util.py index 4f89bfb7..23c64f9d 100644 --- a/argoverse/evaluation/competition_util.py +++ b/argoverse/evaluation/competition_util.py @@ -6,7 +6,6 @@ import shutil import tempfile import uuid -import zipfile from typing import Dict, List, Optional, Tuple, Union import h5py diff --git a/argoverse/evaluation/eval_forecasting.py b/argoverse/evaluation/eval_forecasting.py index 0e523fac..4aed8ff1 100644 --- a/argoverse/evaluation/eval_forecasting.py +++ b/argoverse/evaluation/eval_forecasting.py @@ -3,8 +3,7 @@ """This module evaluates the forecasted trajectories against the ground truth.""" import math -import pickle as pkl -from typing import Dict, List, Optional, Tuple +from typing import Dict, List, Optional import numpy as np diff --git a/argoverse/evaluation/eval_utils.py b/argoverse/evaluation/eval_utils.py index 8e8ab9df..2bd06ed4 100644 --- a/argoverse/evaluation/eval_utils.py +++ b/argoverse/evaluation/eval_utils.py @@ -1,7 +1,6 @@ # """Utilities used in evaluation of performance.""" -import copy from typing import Any, Dict, List, Tuple import numpy as np diff --git a/argoverse/map_representation/lane_segment.py b/argoverse/map_representation/lane_segment.py index 07616f99..ea0c652c 100644 --- a/argoverse/map_representation/lane_segment.py +++ b/argoverse/map_representation/lane_segment.py @@ -1,5 +1,5 @@ # -from typing import List, Optional, Sequence +from typing import List, Optional import numpy as np diff --git a/argoverse/map_representation/map_api.py b/argoverse/map_representation/map_api.py index 2a0eac41..3524ec5b 100644 --- a/argoverse/map_representation/map_api.py +++ b/argoverse/map_representation/map_api.py @@ -2,7 +2,6 @@ import copy import os -from os import PathLike from pathlib import Path from typing import Any, Dict, Iterable, List, Mapping, Optional, Tuple, Union diff --git a/argoverse/utils/bfs.py b/argoverse/utils/bfs.py index 455a4983..675ee043 100644 --- a/argoverse/utils/bfs.py +++ b/argoverse/utils/bfs.py @@ -2,7 +2,7 @@ """Breadth-First-Search of Graphs.""" -from typing import Any, Collection, List, Mapping, MutableMapping, Sequence +from typing import Any, List, Mapping, MutableMapping, Sequence def bfs_enumerate_paths(graph: Mapping[str, Sequence[str]], start: str, max_depth: int = 4) -> List[List[str]]: diff --git a/argoverse/utils/calibration.py b/argoverse/utils/calibration.py index a5fba247..bcd4924c 100644 --- a/argoverse/utils/calibration.py +++ b/argoverse/utils/calibration.py @@ -11,13 +11,7 @@ from typing_extensions import Literal from argoverse.data_loading.pose_loader import get_city_SE3_egovehicle_at_sensor_t -from argoverse.utils.camera_stats import ( - CAMERA_LIST, - RECTIFIED_STEREO_CAMERA_LIST, - RING_CAMERA_LIST, - STEREO_CAMERA_LIST, - get_image_dims_for_camera, -) +from argoverse.utils.camera_stats import CAMERA_LIST, RECTIFIED_STEREO_CAMERA_LIST, get_image_dims_for_camera from argoverse.utils.se3 import SE3 from argoverse.utils.transform import quat2rotmat diff --git a/argoverse/utils/camera_stats.py b/argoverse/utils/camera_stats.py index 51bf9925..dfa43297 100644 --- a/argoverse/utils/camera_stats.py +++ b/argoverse/utils/camera_stats.py @@ -3,7 +3,7 @@ # import logging -from typing import List, Optional, Tuple +from typing import Optional, Tuple from argoverse.sensor_dataset_config import ArgoverseConfig diff --git a/argoverse/utils/centerline_utils.py b/argoverse/utils/centerline_utils.py index 35211192..94cbfa62 100644 --- a/argoverse/utils/centerline_utils.py +++ b/argoverse/utils/centerline_utils.py @@ -6,7 +6,7 @@ import matplotlib.pyplot as plt import numpy as np -from shapely.geometry import LinearRing, LineString, Point, Polygon +from shapely.geometry import LinearRing, LineString, Point from argoverse.map_representation.lane_segment import LaneSegment @@ -81,10 +81,7 @@ def centerline_to_polygon( # right centerline position depends on sign of dx and dy subtract_cond1 = np.logical_and(dx > 0, dy < 0) subtract_cond2 = np.logical_and(dx > 0, dy > 0) - add_cond1 = np.logical_and(dx < 0, dy < 0) - add_cond2 = np.logical_and(dx < 0, dy > 0) subtract_cond = np.logical_or(subtract_cond1, subtract_cond2) - add_cond = np.logical_or(add_cond1, add_cond2) left_centerline, right_centerline = swap_left_and_right(subtract_cond, left_centerline, right_centerline) # right centerline also depended on if we added or subtracted y @@ -258,8 +255,6 @@ def get_nt_distance(xy: np.ndarray, centerline: np.ndarray, viz: bool = False) - traj_len = xy.shape[0] nt_distance = np.zeros((traj_len, 2)) - delta_offset = 0.01 - last = 0 max_dist: float = -1 for i in range(traj_len): diff --git a/argoverse/utils/cuboid_interior.py b/argoverse/utils/cuboid_interior.py index 47780d4a..4669be6d 100644 --- a/argoverse/utils/cuboid_interior.py +++ b/argoverse/utils/cuboid_interior.py @@ -98,7 +98,6 @@ def filter_point_cloud_to_bbox_2D_vectorized(bbox: np.ndarray, pc_raw: np.ndarra P1 = np.array([bbox[0][0:2]]) P2 = np.array([bbox[1][0:2]]) P4 = np.array([bbox[2][0:2]]) - P5 = np.array([]) dot1 = np.matmul(U, pc_2d.transpose(1, 0)) dot2 = np.matmul(V, pc_2d.transpose(1, 0)) diff --git a/argoverse/utils/cv2_plotting_utils.py b/argoverse/utils/cv2_plotting_utils.py index 3cca5ba7..3a95706a 100644 --- a/argoverse/utils/cv2_plotting_utils.py +++ b/argoverse/utils/cv2_plotting_utils.py @@ -1,7 +1,7 @@ # """OpenCV plotting utility functions.""" -from typing import Dict, Iterable, List, Tuple, Union +from typing import List, Tuple import cv2 import numpy as np diff --git a/argoverse/utils/frustum_clipping.py b/argoverse/utils/frustum_clipping.py index 44510f30..1f200b1f 100644 --- a/argoverse/utils/frustum_clipping.py +++ b/argoverse/utils/frustum_clipping.py @@ -6,8 +6,7 @@ """ import copy -import sys -from typing import Any, Iterable, List, Optional, Tuple +from typing import Any, List, Optional, Tuple import numpy as np @@ -232,7 +231,7 @@ def generate_frustum_planes(K: np.ndarray, camera_name: str, near_clip_dist: flo if img_width is None or img_height is None: return None - P = np.array([0.0, 0.0, 0.0]) + # frustum starts at optical center [0,0,0] fx = K[0, 0] fy = K[1, 1] diff --git a/argoverse/utils/interpolate.py b/argoverse/utils/interpolate.py index fb0ce8f8..3024ec5b 100644 --- a/argoverse/utils/interpolate.py +++ b/argoverse/utils/interpolate.py @@ -2,7 +2,6 @@ from typing import Tuple, cast -import matplotlib.pyplot as plt import numpy as np # For a single line segment @@ -177,20 +176,16 @@ def interp_arc(t: int, px: np.ndarray, py: np.ndarray) -> np.ndarray: """ px, py = eliminate_duplicates_2d(px, py) - # equally spaced in arclength + # equally spaced in arclength -- the number of points that will be uniformly interpolated eq_spaced_points = np.linspace(0, 1, t) - # how many points will be uniformly interpolated? - nt = eq_spaced_points.size - # the number of points on the curve itself n = px.size # are px and py both vectors of the same length? assert px.size == py.size - pxy = np.array((px, py)).T - ndim = 2 + pxy = np.array((px, py)).T # 2d polyline # Compute the chordal arclength of each segment. # Compute differences between each x coord, to get the dx's diff --git a/argoverse/utils/make_att_files.py b/argoverse/utils/make_att_files.py index 5871e439..279e4023 100644 --- a/argoverse/utils/make_att_files.py +++ b/argoverse/utils/make_att_files.py @@ -4,14 +4,12 @@ from typing import Any, Dict, List, Tuple import cv2 -import matplotlib.pyplot as plt import numpy as np import open3d as o3d import scipy.interpolate as interpolate import torch import torch.nn.functional as F -import argoverse from argoverse.data_loading.argoverse_tracking_loader import ArgoverseTrackingLoader from argoverse.utils.json_utils import read_json_file from argoverse.utils.pkl_utils import save_pkl_dictionary diff --git a/argoverse/utils/make_track_label_folders.py b/argoverse/utils/make_track_label_folders.py index bfc216b5..c5c9f0f5 100644 --- a/argoverse/utils/make_track_label_folders.py +++ b/argoverse/utils/make_track_label_folders.py @@ -4,8 +4,6 @@ import sys from typing import Any, Dict, List -from typing_extensions import TypedDict - from argoverse.utils.json_utils import read_json_file, save_json_dict root_dir = sys.argv[1] diff --git a/argoverse/utils/manhattan_search.py b/argoverse/utils/manhattan_search.py index 88277b8e..53e40e34 100644 --- a/argoverse/utils/manhattan_search.py +++ b/argoverse/utils/manhattan_search.py @@ -3,7 +3,7 @@ """Fast search functions of nearest neighbor based on Manhattan distance.""" import logging -from typing import List, Tuple, Union +from typing import List, Tuple import numpy as np diff --git a/argoverse/utils/plane_visualization_utils.py b/argoverse/utils/plane_visualization_utils.py index 0cf2640a..3f9de265 100644 --- a/argoverse/utils/plane_visualization_utils.py +++ b/argoverse/utils/plane_visualization_utils.py @@ -1,6 +1,5 @@ # -import sys from typing import List, Optional import numpy as np @@ -11,7 +10,6 @@ Figure, draw_mayavi_line_segment, plot_3d_clipped_bbox_mayavi, - plot_bbox_3d_mayavi, plot_points_3D_mayavi, ) diff --git a/argoverse/visualization/generate_sequence_videos.py b/argoverse/visualization/generate_sequence_videos.py index d5d91df2..e42862b7 100644 --- a/argoverse/visualization/generate_sequence_videos.py +++ b/argoverse/visualization/generate_sequence_videos.py @@ -4,18 +4,13 @@ import argparse import os -import re import shutil import sys -from collections import defaultdict from typing import List -import matplotlib.animation as anim -import matplotlib.lines as mlines import matplotlib.pyplot as plt import numpy as np import pandas as pd -from scipy.interpolate import interp1d from argoverse.map_representation.map_api import ArgoverseMap from argoverse.visualization.visualize_sequences import viz_sequence @@ -49,7 +44,6 @@ def main(arguments: List[str]) -> int: # Get API for Argo Dataset map avm = ArgoverseMap() city_name = df["CITY_NAME"].values[0] - seq_lane_bbox = avm.city_halluc_bbox_table[city_name] seq_lane_props = avm.city_lane_centerlines_dict[city_name] x_min = min(df["X"]) diff --git a/argoverse/visualization/visualization_utils.py b/argoverse/visualization/visualization_utils.py index b03a0f28..28fa83ef 100644 --- a/argoverse/visualization/visualization_utils.py +++ b/argoverse/visualization/visualization_utils.py @@ -4,7 +4,6 @@ from collections import defaultdict from typing import Any, Dict, Iterable, List, Optional, Tuple, Union -import cv2 import matplotlib.pyplot as plt import numpy as np from PIL import Image @@ -12,7 +11,7 @@ from argoverse.data_loading.argoverse_tracking_loader import ArgoverseTrackingLoader from argoverse.data_loading.object_classes import OBJ_CLASS_MAPPING_DICT from argoverse.data_loading.object_label_record import ObjectLabelRecord -from argoverse.utils.calibration import Calibration, determine_valid_cam_coords, proj_cam_to_uv +from argoverse.utils.calibration import Calibration from argoverse.utils.frustum_clipping import generate_frustum_planes point_size = 0.01 @@ -208,8 +207,6 @@ def draw_box( def show_image_with_boxes(img: np.ndarray, objects: Iterable[ObjectLabelRecord], calib: Calibration) -> np.ndarray: """Show image with 2D bounding boxes.""" img1 = np.copy(img) - K = calib.K - d = calib.d h, w = np.shape(img1)[0:2] planes = generate_frustum_planes(calib.K, calib.camera) @@ -219,7 +216,6 @@ def show_image_with_boxes(img: np.ndarray, objects: Iterable[ObjectLabelRecord], if obj.occlusion == 100: continue box3d_pts_3d = obj.as_3d_bbox() - uv = calib.project_ego_to_image(box3d_pts_3d) uv_cam = calib.project_ego_to_cam(box3d_pts_3d) img1 = obj.render_clip_frustum_cv2( diff --git a/argoverse/visualization/visualize_sequences.py b/argoverse/visualization/visualize_sequences.py index 5903aa1b..1acbca28 100644 --- a/argoverse/visualization/visualize_sequences.py +++ b/argoverse/visualization/visualize_sequences.py @@ -1,14 +1,9 @@ #!/usr/bin/env python """A simple python script template.""" -import argparse -import os -import shutil -import sys from collections import defaultdict from typing import Dict, List, Optional -import matplotlib.animation as anim import matplotlib.lines as mlines import matplotlib.pyplot as plt import numpy as np @@ -42,13 +37,11 @@ def viz_sequence( ) -> None: # Seq data - time_list = np.sort(np.unique(df["TIMESTAMP"].values)) city_name = df["CITY_NAME"].values[0] if lane_centerlines is None: # Get API for Argo Dataset map avm = ArgoverseMap() - seq_lane_bbox = avm.city_halluc_bbox_table[city_name] seq_lane_props = avm.city_lane_centerlines_dict[city_name] plt.figure(0, figsize=(8, 7)) diff --git a/demo_usage/cuboids_to_bboxes.py b/demo_usage/cuboids_to_bboxes.py index d24da081..b681075d 100644 --- a/demo_usage/cuboids_to_bboxes.py +++ b/demo_usage/cuboids_to_bboxes.py @@ -1,13 +1,11 @@ # import argparse import copy -import glob import logging import os -import sys from multiprocessing import Pool from pathlib import Path -from typing import Any, Iterable, List, Mapping, Sequence, Tuple, Union +from typing import Any, Iterable, List, Sequence, Tuple, Union import cv2 import imageio @@ -287,7 +285,7 @@ def main(args: Any): for log_id in log_ids ] with Pool(os.cpu_count()) as p: - accum = p.starmap(dump_clipped_3d_cuboids_to_images, single_process_args) + p.starmap(dump_clipped_3d_cuboids_to_images, single_process_args) else: # run in a single process, instead diff --git a/demo_usage/visualize_ground_lidar_points.py b/demo_usage/visualize_ground_lidar_points.py index bcb427c5..44d2e8ee 100644 --- a/demo_usage/visualize_ground_lidar_points.py +++ b/demo_usage/visualize_ground_lidar_points.py @@ -2,7 +2,6 @@ import argparse import glob -import sys from pathlib import Path import numpy as np diff --git a/integration_tests/test_map_api.py b/integration_tests/test_map_api.py index 6d295355..629d2b1b 100644 --- a/integration_tests/test_map_api.py +++ b/integration_tests/test_map_api.py @@ -4,13 +4,11 @@ import glob from typing import Set, Tuple -import matplotlib import matplotlib.pyplot as plt import numpy as np from argoverse.map_representation.map_api import ArgoverseMap from argoverse.utils.datetime_utils import generate_datetime_string -from argoverse.utils.geometry import point_inside_polygon from argoverse.utils.json_utils import read_json_file from argoverse.utils.mpl_plotting_utils import plot_lane_segment_patch diff --git a/integration_tests/test_plane_visualization_utils.py b/integration_tests/test_plane_visualization_utils.py index 354f0e6a..29475338 100644 --- a/integration_tests/test_plane_visualization_utils.py +++ b/integration_tests/test_plane_visualization_utils.py @@ -1,6 +1,5 @@ import os import pathlib -import sys import matplotlib.pyplot as plt import pytest @@ -58,4 +57,4 @@ def test_populate_frustum_voxels() -> None: def test_get_perpendicular() -> None: """Test getting an orthogonal vector from a given query vector.""" n = [0, 1, 1] - result = get_perpendicular(n) + get_perpendicular(n) diff --git a/integration_tests/test_tracker_eval.py b/integration_tests/test_tracker_eval.py index a45450ae..4cc490f6 100644 --- a/integration_tests/test_tracker_eval.py +++ b/integration_tests/test_tracker_eval.py @@ -1,15 +1,11 @@ # -import os import pathlib import numpy as np from argoverse.evaluation import eval_tracking, eval_utils from argoverse.utils import ply_loader -from argoverse.utils.json_utils import read_json_file -from argoverse.utils.se3 import SE3 -from argoverse.utils.transform import quat2rotmat TEST_DATA_LOC = pathlib.Path(__file__).parent.parent / "tests" / "test_data" / "tracking" D_MIN = 0 diff --git a/tests/test_argoverse_tracking_loader.py b/tests/test_argoverse_tracking_loader.py index 72521fee..fe6520c5 100644 --- a/tests/test_argoverse_tracking_loader.py +++ b/tests/test_argoverse_tracking_loader.py @@ -1,7 +1,6 @@ # """Tracking Loader unit tests""" -import glob import pathlib import numpy as np diff --git a/tests/test_cv2_plotting_utils.py b/tests/test_cv2_plotting_utils.py index 79ea22f7..1aafdbd9 100644 --- a/tests/test_cv2_plotting_utils.py +++ b/tests/test_cv2_plotting_utils.py @@ -2,12 +2,7 @@ import numpy as np -from argoverse.utils.cv2_plotting_utils import ( - draw_point_cloud_in_img_cv2, - draw_polygon_cv2, - draw_polyline_cv2, - plot_bbox_polygon_cv2, -) +from argoverse.utils.cv2_plotting_utils import draw_point_cloud_in_img_cv2, draw_polygon_cv2, plot_bbox_polygon_cv2 def test_draw_point_cloud_in_img_cv2_smokescreen() -> None: diff --git a/tests/test_eval_forecasting.py b/tests/test_eval_forecasting.py index 46bec02b..4432f4c6 100644 --- a/tests/test_eval_forecasting.py +++ b/tests/test_eval_forecasting.py @@ -2,7 +2,7 @@ """This module tests the motion forecasting metric computation.""" -from typing import Dict, Mapping +from typing import Mapping import numpy as np import pytest diff --git a/tests/test_eval_tracking.py b/tests/test_eval_tracking.py index f83417d2..404c5473 100644 --- a/tests/test_eval_tracking.py +++ b/tests/test_eval_tracking.py @@ -367,7 +367,6 @@ def test_1obj_poor_translation() -> None: result_dict = run_eval(exp_name=log_id) assert result_dict["num_frames"] == 4 - sw = 0 mota = 1 - ((2 + 2 + 0) / 4) # 1 - (FN+FP+SW)/#GT assert mota == 0.0 assert result_dict["mota"] == 0.0 diff --git a/tests/test_frame_label_accumulator.py b/tests/test_frame_label_accumulator.py index 5aa494cb..ee517abe 100644 --- a/tests/test_frame_label_accumulator.py +++ b/tests/test_frame_label_accumulator.py @@ -1,9 +1,7 @@ # """Forecasting Loader unit tests""" -import glob import pathlib -import tempfile import numpy as np import pytest diff --git a/tests/test_interpolate.py b/tests/test_interpolate.py index 699c83df..7fc0ee04 100644 --- a/tests/test_interpolate.py +++ b/tests/test_interpolate.py @@ -300,7 +300,6 @@ def test_compute_midpoint_line_curved_maintain_4_waypts() -> None: draw_polygon_mpl(ax, centerline_pts, "r") gt_centerline_pts = np.array([[-1, 2], [1, 2], [3, 0], [3, -2]]) - gt_lane_width = 2.0 assert np.allclose(centerline_pts[0], gt_centerline_pts[0]) assert np.allclose(centerline_pts[-1], gt_centerline_pts[-1]) diff --git a/tests/test_sim2.py b/tests/test_sim2.py index bb7bc741..078f5bed 100644 --- a/tests/test_sim2.py +++ b/tests/test_sim2.py @@ -192,4 +192,4 @@ def test_cannot_set_zero_scale() -> None: s = 0.0 with pytest.raises(ZeroDivisionError) as e_info: - aSb = Sim2(R, t, s) + Sim2(R, t, s) diff --git a/tests/test_transform.py b/tests/test_transform.py index 7d1ae7b0..c895f046 100644 --- a/tests/test_transform.py +++ b/tests/test_transform.py @@ -153,7 +153,7 @@ def test_invalid_quaternion_zero_norm(): q = np.array([0.0, 0.0, 0.0, 0.0]) with pytest.raises(ZeroDivisionError) as e_info: - R = quat2rotmat(q) + quat2rotmat(q) def test_quaternion_renormalized():