代码拉取完成,页面将自动刷新
同步操作将从 JeffreyChan/V2V-PAEB 强制同步,此操作会覆盖自 Fork 仓库以来所做的任何修改,且无法恢复!!!
确定后同步将在后台操作,完成时将刷新页面,请耐心等待。
function [radar_out,num_det_objs] = radar_data_preprocessing(radar_in,vechicle_state,TISdet)
%#codegen
coder.extrinsic('fprintf')
radar_out = radar_in;
%m is number of rows, and n is number of comumns
%[m,n] = size(radar_in);
%fprintf('The demision of Radar Sensor data: m = %d , n = %d \r\n',m,n);
%Radar_Data_Rows_Per_Object = 10;
%Them max number of objects that the radar sensor can detect
Max_Num_Detected_objects = TISdet;%m/Radar_Data_Rows_Per_Object;
num_det_objs = false(Max_Num_Detected_objects,1);
%Extract the radar data and check if any objects has been detected
for i=1:Max_Num_Detected_objects
beam_id = radar_in(Max_Num_Detected_objects*0 + i);
range = radar_in(Max_Num_Detected_objects*1 + i);
velocity = radar_in(Max_Num_Detected_objects*2 + i);
velocity_x = radar_in(Max_Num_Detected_objects*3 + i);
velocity_y = radar_in(Max_Num_Detected_objects*4 + i);
velocity_z = radar_in(Max_Num_Detected_objects*5 + i);
theta = radar_in(Max_Num_Detected_objects*6 + i);
phi = radar_in(Max_Num_Detected_objects*7 + i);
target_id = radar_in(Max_Num_Detected_objects*8 + i);
target_type = radar_in(Max_Num_Detected_objects*9 + i);
velocity_trans_x = radar_in(Max_Num_Detected_objects*10 + i);
velocity_trans_y = radar_in(Max_Num_Detected_objects*11 + i);
velocity_trans_z = radar_in(Max_Num_Detected_objects*12 + i);
velocity_rot_x = radar_in(Max_Num_Detected_objects*13 + i);
velocity_rot_y = radar_in(Max_Num_Detected_objects*14 + i);
velocity_rot_z = radar_in(Max_Num_Detected_objects*15 + i);
%fprintf('Radar Data: beam_id = %d , range = %d, velocity = %d, velocity_x = %d, velocity_y = %d, velocity_z = %d \r\n',beam_id,range,velocity,velocity_x,velocity_y,velocity_z);
%fprintf('Radar Data: theta = %d, phi = %d, target_id = %d, target_type = %d \r\n',theta,phi,target_id,target_type);
if range > 0 && target_id > 0
num_det_objs(i) = true;
end
%We can do some filter thing here, and delete the objects that are not
%likely to be pedestrians or not be dangerous.
end
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。