scottransom / presto

Open source pulsar search and analysis toolkit
http://www.cv.nrao.edu/~sransom/presto/
GNU General Public License v2.0
240 stars 177 forks source link

Discrepancy between time for single pulse with single_pulse_search.py and watefaller.py #189

Open suaraujo opened 1 year ago

suaraujo commented 1 year ago

Hello, I am analysing a single pulse in an observation and I have discrepancies when seeing it with waterfaller.py. I am working with PRESTO 2. I got the time for the single pulse and its DM value with single_pulse_search.py. I use the DM value in which the S/N is the highest. When I see the time series with exploredat, the pulse appears at the time that single_pulse_search.py indicates. If I read the time series in python, it also appears when single_pulse_search.py indicates.

The problem arises when I am trying to get the dynamic spectrum of the single pulse with waterfaller.py. The pulse appears later in time (~0.16s later) and the value of DM at which it is aligned is 20 pc/cm^-3 higher. Do you know which could be the reason for the discrepancy?

scottransom commented 1 year ago

Hmmm. Good question. I didn't write waterfaller.py (or several of the python modules it uses), and so I'd have to dig into the code. Looking quickly, it looks like they might use the center of the top subband as the reference frequency for the timing. PRESTO, in general, uses the center of the highest frequency channel as the time (and dedispersion) reference. There could also be an issue with how the dedispersion is done.

It might be worth making some fake data with a known short pulse in it and running it through single_pulse_search.py (after dedispersion) and the waterfaller.py to see if you can figure out where the offset is. Note that I haven't heard of this issue before, so it is possible that it was fixed in a more recent version of PRESTO! PRESTO 2 is very old now!