FRBs / sigpyproc3

Python3 version of Ewan Barr's sigpyproc library
https://sigpyproc3.readthedocs.io
MIT License
14 stars 11 forks source link

read_dedisp_block gives only the lowest frequency channel copied into all channels #36

Closed JoschaJ closed 4 months ago

JoschaJ commented 5 months ago

I realised that I can just read a block and dedisperse afterwards, but I thought I will report it anyways.

fil = FilReader(file)
data = fil.read_block(0, fil.header.nsamples)
data_dd = fil.read_dedisp_block(0, fil.header.nsamples, 0)
print(data_dd == data_dd[0])  # all rows are the same as the 0th
print(data_dd[0] == data)  # The 0th row is the same as the last row in the data.

Output

FilterbankBlock([[ True,  True,  True, ...,  True,  True,  True],
                 [ True,  True,  True, ...,  True,  True,  True],
                 [ True,  True,  True, ...,  True,  True,  True],
                 ...,
                 [ True,  True,  True, ...,  True,  True,  True],
                 [ True,  True,  True, ...,  True,  True,  True],
                 [ True,  True,  True, ...,  True,  True,  True]])
FilterbankBlock([[False, False, False, ..., False, False, False],
                 [False, False, False, ..., False, False, False],
                 [False, False, False, ..., False, False, False],
                 ...,
                 [False, False, False, ..., False, False, False],
                 [False, False, False, ..., False, False, False],
                 [ True,  True,  True, ...,  True,  True,  True]])
pravirkr commented 4 months ago

Thanks for reporting, @JoschaJ. It should work now! Feel free to reopen this issue if it does not work.