Skip to content

Seg fault on attempting to print ifit *_gvar results in _fit_integrated_spectra #32

@Lyalpha

Description

@Lyalpha

When running

from orcs.process import SpectralCube
cube = SpectralCube('data/SN3/NGC6946_SN3.merged.cm1.1.0.hdf5', debug=True)
cube.map_sky_velocity(80., div_nb=4)

I get a Segmentation fault (core dumped), output is below. I'm running the latest master versions of orb/orcs. From stepping through the code with python debugger - I get to this point in the code:

...
...
 [==========] [100%] [completed in 13.9 s]                                    
180130-13:46:50|parallel:87:close_pp_server|DEBUG> ncpus: 8,  njobs: 4, rworker: None, time: 32.7136440277
> /home/jdl/research/work/NGC6946_SITELLE/build/bdist.linux-x86_64/egg/orcs/core.py(733)_fit_integrated_spectra()
-> lines = gvar.mean(self.inputparams.allparams.pos_guess)
(Pdb) n
> /home/jdl/research/work/NGC6946_SITELLE/build/bdist.linux-x86_64/egg/orcs/core.py(736)_fit_integrated_spectra()
-> for iregion in range(len(regions)):
(Pdb) s
> /home/jdl/research/work/NGC6946_SITELLE/build/bdist.linux-x86_64/egg/orcs/core.py(737)_fit_integrated_spectra()
-> ifit, ispectrum = all_fit[iregion]
(Pdb) s
> /home/jdl/research/work/NGC6946_SITELLE/build/bdist.linux-x86_64/egg/orcs/core.py(739)_fit_integrated_spectra()
-> if ifit != []:
(Pdb) s
> /home/jdl/research/work/NGC6946_SITELLE/build/bdist.linux-x86_64/egg/orcs/core.py(741)_fit_integrated_spectra()
-> all_fit_results = list()
(Pdb) s
> /home/jdl/research/work/NGC6946_SITELLE/build/bdist.linux-x86_64/egg/orcs/core.py(742)_fit_integrated_spectra()
-> logging.info('Velocity of the first line (km/s): {}'.format(ifit['velocity_gvar'][0]))
(Pdb) s
Segmentation fault (core dumped)

In the debugger, if I try to even print ifit['velocity_gvar'] I get a seg fault. I can print ifit['velocity'] and ifit['velocity_err'], however, and the numbers seem sensible. If I try to print other *_gvar entries I also get a seg fault.

Simply commenting out the line that is attempting to print velocity_gvar acts as a workaround for me to get the results from map_sky_velocity.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions