radar_start = 300 #Initial 500 380 for flight 6 300 for flight 7 motion_start = 3850 #5200 flight 6 3900 flight 7 2411 flight 8 motion_end = 34129 #16400 flight 6 34129 flight 7 29126 flight 8 #Aligns data aligned_data = align_data(radar_data, motion_data, radar_start, motion_start, motion_end, 200, 4600) #100, 3500 #Plots aligned graph with known data point AlignedGraph( aligned_data, radar_data, [[-0.254065627, 0.252586546, 2.662674582], [-0.264097265, 0.237835515, -3.115790777]] ) #[[.942713,.1,1.019]] Final: [[-0.254065627, 0.252586546, 2.662674582], [-0.264097265, 0.237835515, -3.115790777]] #Calculates and plots BackProjected Image #IntensityList = BackProjection(aligned_data,radar_data,[-4,0],[4,4],0.1) IntensityList2 = FastBackProjection(aligned_data, radar_data, [-2.0, 0.5], [1.5, 1.75], 0.002) #Deconvolutes image and plots images Image = deconvolute(IntensityList2, IterationNumber=3, LeftInterval=[-2.0, 0.5], RightInterval=[1.5, 1.75], PercentageMin=1 / 20) ''' FinalDict = {'orig_sar_img': IntensityList2, 'proc_sar_img': Image, 'x_axis': arange(-4, 4+0.01,0.01), 'y_axis': arange(0, 4+0.01, 0.01)} with open('UAVSAR1.pickle', 'wb') as handle: pickle.dump(FinalDict, handle, protocol=pickle.HIGHEST_PROTOCOL) '''
motion_end = 29545 #Aligns data, currently using frames given in function definition aligned_data = align_data(radar_data, motion_data, radar_start, motion_start, motion_end, 100, 3500) WrongRadarPosition = aligned_data[1] #Actual position of radar in 3D space PulseData = aligned_data[0] #Data of all pulses in file RangeBins = radar_data[ 2] #Distance in meters between the sampling rate of PulseData #Plots aligned graph AlignedGraph(aligned_data, radar_data) #Calculates and plots BackProjected Image IntensityList = BackProjection(aligned_data, radar_data, [-4, 0], [4, 4], 0.01) #IntensityList = read_intensity('../Raw_Data/intensity2.csv') #Deconvolutes image and plots images deconvolute(IntensityList, IterationNumber=3, PercentageMin=1 / 5.5) ''' #Currently unused code #Calculates backprojected image using Ramu's algorithm interp_approach(aligned_data,radar_data,[-3,3],[-3,3],.1) #Reads in an intensity list and saves it as an intensity list IntensityList = read_intensity('../Raw_Data/intensity2.csv') '''
#Plot RTI for radar_data plotRTI(radar_data) #Set parameters #Take motion_start and motion_end from .tak file video #Estimate radar_start from the plotRTI above, initially comment out code below radar_start = 510 #Flight4: 505, FLight3: 135, Flight2: 113 motion_start = 3450 #Flight2: 3300, Flight3: 2400, FLight4: 3450, Flight5: 4477 motion_end = 14462 #Flight2: 24000, Flight3: 15382, Flight4: 14462, Flight5: 14201 #Aligns data aligned_data = align_data(radar_data, motion_data, radar_start, motion_start, motion_end, 100, 1200) #100, 3500 #Plots aligned graph with known data point AlignedGraph(aligned_data, radar_data, [[2.920519426, 0.089892255, -1.116615139] ]) # (2.920519426, 0.089892255, -1.116615139) #Calculates and plots BackProjected Image IntensityList = FastBackProjection(aligned_data, radar_data, [-3, 1.5], [0, 4], 0.01) #Deconvolutes image and plots images Image = deconvolute(IntensityList, IterationNumber=2, PercentageMin=1 / 5) ''' plt.figure(5) plt.imshow(Image) plt.show() '''
#Plot RTI for radar_data plotRTI(radar_data) #Set parameters #Take motion_start and motion_end from .tak file video #Estimate radar_start from the plotRTI above, initially comment out code below radar_start = 510 #Flight4: 510, FLight3: 135, Flight2: 113 motion_start = 3450 #Flight2: 3300, Flight3: 2400, FLight4: 3450, Flight5: 4477 motion_end = 14462 #Flight2: 24000, Flight3: 15382, Flight4: 14462, Flight5: 14201 #Aligns data aligned_data = align_data(radar_data,motion_data,radar_start,motion_start, motion_end, 100, 1200) #100, 3500 #Plots aligned graph with known data point AlignedGraph(aligned_data,radar_data, [[2.920519426, 0.089892255, -1.116615139]]) # (2.920519426, 0.089892255, -1.116615139) #Calculates and plots BackProjected Image IntensityList = FastBackProjection(aligned_data,radar_data,[-3,1.5],[0,4],0.02) #Deconvolutes image and plots images Image = deconvolute(IntensityList, [-3,1.5],[0,4], IterationNumber = 2, PercentageMin = 1/5, ) ''' plt.figure(5) plt.imshow(Image) cbar = plt.colorbar() plt.show() '''