From 96f8d9f9ce86dba85367b9b0e0e090d92637be6c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Kacper=20R=C4=85czy?= Date: Tue, 11 Mar 2025 13:35:54 -0700 Subject: [PATCH] Move the import up --- selfdrive/locationd/lagd.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/selfdrive/locationd/lagd.py b/selfdrive/locationd/lagd.py index ad4e2bf251..e71bd60961 100755 --- a/selfdrive/locationd/lagd.py +++ b/selfdrive/locationd/lagd.py @@ -2,6 +2,8 @@ import numpy as np from collections import deque +from skimage.registration._masked_phase_cross_correlation import cross_correlate_masked + import cereal.messaging as messaging from cereal import car from openpilot.common.params import Params @@ -112,7 +114,6 @@ class LagEstimator(BaseLagEstimator): return np.arange(0, sig_len) * dt def actuator_delay(self, expected_sig, actual_sig, is_okay, dt, max_lag): - from skimage.registration._masked_phase_cross_correlation import cross_correlate_masked # masked (gated) normalized cross-correlation # normalized, can be used for anything, like comparsion