Changeset 467 for trunk


Ignore:
Timestamp:
12/15/11 15:07:54 (12 years ago)
Author:
lelod
Message:

validation faite

Location:
trunk/src
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/extract_amsua.pro

    r466 r467  
    9393; ========== 
    9494; 
     95; lelod 20111215 
     96; tests de fonctionnement effectues: la correction nadir est 
     97;correctement implementee 
     98; l'interpolation de la fauchee fonctionne 
     99; mais attention test sur la longitude code en dur: 
     100; pbs avec les fauchees qui traversent le meridien 180deg!!!! 
     101; l'interpolation ajoute des points parasites dans la zone... 
    95102; $Id$ 
    96103; 
     
    192199; TODO 
    193200; ==== 
     201; 
     202; traiter les longitudes autour de 180 degres (passage de 180 a -180) 
     203; interpolswath ne gere pas cette situation 
    194204; 
    195205; comprendre les points bizarres autour de -40,30 visibles avec l'exemple 
     
    265275openr, lun_a, list_filea, /get_lun 
    266276filea='' 
    267 nlist=1 
     277nlist=0 
    268278ilist=0 
    269    ; while (not eof(lun_a)) do begin 
    270279loadct,39 
    271280numwindow=1 
    272281;while ilist le nlist do begin 
    273  while (not eof(lun_a)) do begin 
     282while (not eof(lun_a)) do begin 
    274283   ilist=ilist+1 
    275284   onefile = '' 
     
    370379;   colscale[j]=(tb[j]-min(tb))*255/(max(tb)-min(tb)) 
    371380;endfor 
    372 ;plots,lolo,lala,psym=5,symsize=2,color=colscale 
     381;plots,lolo,lala,psym=5,symsize=1,color=colscale 
    373382;numwindow=numwindow+1 
    374383 
     
    376385; reguliere dans la fauchee 
    377386; et selection de la zone conservee 
    378 ;tek_color 
    379 ;resol=1 
     387; attention test sur la longitude code en dur: 
     388; pbs avec les fauchees qui traversent le meridien 180deg!!!! 
     389; l'interpolation ajoute des points parasites dans la zone... 
    380390   nbgrid=0 
     391cont=0L 
    381392   for i=0L,n_scan-1L do begin 
    382393      tb=ch_nadir[*,i] 
     
    384395      lat=amalat[*,i] 
    385396      mask=landseamask[*,i] 
    386       nbgrid1=nbgrid 
    387       interpolswath,tb,lat,lon,mask,resol,nbgrid,tbgrid,latgrid,longrid,maskgrid 
    388       if i eq 0L then begin 
    389          fovgrid=indgen(nbgrid)+1 
    390       endif 
    391       ;ind=where(tbgrid gt tbmin and tbgrid lt tbmax,nbon) 
    392      ; if (nbon ne 0) then begin 
    393          longit=longrid 
    394          latit=latgrid 
    395       ;   oplot,longit,latit,psym=3,color=0 
    396      ; endif else begin 
    397      ;    print,'pas de point valable dans la fauchee' 
    398      ; endelse 
     397      ind=where(tb gt 0 and lon gt -60 and lon lt 100,nbon) 
     398      if nbon eq nbpix then begin 
     399         cont=cont+1L 
     400         nbgrid1=nbgrid 
     401         interpolswath,tb,lat,lon,mask,resol,nbgrid,tbgrid,latgrid,longrid,maskgrid 
     402         if cont eq 1L then begin 
     403            fovgrid=indgen(nbgrid)+1 
     404         endif 
     405         ;longit=longrid 
     406         ;latit=latgrid 
     407         ;oplot,longit,latit,psym=3,color=0 
    399408 
    400409; selection des taches au sol situees dans la zone d'interet 
    401       zone=where((longrid ge lon_min) and (longrid le lon_max) $ 
    402                  and (latgrid ge lat_min) and (latgrid le lat_max) and (tbgrid gt tbmin), npt) 
    403       if npt ne 0 then begin 
    404          if (n_elements(chint) EQ 0) then begin 
    405             timeint=replicate(tt[i],npt) 
    406             chint=tbgrid[zone] 
    407             latint=latgrid[zone] 
    408             lonint=longrid[zone] 
    409             fovint=fovgrid[zone] 
    410             maskint=maskgrid[zone] 
     410         zone=where((longrid ge lon_min) and (longrid le lon_max) $ 
     411                    and (latgrid ge lat_min) and (latgrid le lat_max) and (tbgrid gt tbmin), npt) 
     412         if npt ne 0 then begin 
     413            if (n_elements(chint) EQ 0) then begin 
     414               timeint=replicate(tt[i],npt) 
     415               chint=tbgrid[zone] 
     416               latint=latgrid[zone] 
     417               lonint=longrid[zone] 
     418               fovint=fovgrid[zone] 
     419               maskint=maskgrid[zone] 
     420            endif else begin 
     421               chint=[chint,tbgrid[zone]] 
     422               latint=[latint,latgrid[zone]] 
     423               lonint=[lonint,longrid[zone]] 
     424               fovint=[fovint,fovgrid[zone]] 
     425               maskint=[maskint,maskgrid[zone]] 
     426               timeint=[timeint,replicate(tt[i],npt)] 
     427            endelse 
    411428         endif else begin 
    412             chint=[chint,tbgrid[zone]] 
    413             latint=[latint,latgrid[zone]] 
    414             lonint=[lonint,longrid[zone]] 
    415             fovint=[fovint,fovgrid[zone]] 
    416             maskint=[maskint,maskgrid[zone]] 
    417             timeint=[timeint,replicate(tt[i],npt)] 
     429            print, 'www : aucun point dans la zone' 
    418430         endelse 
    419431      endif else begin 
    420          print, 'www : aucun point dans la zone' 
     432         print,'fauchee incomplete',nbon 
    421433      endelse 
    422434 
     
    485497plot,lonint,latint,xrange=[lon_min,lon_max],yrange=[lat_min,lat_max],xstyle=1,ystyle=1,/nodata 
    486498ind=where(maskint eq 1) 
    487 oplot,lonint[ind],latint[ind],psym=1 
     499;oplot,lonint[ind],latint[ind],psym=1 
    488500jnd=where(chint gt tbmin and chint lt tbmax) 
    489501tb=chint[jnd] 
  • trunk/src/interpolswath.pro

    r466 r467  
    4040;   * minimal rest header 
    4141; 
     42; TO DO 
     43; ===== 
     44; regler le pb des longitudes autour de 180 degres 
     45; l'interpolation ne les gere pas et cree des points dans la zone AMMA... 
    4246;- 
    4347pro interpolswath, tb, latlu, lonlu, masklu, resol, nbgrid, tbint, latgrid, longrid, mask 
     
    7074;print,pixatot 
    7175;window,1 
    72 ;ploterr,ifov,fova,pixatot 
     76 ;ploterr,ifov,fova,pixatot 
    7377 
    7478distmax=-min(fova)+max(fova)+max(pixa) 
     
    7983if (dmax/delta-fix(dmax/delta) le 0.5) then ndemigrid=ndemigrid-1 
    8084nbgrid=ndemigrid*2 
    81 print,'nb pts',nbgrid, ' dmax',dmax 
     85;print,'nb pts',nbgrid, ' dmax',dmax 
    8286 
    8387grid2=indgen(ndemigrid)*delta+fova[nnadir] 
     
    116120longrid=interpol(lonlu,fova,grid) 
    117121 
     122ind=where(longrid gt 35 and longrid lt 45 and latgrid gt 10 and latgrid lt 25,nbind) 
     123if nbind ne 0 then begin 
     124  ; print,'longitude intiniale',lonlu 
     125  ; print,'long. interpolee',longrid 
     126endif 
    118127;print,tbint 
    119128end 
Note: See TracChangeset for help on using the changeset viewer.