evanocathain / fits2fil

A code that converts psrfits format pulsar search data to sigproc filterbank format
1 stars 1 forks source link

psrfits2fil It's not working properly, or I've got the parameters wrong #1

Open wanglihuaya opened 5 years ago

wanglihuaya commented 5 years ago

hello This is my fault `23:38:47:singlepulse$ psrfits2fil qtt_190429_094555_0001.sf 1.382525715 1556 Output filterbank file qtt_190429_094555_0001.fil Opened file 'qtt_190429_094555_0001.sf' OBS_MODE = SEARCH TELESCOP NSRT There are 2 hdus at status 0 About to move to 1st SUBINT npol = 4 8 512 4 16384 sub->bytes_per_subint = 33554432 Made it through reading in the file rows per file 213 Before read: 4 16384 1.000000 24.897025 1 1 33554432

FITSIO status = 302: column number < 1 or > tfields Specified column number is out of range: 18 There are 17 columns in this table. ` What is the use of the program, file + period + center frequency, is it? I was hoping you could help me with that

Thanks a Million

evanocathain commented 5 years ago

Hello,

Thanks for your message. You can see the usage from just running psrfits2fil with no arguments, but it should suffice to do:

psrfits2fil $filename.sf

You can also do:

psrfits2fil $filename.sf flip

if you want to flip the band around. Those should make a file called $filename".fil", a SIGPROC filterbank format file. That is still search mode data, so not folded, so no need for the period.

Does this help?

You could also run psredit (from psrchive) on the fits file to check it is getting the correct nsblk for the values in that "Before read" output line.

I'd be happy to look at the file (or maybe a small snippet easier) to check it. It is very possible that this might not work, for reasons I never thought about, for data from a telescope I haven't tried before, so happy to test/update/improve as needed.

Good luck! Evan

wanglihuaya commented 5 years ago

Hello

Thank you very much for your reply, I really did not expect to receive a reply, or so soon to receive a reply, I am an undergraduate sophomore from China, my English may not be very good, please forgive me.

For psfits2fil I started with the psrfits2fil.py program in the presto program to try the conversion, but this is python with 2.7 and mine with 3.7, so presto is a bit tricky to set up, it should be a lack of dependencies, but I'm done now use python to convert, but I'd like to try your C program anyway, and I see that your comment is

'usage: psrfits2fil fitsfile (flip)(fcentMHz)'

Here's how I use it:[cid:3e1e62a8-1988-45df-8a7d-f03a5396131a]

Generate a 0kb t130501_043214.fil Can you help me? My data was downloaded by the Australian telescope: ATNFhttps://data.csiro.au/dap/public/atnf/pulsarresult.zul?observationmode=all&coneradius=0&pulsarname=j1141-6545&backend=all&frontend=all You can take a look

Finally, thank you so much for your help

Good luck 👍

LiHua


发件人: Evan Keane notifications@github.com 发送时间: 2019年8月10日 11:36 收件人: evanocathain/fits2fil fits2fil@noreply.github.com 抄送: 王李华 wanglihuaya@outlook.com; Author author@noreply.github.com 主题: Re: [evanocathain/fits2fil] psrfits2fil It's not working properly, or I've got the parameters wrong (#1)

Hello,

Thanks for your message. You can see the usage from just running psrfits2fil with no arguments, but it should suffice to do:

psrfits2fil $filename.sf

You can also do:

psrfits2fil $filename.sf flip

if you want to flip the band around. Those should make a file called $filename".fil", a SIGPROC filterbank format file. That is still search mode data, so not folded, so no need for the period.

Does this help?

You could also run psredit (from psrchive) on the fits file to check it is getting the correct nsblk for the values in that "Before read" output line.

I'd be happy to look at the file (or maybe a small snippet easier) to check it. It is very possible that this might not work, for reasons I never thought about, for data from a telescope I haven't tried before, so happy to test/update/improve as needed.

Good luck! Evan

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHubhttps://nam04.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fevanocathain%2Ffits2fil%2Fissues%2F1%3Femail_source%3Dnotifications%26email_token%3DALZ2M3NUNB2NMUNMCELCLJTQDYZTXA5CNFSM4IKVE7UKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOD4AFBUQ%23issuecomment-520114386&data=02%7C01%7C%7Cd527e2fd5f7d4ef8f93908d71d43edb0%7C84df9e7fe9f640afb435aaaaaaaaaaaa%7C1%7C0%7C637010049888457245&sdata=k2tTvwV4YmFoZEMUkwI7%2FQ7kxh0izeyxNraLAPIYx24%3D&reserved=0, or mute the threadhttps://nam04.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fnotifications%2Funsubscribe-auth%2FALZ2M3L5QXVLP6FLOHLEFKTQDYZTXANCNFSM4IKVE7UA&data=02%7C01%7C%7Cd527e2fd5f7d4ef8f93908d71d43edb0%7C84df9e7fe9f640afb435aaaaaaaaaaaa%7C1%7C0%7C637010049888467250&sdata=%2BVJKsqf3%2F3PD37qmXHNWyYSsfc5HqTjPaWK3rC95Wc8%3D&reserved=0.

evanocathain commented 4 years ago

Hi LiHua,

I cannot see your exact file name of usage line. I see just this:

"Here's how I use it:[cid:3e1e62a8-1988-45df-8a7d-f03a5396131a]

Generate a 0kb t130501_043214.fil Can you help me? My data was downloaded by the Australian telescope: ATNFhttps://data.csiro.au/dap/public/atnf/pulsarresult.zul?observationmode=all&coneradius=0&pulsarname=j1141-6545&backend=all&frontend=all You can take a look"

Can you tell me the exact file and I will grab it from the DAP and run myself, and fix any bugs that come from that?

I just fixed a couple of things which maybe will help, e.g. reading not-necessary FITS header keys, and some default values (also added a Makefile). But if you tell me the exact file you used I can simulate the exact issue.

Evan