;+ ; Project : SOHO - CDS ; ; Name : MK_SYN_ATLAS ; ; Purpose : Creates synoptic map atlas files. ; ; Explanation : Calls SHOW_SYNOPTIC and stores the jpg file in the CDS ; atlas directory. ; ; Use : IDL> mk_syn_atlas [,/all] ; ; Inputs : None ; ; Opt. Inputs : None ; ; Outputs : None ; ; Opt. Outputs: None ; ; Keywords : ALL - will try to recreate all the synoptic images known ; to the catalogue. ; NEW - create new display even if old one exists. ; YEAR - specify the year for 'all' option ; ; ; Calls : SHOW_SYNOPTIC ; ; Common : None ; ; Restrictions: Requires write access to atlas directories. ; ; Side effects: None ; ; Category : Archive ; ; Prev. Hist. : None ; ; Written : C D Pike, RAL, ; ; Modified : Added NEW keyword. CDP, 23-Mar-99 ; Allow use of all SYNOP variations. CDP, 26-Aug-99 ; Change to jpg format. CDP, 3-Sep-2001 ; Make jpg work. CDP, 07/Jan/02 ; ; Version : Version 5, 7-Jan-2002 ;- pro mk_syn_atlas, all=all, new=new, year=year use_eof_cat, /q if keyword_set(all) then begin get_utc,utc mjd2date,utc.mjd,y,m,d headcat,cat,year=year endif else begin headcat,cat,/latest endelse n = where(strpos(cat.obs_prog,'SYNOP') ge 0,count) if count eq 0 then begin print,'No synoptic files.' return endif nd = count file = strarr(nd) ; ; format day number and catch those that start early on the 'previous day' ; for i=0,nd-1 do begin file(i) = strmid(anytim2cal(cat(n(i)).date_obs,f=8),0,8) file_id = long(file(i)) hr = fix(strmid(anytim2cal(cat(n(i)).date_obs,f=8),8,2)) if hr gt 20 then file_id = file_id + 1L file(i) = trim(file_id) endfor file = file(rem_dup(file)) nf = n_elements(file) for i=0,nf-1 do begin yr = strmid(file(i),0,4) ofile = '/archive/private/data/cds/atlas/synoptic/'+yr+'/syn_'+file(i)+'.jpg' if (not file_exist(ofile)) or keyword_set(all) or keyword_set(new) then begin show_synoptic,long(file(i)),status=status if status then begin ; arr = tvrd() ; tvscl,arr ; arr = tvrd() print,'/archive/private/data/cds/atlas/synoptic/'+yr+'/syn_'+file(i)+'.jpg' ; mk_jpg,'/archive/private/data/cds/atlas/synoptic/'+yr+'/syn_'+file(i)+'.jpg' x2jpeg,'/archive/private/data/cds/atlas/synoptic/'+yr+$ '/syn_'+file(i)+'.jpg' endif else begin print,'No data - '+file(i) endelse endif else begin print,'Already there and only updating - '+ofile endelse endfor end