Skip to content

Commit

Permalink
added stilts script to add descriptions to the votable output
Browse files Browse the repository at this point in the history
  • Loading branch information
dpshelio committed Jan 31, 2012
1 parent 7cf94f0 commit f7caf2e
Show file tree
Hide file tree
Showing 4 changed files with 57 additions and 6 deletions.
15 changes: 15 additions & 0 deletions cir_stilts_script
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
tablename "SHEBA CIR propagation model"
colmeta -desc "Time the CIR origin at the Sun" time_start
colmeta -desc "Longitude in Heliographic coordinates of the origin of the CIR" -units "degrees" long_hg
colmeta -desc "HGI Longitude coordinates of the origin of the CIR" -units "degrees" long_hci
colmeta -desc "Speed of the solar wind" -units "km/s" v
colmeta -desc "Error of the speed" -units "km/s" v_err
colmeta -desc "Planet or spacecraft of the solar system" target_obj
colmeta -desc "Radial Distance from the Sun" -units "AU" r_hci
colmeta -desc "Label that shows whether the object is hit or not" HitOrMiss
colmeta -desc "Estimated time of arrival" ETA
colmeta -desc "Minimun Estimated time of arrival" ETA_min
colmeta -desc "Maximum Estimated time of arrival" ETA_max
colmeta -desc "Estimated number of days for arrival" -units "Days" Dt
colmeta -desc "Estimated minimum number of days for arrival" -units "Days" Dt_min
colmeta -desc "Estimated maximum number of days for arrival" -units "Days" Dt_max
16 changes: 16 additions & 0 deletions cme_stilts_script
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
tablename "SHEBA CME propagation model"
colmeta -desc "Time the CME emerges from the Sun" time_start
colmeta -desc "Longitude in Heliographic coordinates" -units "degrees" long_hg
colmeta -desc "HGI Longitude" -units "degrees" long_hci
colmeta -desc "Longitudinal width of the CME" -units "degrees" long_width
colmeta -desc "Speed of the CME" -units "km/s" v
colmeta -desc "Error of the speed" -units "km/s" v_err
colmeta -desc "Planet or spacecraft of the solar system" target_obj
colmeta -desc "Radial Distance from the Sun" -units "AU" r_hci
colmeta -desc "Label that shows whether the object is hit or not" HitOrMiss
colmeta -desc "Estimated time of arrival" ETA
colmeta -desc "Minimun Estimated time of arrival" ETA_min
colmeta -desc "Maximum Estimated time of arrival" ETA_max
colmeta -desc "Estimated number of days for arrival" -units "Days" Dt
colmeta -desc "Estimated minimum number of days for arrival" -units "Days" Dt_min
colmeta -desc "Estimated maximum number of days for arrival" -units "Days" Dt_max
14 changes: 14 additions & 0 deletions sep_stilts_script
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
tablename "SHEBA SEP propagation model"
colmeta -desc "Time the SEP event happens at the Sun" time_start
colmeta -desc "Longitude in Heliographic coordinates" -units "degrees" long_hg
colmeta -desc "HGI Longitude" -units "degrees" long_hci
colmeta -desc "Speed of the Solar Wind" -units "km/s" v
colmeta -desc "Error of the speed" -units "km/s" v_err
colmeta -desc "Fraction of the speed of light" -units "1/c" beta
colmeta -desc "Planet or spacecraft of the solar system" target_obj
colmeta -desc "Radial Distance from the Sun" -units "AU" r_hci
colmeta -desc "Label that shows whether the object is hit or not" HitOrMiss
colmeta -desc "Velocity of the solarwind that connects the event with the object" -units "km/s" v_estimated
colmeta -desc "Estimated time of arrival" ETA
colmeta -desc "Estimated number of seconds for arrival" -units "seconds" Dt

18 changes: 12 additions & 6 deletions writing_prop_out.pro
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,11 @@ function sheba_header,model=model
str = ''

if model eq 'cme' then $
str = "time_start,long_hg,long_hci,long_width,v,v_err,target_obj,r_hci,HitOrMiss,ETA,ETA_min,ETA_max,Dt[days],Dt_min[days],Dt_max[days]"
str = "time_start,long_hg,long_hci,long_width,v,v_err,target_obj,r_hci,HitOrMiss,ETA,ETA_min,ETA_max,Dt,Dt_min,Dt_max"
if model eq 'sep' then $
str = "time_start,long_hg,long_hci,v,v_err,beta,target_obj,r_hci,HitOrMiss,v_estimated,ETA,Dt[s]"
str = "time_start,long_hg,long_hci,v,v_err,beta,target_obj,r_hci,HitOrMiss,v_estimated,ETA,Dt"
if model eq 'cir' then $
str = "time_start,long_hg,long_hci,v,v_err,target_obj,r_hci,HitOrMiss,ETA,ETA_min,ETA_max,Dt[days],Dt_min[days],Dt_max[days]"
str = "time_start,long_hg,long_hci,v,v_err,target_obj,r_hci,HitOrMiss,ETA,ETA_min,ETA_max,Dt,Dt_min,Dt_max"

return,str
end
Expand Down Expand Up @@ -68,7 +68,7 @@ dt1_out_max = (t1_out eq '')?'':string((anytim(object.minmaxt.t_max) - anytim(ob
string(object.pos_t0.radio,format='(F7.3)') +',' + $ ; distance
string(object.HitOrMiss,format='(I1)') +',' + $ ; HitOrMiss
swvel+',' + $ ; velocity stimated
object.pos_thit.date +','+$ ; time of arrival
t1_out+','+$ ; time of arrival
dt ; dt in seconds.

return,str
Expand All @@ -94,8 +94,14 @@ object_struct = (data_chk(spacecraft_str,/type) eq 8 )?['planets_str','spacecraf
close,/all

; votable optative (stilts)
stilts_command = './stilts tcopy '+file_out+'.csv ifmt=csv '+file_out+'.votable ofmt=votable'
if keyword_set(votable) then spawn,stilts_command
stilts_command = './stilts tcopy '+file_out+'.csv ifmt=csv '+file_out+'00.votable ofmt=votable'
stilts_change = './stilts tpipe cmd=@'+model+'_stilts_script '+file_out+'00.votable ofmt=votable out='+file_out+'.votable'
if keyword_set(votable) then begin
spawn,stilts_command
spawn,stilts_change
delete_midfiles = 'rm '+file_out+'00.votable'
spawn,delete_midfiles
endif

end

Expand Down

0 comments on commit f7caf2e

Please sign in to comment.