jaimedelacruz / stic

The Stockholm inversion code
19 stars 6 forks source link

exercise_1 produce zeros in sythised stokes profiles #1

Closed HighwayStar closed 5 years ago

HighwayStar commented 5 years ago

I'm trying to run exercises and stuck at first one. Using configs from exercise1.tar.bz2 I compared it to pdf recommended params, all seems fine, but synth result is zero Q,U,V profiles, only I synthed.

I've tried to add synthesize_lte_eos = 1 to input.cfg but it seems not changing anything.

Commands output:

stic/exercises/exercise_1> python prepare_input_model.py                             
model::setSize: nx = 2, ny = 2, ndep = 82, nt = 1
model::write: FALC.nc -> nx=2, ny=2, ndep=82, nt=1
stic/exercises/exercise_1> mpirun -n 2 ../../src/STiC.x 

   SSSSSSSSSSSSSSS TTTTTTTTTTTTTTTTTTTTTTT  iiii         CCCCCCCCCCCCC
 SS:::::::::::::::ST:::::::::::::::::::::T i::::i     CCC::::::::::::C
S:::::SSSSSS::::::ST:::::::::::::::::::::T  iiii    CC:::::::::::::::C
S:::::S     SSSSSSST:::::TT:::::::TT:::::T         C:::::CCCCCCCC::::C
S:::::S            TTTTTT  T:::::T  TTTTTTiiiiiii C:::::C       CCCCCC
S:::::S                    T:::::T        i:::::iC:::::C              
 S::::SSSS                 T:::::T         i::::iC:::::C              
  SS::::::SSSSS            T:::::T         i::::iC:::::C              
    SSS::::::::SS          T:::::T         i::::iC:::::C              
       SSSSSS::::S         T:::::T         i::::iC:::::C              
            S:::::S        T:::::T         i::::iC:::::C              
            S:::::S        T:::::T         i::::i C:::::C       CCCCCC
SSSSSSS     S:::::S      TT:::::::TT      i::::::i C:::::CCCCCCCC::::C
S::::::SSSSSS:::::S      T:::::::::T      i::::::i  CC:::::::::::::::C
S:::::::::::::::SS       T:::::::::T      i::::::i    CCC::::::::::::C
 SSSSSSSSSSSSSSS         TTTTTTTTTTT      iiiiiiii       CCCCCCCCCCCCC

STIC: Initialized with 2 process(es)
read_input: ignoring line: # I/O options and observation details
read_input: input_model -> FALC.nc
read_input: output_profiles -> synthetic.nc
read_input: abundance_file -> Atoms/abundance.input
read_input: mu -> 1.0
read_input: ignoring line: # Some inversion stuff: Mode 1 is invert pixel to pixel, mode 2 is synthesis, mode 3
read_input: ignoring line: # is sparse inversion (broken at the moment)
read_input: mpi_pack -> 1
read_input: mode -> 2
read_input: synthesize_lte_eos -> 1
read_input: master_threads -> 1
read_input: recompute_hydro -> 2
read_input: ignoring line: # Type of atmosphere: rh 
read_input: atmosphere_type -> rh
read_input: ignoring line: # Add your regions here!! For example: 
read_input: ignoring line: # Regions information, they will be appended one after the other 
read_input: region -> 3932.246500,0.039500,75,1.0,none,3933.nc
read_input: region -> 3967.031600,0.039500,75,1.0,none,3968.nc
read_input: region -> 8540.250900,0.050000,75,1.0,none,8542.nc
read_input: region -> 6301.230000,0.020000,25,1.0,none,6301.nc
read_input: region -> 6302.150000,0.020000,25,1.0,none,6302.nc
read_input: region -> 2794.038400,0.050900,88,1.0,none,2797.nc
read_input: region -> 2801.673400,0.050900,39,1.0,none,2797.nc
read_input: ignoring line: # depth_type: use 0 for log_tau or 1 for log_cmass. In synthesis mode we can use also "2" for "z".
read_input: depth_t -> 0
read_input: ignoring line: # Set this to false if you are running big runs
read_input: verbose -> 1
io::initRead: Found 12 variables in FALC.nc [azi, bhor, blong, cmass, ltau500, nne, pgas, rho, temp, vlos, vturb, z]
io::initRead: Found 12 variables in FALC.nc [azi, bhor, blong, cmass, ltau500, nne, pgas, rho, temp, vlos, vturb, z]
io::read_Tstep: read temp (t=0) [2, 2, 82]
io::read_Tstep: read vlos (t=0) [2, 2, 82]
io::read_Tstep: read vturb (t=0) [2, 2, 82]
io::read_Tstep: read blong (t=0) [2, 2, 82]
io::read_Tstep: read bhor (t=0) [2, 2, 82]
io::read_Tstep: read azi (t=0) [2, 2, 82]
io::read_Tstep: read pgas (t=0) [2, 2, 82]
io::read_Tstep: read rho (t=0) [2, 2, 82]
io::read_Tstep: read nne (t=0) [2, 2, 82]
mdepthall::read_model2: Bound -> 1
io::read_Tstep: read ltau500 (t=0) [2, 2, 82]
io::read_Tstep: read z (t=0) [2, 2, 82]
io::read_Tstep: read cmass (t=0) [2, 2, 82]
io::write_Tstep: writing [wav] to synthetic.nc
master, comm_get_buffer_size: MPI_buffer_size = 1.04395 kbytes
master, comm_get_buffer_size: MPI_buffer_size1 = 1.57324 kbytes
Processed -> 133%  
io::write_Tstep: writing [profiles] (t=0) to synthetic.nc

master, comm_kill_slaves: Killing slaves
mdepthall::setsize: [0 0 0]
main: total elapsed time [00:00:02.580]

Current exercise with synth result attached: exercise_1.zip

jaimedelacruz commented 5 years ago

In that exercise you are expected to: 1) use the python script to generate the input model. 2) activate the atomic species that you want to compute in non-LTE, in this case the CaII atom and the MgII atom in atoms.input.

I just did those two things and I can reproduce the full-Stokes output that is expected. Have you performed step 2)?

HighwayStar commented 5 years ago

Yes turns out I missed step 2, now it works. Thank you for your help!