casangi / xradio

Xarray Radio Astronomy Data IO
Other
9 stars 5 forks source link

Fix test_get_pad_nan_feed1 error on MacOS #177

Closed FedeMPouzols closed 1 month ago

FedeMPouzols commented 1 month ago

The failure is harmless in principle I think. Here is an attempt to fix the test without removing it.

The failure is a manifestation of https://github.com/numpy/numpy/issues/21166 "Conversion of numpy.nan to int gives inconsistent results" causing different behavior between platforms, for example: https://github.com/aai-institute/pyDVL/issues/474

This discrepancy should not be a big deal but could bite us if we end up having integer data variables in the final schema. For example missing "time-baseline" rows in the MS, become "np.nan" values in xdss, with the caveat that for integer data variables they would get whatever special value an np.nan is converted to. It turns out that:

CLAassistant commented 1 month ago

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you all sign our Contributor License Agreement before we can accept your contribution.
1 out of 2 committers have signed the CLA.

:white_check_mark: Jan-Willem
:x: FedeMPouzols
You have signed the CLA already but the status is still pending? Let us recheck it.