@@ -533,7 +533,6 class AMISRReader(ProcessingUnit): | |||||
533 | nblocks = self.nblocks |
|
533 | nblocks = self.nblocks | |
534 | nsamples = self.nsa |
|
534 | nsamples = self.nsa | |
535 | #print("Channels: ",self.nChannels) |
|
535 | #print("Channels: ",self.nChannels) | |
536 | print("dataset: ", self.dataset.shape) |
|
|||
537 | #Dimensions : nChannels, nProfiles, nSamples |
|
536 | #Dimensions : nChannels, nProfiles, nSamples | |
538 | new_block = numpy.empty((nblocks, nchan, numpy.int_(self.newProfiles), nsamples), dtype="complex64") |
|
537 | new_block = numpy.empty((nblocks, nchan, numpy.int_(self.newProfiles), nsamples), dtype="complex64") | |
539 | ############################################ |
|
538 | ############################################ |
@@ -2203,7 +2203,6 class IncohInt(Operation): | |||||
2203 | self._nProfilesByRange += dataOut.nProfilesByRange |
|
2203 | self._nProfilesByRange += dataOut.nProfilesByRange | |
2204 |
|
2204 | |||
2205 | if self.__dataReady: |
|
2205 | if self.__dataReady: | |
2206 | print("IncohInt Done ", self.incohInt) |
|
|||
2207 | #print("prof: ",dataOut.max_nIncohInt,self.__profIndex) |
|
2206 | #print("prof: ",dataOut.max_nIncohInt,self.__profIndex) | |
2208 | dataOut.data_spc = avgdata_spc |
|
2207 | dataOut.data_spc = avgdata_spc | |
2209 | dataOut.data_cspc = avgdata_cspc |
|
2208 | dataOut.data_cspc = avgdata_cspc | |
@@ -2218,7 +2217,7 class IncohInt(Operation): | |||||
2218 | dataOut.nProfilesByRange = self._nProfilesByRange |
|
2217 | dataOut.nProfilesByRange = self._nProfilesByRange | |
2219 | self._nProfilesByRange = numpy.zeros((1,len(dataOut.heightList))) |
|
2218 | self._nProfilesByRange = numpy.zeros((1,len(dataOut.heightList))) | |
2220 | self._flagProfilesByRange = False |
|
2219 | self._flagProfilesByRange = False | |
2221 |
|
2220 | #print("IncohInt Done") | ||
2222 | return dataOut |
|
2221 | return dataOut | |
2223 |
|
2222 | |||
2224 | class dopplerFlip(Operation): |
|
2223 | class dopplerFlip(Operation): |
@@ -3116,7 +3116,7 class remFaradayProfiles(Operation): | |||||
3116 | self.flagRemove = False |
|
3116 | self.flagRemove = False | |
3117 | self.k = 0 |
|
3117 | self.k = 0 | |
3118 |
|
3118 | |||
3119 |
def setup(self, channel,nChannels=5, nProfiles=300,nBlocks=100, nIpp2= |
|
3119 | def setup(self, channel,nChannels=5, nProfiles=300,nBlocks=100, nIpp2=300, nTx2=132, nTaus=22, offTaus=14, iTaus=8, | |
3120 | nfft=1): |
|
3120 | nfft=1): | |
3121 | ''' |
|
3121 | ''' | |
3122 | nProfiles = amisr profiles per block -> raw data |
|
3122 | nProfiles = amisr profiles per block -> raw data | |
@@ -3151,7 +3151,6 class remFaradayProfiles(Operation): | |||||
3151 | if k%nIpp2==0: #each sync PPs or 2, 3, or 5 |
|
3151 | if k%nIpp2==0: #each sync PPs or 2, 3, or 5 | |
3152 | f_ntx = True |
|
3152 | f_ntx = True | |
3153 | kt = 0 |
|
3153 | kt = 0 | |
3154 | #print(k, fi, j, f_iTaus) |
|
|||
3155 | if f_ntx: |
|
3154 | if f_ntx: | |
3156 |
|
3155 | |||
3157 | if kt%nTaus==0: #each sequence of Taus |
|
3156 | if kt%nTaus==0: #each sequence of Taus | |
@@ -3168,11 +3167,8 class remFaradayProfiles(Operation): | |||||
3168 | fi_reps += 1 |
|
3167 | fi_reps += 1 | |
3169 | if fi_reps == (nTx2/nTaus): |
|
3168 | if fi_reps == (nTx2/nTaus): | |
3170 | fi = 0 |
|
3169 | fi = 0 | |
3171 | #print("AQUI, ", fi_reps, k, fi) |
|
|||
3172 | fi_reps = 0 |
|
3170 | fi_reps = 0 | |
3173 | f_ntx=False |
|
3171 | f_ntx=False | |
3174 | # if i < 1: |
|
|||
3175 | # print(fi, kt) |
|
|||
3176 | kt += 1 |
|
3172 | kt += 1 | |
3177 | k += 1 |
|
3173 | k += 1 | |
3178 |
|
3174 | |||
@@ -3182,8 +3178,7 class remFaradayProfiles(Operation): | |||||
3182 | # cbar = fig.colorbar(cax) |
|
3178 | # cbar = fig.colorbar(cax) | |
3183 | # plt.show() |
|
3179 | # plt.show() | |
3184 |
|
3180 | |||
3185 |
|
3181 | |||
3186 | #print ("AQUI") |
|
|||
3187 | #reshape the Flag as AMISR reader |
|
3182 | #reshape the Flag as AMISR reader | |
3188 |
|
3183 | |||
3189 | profPerCH = int( (nProfiles) / (nfft*nChannels)) |
|
3184 | profPerCH = int( (nProfiles) / (nfft*nChannels)) | |
@@ -3206,8 +3201,8 class remFaradayProfiles(Operation): | |||||
3206 | new_block[:,ich,:] = booldataset[:,idx_ch] |
|
3201 | new_block[:,ich,:] = booldataset[:,idx_ch] | |
3207 |
|
3202 | |||
3208 | new_block = numpy.transpose(new_block, (1,0,2)) |
|
3203 | new_block = numpy.transpose(new_block, (1,0,2)) | |
3209 | new_block = numpy.reshape(new_block, (nChannels,-1)) |
|
3204 | #new_block = numpy.reshape(new_block, (nChannels,-1)) | |
3210 |
|
|
3205 | new_block = numpy.reshape(new_block, (nChannels,profPerCH*nBlocks)) | |
3211 | self.profilesFlag = new_block.copy() |
|
3206 | self.profilesFlag = new_block.copy() | |
3212 |
|
3207 | |||
3213 | # fig = plt.figure() |
|
3208 | # fig = plt.figure() | |
@@ -3218,7 +3213,6 class remFaradayProfiles(Operation): | |||||
3218 |
|
3213 | |||
3219 | self.isConfig = True |
|
3214 | self.isConfig = True | |
3220 |
|
3215 | |||
3221 | #print(self.profilesFlag.shape) |
|
|||
3222 |
|
3216 | |||
3223 | def run(self,dataOut, channel=0, nChannels=5, nProfiles=300,nBlocks=100,nIpp1=100, |
|
3217 | def run(self,dataOut, channel=0, nChannels=5, nProfiles=300,nBlocks=100,nIpp1=100, | |
3224 | nIpp2=300, nTx2=132, nTaus=22, offTaus=8, iTaus=14, nfft=1 ,offIpp=0): |
|
3218 | nIpp2=300, nTx2=132, nTaus=22, offTaus=8, iTaus=14, nfft=1 ,offIpp=0): | |
@@ -3237,17 +3231,13 class remFaradayProfiles(Operation): | |||||
3237 | else: |
|
3231 | else: | |
3238 | self.flagRun = True |
|
3232 | self.flagRun = True | |
3239 | self.profile = 0 |
|
3233 | self.profile = 0 | |
3240 |
|
||||
3241 |
|
3234 | |||
3242 | #check profile ## Faraday interference |
|
3235 | #check profile ## Faraday interference | |
3243 | if self.profilesFlag[channel, self.profile]==0: |
|
3236 | if self.profilesFlag[channel, self.profile]==0: | |
3244 | dataOut.flagNoData = True # do not pass this profile |
|
3237 | dataOut.flagNoData = True # do not pass this profile | |
3245 | # print(self.nprofile, dataOut.flagNoData) |
|
3238 | ||
3246 | #print(self.nprofile2, self.profile, dataOut.flagNoData) |
|
|||
3247 | self.profile +=1 |
|
3239 | self.profile +=1 | |
3248 | # if self.profile == int((nProfiles*nBlocks)/self.nChannels): |
|
3240 | ||
3249 | # self.flagRun=False |
|
|||
3250 | # self.profile = 0 |
|
|||
3251 |
|
3241 | |||
3252 | self.nprofile2 +=1 |
|
3242 | self.nprofile2 +=1 | |
3253 |
|
3243 |
General Comments 0
You need to be logged in to leave comments.
Login now