-
Notifications
You must be signed in to change notification settings - Fork 3
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix backwards compatibility bugs with UVPSpec data files #195
Conversation
…lpair_array in old UVPSpec files
This should fix issue #194. |
- source activate test-environment | ||
- conda install -c conda-forge healpy aipy scikit-learn | ||
- conda install -c conda-forge healpy aipy |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
hera_qm and hera_cal, although they don't strictly require it, have some advanced functionality that relies on scikit-learn
, so it'd be nice to keep this if possible. was something breaking with the installation?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks Nick. The reason from removing scikit-learn
from this line is that it was pulling in an old version of numpy
, which is now incompatible with pyuvdata
(thus causing the tests to fail). It is installed via pip
later on in the Travis script however (pip allows it to install with a more recent version of numpy
).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me, but I'd like to keep scikit-learn
installation if its not breaking anything
Thanks for the quick turnaround @philbull! |
Fix two backwards compatibility bugs related to loading old HDF5 files into
UVPSpec
objects.The first is related to HDF5 in Py3, which returns
bytes
instead of strings. A string comparison was failing as a result. All string attributes inUVPSpec
files are now converted frombytes
to strings.The second is due to the recent change from
pol_array
topolpair_array
in theUVPSpec
data model. The oldpol_array
attribute is now detected and automatically converted to apolpair_array
when a file is loaded. AUserWarning
is shown when this happens.