ratt-ru / CubiCal

A fast radio interferometric calibration suite.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Null-v: Key doesn't exist

AKHughes1994 opened this issue · comments

Hello,

First of all, sorry if this is a silly question,

When trying to run a K-slope calibration run I get this error that kills the process

Traceback (most recent call last): File "/home/ubuntu/VirtualEnvironments/CubiCalEnv/lib/python3.9/site-packages/cubical/main.py", line 457, in main null_v=GD["model"]["null-v"]) KeyError: 'null-v'

I'm not exactly sure how to debug this issue, so I was hoping for some advice on where to begin.

Thanks,
Andrew

P.S. I've attached my parset
DI_bb2.txt

Try adding

null-v = 0

To the [model] section of your parset. This is a recent feature -- perhaps you're using a parset you made for an older version (if so, this means we mucked up the version transition... that key should be there by default...)

Adding that term changes the error to

Traceback (most recent call last): File "/home/ubuntu/VirtualEnvironments/CubiCalEnv/lib/python3.9/site-packages/cubical/main.py", line 453, in main ms.init_models(models, weights, fill_offdiag_weights=GD["weight"]["fill-offdiag"], TypeError: init_models() got an unexpected keyword argument 'null_v'

I'm guessing for some reason it is reading null-v in as null_v.

Hi @AKHughes1994! I am trying to reproduce the error. Could you possibly try and run using Python 3.8? I suspect that the problem is only in 3.9+. Not sure how long it will take me to find it.

Ah, after some head scratching I have managed to reproduce. This bug is in the release version on PyPI. You can install from the master branch on the repo and things should work - I will investigate the root cause.

I have identified the root cause - for some reason, the DefaultParset.cfg file in the release version is incorrect. This means that there is no default for the new parameter and causes this bug. I will need to upload a new release, although I am not quite sure how this happened.

Something went wrong with the original wheel/source upload. Updating to cubical==1.6.4 should solve the problem.

I can confirm this fixed the issue on my end. Thanks!