Skip to content

Commit

Permalink
Add option to change output type in the GUI... just copying whatever …
Browse files Browse the repository at this point in the history
…was done for ihowfarless
  • Loading branch information
marenaud committed Jan 16, 2018
1 parent 76761fa commit 47baa08
Show file tree
Hide file tree
Showing 5 changed files with 26 additions and 4 deletions.
10 changes: 8 additions & 2 deletions HEN_HOUSE/omega/progs/gui/dosxyznrc/create_file_nrc.tcl
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ proc create_file { file } {
global grouping nrow izrow enflag numsrcopts izopts ncpu dflag parnum
global numthphi angfixed ang1 ang2 nang pang ivary thphidef
global numsets iso1 iso2 iso3 ang1 ang2 ang3 dsource muI
global iphant iphspout imuphspout calflag
global iphant iphspout imuphspout calflag ibindos
global level ibcmp_min ibcmp_max iphter_min iphter_max
global iraylr_min iraylr_max iedgfl_min iedgfl_max
global i_dbs r_dbs ssd_dbs z_dbs the_beam_code the_input_file the_pegs_file
Expand Down Expand Up @@ -446,7 +446,13 @@ set str "$ivary($i), $angfixed($i), $ang1($i), $ang2($i), $nang($i), $pang($i)"
} else {
set val 0
}
set str "$str$val, $iphspout"
set str "$str$val, $iphspout, "
if { [string compare $values(ibindos) $options(ibindos,1)]==0 } {
set val 1
} else {
set val 0
}
set str "$str$val"

puts $file $str

Expand Down
8 changes: 8 additions & 0 deletions HEN_HOUSE/omega/progs/gui/dosxyznrc/load_input2_nrc.tcl
Original file line number Diff line number Diff line change
Expand Up @@ -772,6 +772,14 @@ proc read_input {} {
set iphspout 0
if {$arr(0)<=2} { set iphspout $arr(0) }

# bindos output option
set data [get_val $data arr 0]
if {$arr(0)==1} {
set values(ibindos) $options(ibindos,1)
} else {
set values(ibindos) $options(ibindos,0)
}

# now get the EGSnrc inputs
foreach i {ecut pcut smaxir estepe ximax bca_algorithm skindepth_for_bca \
transport_algorithm spin_effects ibrdst ibr_nist ibcmp iprdst\
Expand Down
3 changes: 2 additions & 1 deletion HEN_HOUSE/omega/progs/gui/dosxyznrc/reset_parameters_nrc.tcl
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ proc reset_parameters { } {
global spec_file ecutin pcutin estepm smax imax ivox gvox dsurround
global inc exc names mvox izvox PhantFileName latbit nbit1 nbit2
global grouping nrow izrow enflag numsrcopts izopts maxvals
global dflag dflagopt iphspout imuphspout calflag
global dflag dflagopt iphspout imuphspout calflag ibindos
global numthphi angfixed ang1 ang2 nang pang ivary thphidef
global numsets iso1 iso2 iso3 ang1 ang2 ang3 dsource muI
global iphant level the_beam_code the_input_file the_pegs_file
Expand Down Expand Up @@ -172,6 +172,7 @@ proc reset_parameters { } {
set iphspout 0
set imuphspout 0
set calflag 0
set ibindos 0

set Ein {}
set spec_file {}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -256,7 +256,7 @@ proc edit_parameters {} {
frame $w
frame $w1
frame $w2
foreach j { 5 6 7 8 9 10 12 ihowfarless } {
foreach j { 5 6 7 8 9 10 12 ihowfarless ibindos } {
frame $w1.inp$j -bd 4
button $w1.inp$j.help -text "?" -command "help $j"
label $w1.inp$j.label -text $names($j) -anchor w
Expand Down
7 changes: 7 additions & 0 deletions HEN_HOUSE/omega/progs/gui/dosxyznrc/xyznrc_parameters.tcl
Original file line number Diff line number Diff line change
Expand Up @@ -743,6 +743,13 @@ monoenergetic electron beams.
Recommended for all homogeneous phantom calculations.
}

set ibindos {}
set names(ibindos) "Dose output"
set numopts(ibindos) 2
set options(ibindos,0) "3ddose output"
set options(ibindos,1) "sparse binary output"
set values(ibindos) $options(ibindos,0)

#################The following are the EGSnrc parameters#############

set ecut {}
Expand Down

0 comments on commit 47baa08

Please sign in to comment.