|
|
@ -6,17 +6,20 @@ While the roll calibration is a real value that can be estimated, here we assume |
|
|
|
and the image input into the neural network is not corrected for roll. |
|
|
|
and the image input into the neural network is not corrected for roll. |
|
|
|
''' |
|
|
|
''' |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
import gc |
|
|
|
import os |
|
|
|
import os |
|
|
|
from typing import NoReturn |
|
|
|
|
|
|
|
import numpy as np |
|
|
|
import numpy as np |
|
|
|
import cereal.messaging as messaging |
|
|
|
from typing import NoReturn |
|
|
|
|
|
|
|
|
|
|
|
from cereal import log |
|
|
|
from cereal import log |
|
|
|
from selfdrive.hardware import TICI |
|
|
|
import cereal.messaging as messaging |
|
|
|
from common.params import Params, put_nonblocking |
|
|
|
from common.params import Params, put_nonblocking |
|
|
|
|
|
|
|
from common.realtime import set_realtime_priority |
|
|
|
from common.transformations.model import model_height |
|
|
|
from common.transformations.model import model_height |
|
|
|
from common.transformations.camera import get_view_frame_from_road_frame |
|
|
|
from common.transformations.camera import get_view_frame_from_road_frame |
|
|
|
from common.transformations.orientation import rot_from_euler, euler_from_rot |
|
|
|
from common.transformations.orientation import rot_from_euler, euler_from_rot |
|
|
|
from selfdrive.config import Conversions as CV |
|
|
|
from selfdrive.config import Conversions as CV |
|
|
|
|
|
|
|
from selfdrive.hardware import TICI |
|
|
|
from selfdrive.swaglog import cloudlog |
|
|
|
from selfdrive.swaglog import cloudlog |
|
|
|
|
|
|
|
|
|
|
|
MIN_SPEED_FILTER = 15 * CV.MPH_TO_MS |
|
|
|
MIN_SPEED_FILTER = 15 * CV.MPH_TO_MS |
|
|
@ -191,6 +194,9 @@ class Calibrator(): |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
def calibrationd_thread(sm=None, pm=None) -> NoReturn: |
|
|
|
def calibrationd_thread(sm=None, pm=None) -> NoReturn: |
|
|
|
|
|
|
|
gc.disable() |
|
|
|
|
|
|
|
set_realtime_priority(1) |
|
|
|
|
|
|
|
|
|
|
|
if sm is None: |
|
|
|
if sm is None: |
|
|
|
sm = messaging.SubMaster(['cameraOdometry', 'carState'], poll=['cameraOdometry']) |
|
|
|
sm = messaging.SubMaster(['cameraOdometry', 'carState'], poll=['cameraOdometry']) |
|
|
|
|
|
|
|
|
|
|
|